I have a field called attachment_file which i set as an upload field with view tag set to image. AM uploading into a given folder and saving the file name here. during row_inserting i can then do some validations on the file like i can know its extension etc which also works fine
When uploading a file which is one of the predefined allowed types like png,xls it works fine.
BUT i want users to be able to upload any type of file into this,. And i can not go adding all possible file types into the ASP.NET settings->file upload->allowed file type or in idvanced settinngs.
SO i want at runtime to be able to allow a user to browse and attach all files ie (.). AM doing it as below
// Page Load event
public override void Page_Render() {
////Log("Page Render");
attachment_file.UploadAllowedFileExtensions = "*";
}
When i inspect the browser i see it cange like <input name="fx_x_attachment_file" id="fx_x_attachment_file" value="*" type="hidden">
BUt it still wont allow if i browse a file of type like .mp3 etc.