Hi,
/// <summary>
/// Validate the Fileformat
/// </summary>
/// <param name = "filepath">FilePath</param>
/// <returns>Boolean</returns>
public boolean validateFileExtension(str filepath)
{
str actualFileName, fileExtension, actualFilePath;
boolean ok = true;
[actualFilePath,actualFileName, fileExtension] = fileNameSplit(filePath);
ok = strScan(actualFileName,allowedFileNameFormat,1,strLen(actualFileName));
if(!ok)
{
Error("@SUNR:FileDoesntExisit");
}
return ok;
}
/// Validate the Fileformat
/// </summary>
/// <param name = "filepath">FilePath</param>
/// <returns>Boolean</returns>
public boolean validateFileExtension(str filepath)
{
str actualFileName, fileExtension, actualFilePath;
boolean ok = true;
[actualFilePath,actualFileName, fileExtension] = fileNameSplit(filePath);
ok = strScan(actualFileName,allowedFileNameFormat,1,strLen(actualFileName));
if(!ok)
{
Error("@SUNR:FileDoesntExisit");
}
return ok;
}
Regards,
No comments:
Post a Comment