FileBrowserTextBoxExtender question

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

Please do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.

This forum is for discussing mojoPortal development

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

You can monitor commits to the repository from this page. We also recommend developers to subscribe to email notifications in the developer forum as occasionally important things are announced.

Before posting questions here you might want to review the developer documentation.

Do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.
This thread is closed to new posts. You must sign in to post in the forums.
10/8/2011 5:19:17 PM
Gravatar
Total Posts 81
Website Hobbyist and Software Engineer
Proud member of the mojoPortal team
www.doan.me

FileBrowserTextBoxExtender question

Is there a way to specify what file extensions to display in the FileBrowserTextBoxExtender? I would like to use it, but for my feature I need to specify specific files types that the user can select for use with the feature.

Thanks for any guidance you can provide.

10/9/2011 1:54:27 PM
Gravatar
Total Posts 18439

Re: FileBrowserTextBoxExtender question

Hi Kerry,

There is a property on FileBrowserTextBoxExtender for BrowserType="file"

there are 3 valid values for it file, image, and media, file is the default.

this is really just a parameter that gets passed to the FileDialog.aspx page to indicate what kinds of files to support. But that dialog doesn't really support any more specific control other than those 3 types.

You could use a RegularExpressionValidator on the textbox to further limit what the user can choose but it won't prevent him from choosing other file types in the dialog, just from saving them in your feature.

So if those don't satisfy your needs you would have to implement your own modified versions of FileBrowserTextBoxAppender and of FileDialog.aspx. You could copy those into your custom feature, change the names and namespaces then modify them as you see fit. You may also need to implement your own version of /Services/jQueryFileTreeMediaBrowser.ashx

Hope that helps,

Joe

 

10/9/2011 7:08:16 PM
Gravatar
Total Posts 81
Website Hobbyist and Software Engineer
Proud member of the mojoPortal team
www.doan.me

Re: FileBrowserTextBoxExtender question

Joe,

Thanks for the quick reply. Not exactly the answer I was hoping for, but the option to set the BrowserType to "media" and then have a Regular Expression Validator on the Text Box sounds like an acceptable option for now. Maybe if I have more time in the future I will look into fine tuning the functionality of the FileBrowserTextBoxExtender control.

Thanks

Kerry

You must sign in to post in the forums. This thread is closed to new posts.