i already used another text box that shows the path of the file, and i used a validator to check if it's empty or doesn't contain a file:
function validateFile(source, args) {
var regex = /.*\..{3,4}/;
var textBoxFileName = document.getElementById('<%=TextBoxFileName.ClientID%>');
if (textBoxExistingFile != null && textBoxFileName != null)
{
if (textBoxFileName.value.length == 0 ||
textBoxFileName.value.search(regex) == -1)
{
args.IsValid =
false;
return;
}
}
args.isValid =
true;
}
function fillFileName(sender, args) {
var label = document.getElementById('<%=TextBoxFileName.ClientID%>');
if (label != null)
label.innerText = args.get_item().get_path();
OnClientItemSelected(sender, args);
}
<telerik:RadFileExplorer ID="RadFileExplorer1" runat="server" Configuration-MaxUploadFileSize="307200"
EnableCreateNewFolder="false" EnableOpenFile="true" OnClientItemSelected="fillFileName">
<Configuration SearchPatterns="*.jpg,*.jpeg,*.JPG,*.JPEG,*.gif,*.GIF,*.png,*.PNG" />
</telerik:RadFileExplorer>