Welcome to the SRP Forum! Please refer to the SRP Forum FAQ post if you have any questions regarding how the forum works.

fsmsg without displaying error message

Hi, please look at the following code:

RV = CopyOSFile(FileName,original_file_name) if RV then OSDelete FileName end else error_msg = "Reason unknown." status = Get_Status(errCodes) if status then error_msg = FsMsg(errCodes) end Error = "Could not copy the file ":FileName:" to ":original_file_name:" Reason: ":error_msg

I want to get the error text associated with status. How can I get the error text without a message box being put up, which fsmsg does.

Comments

  • What does @FILE_ERROR contain in this error state? If it doesn't contain the verbosity you require, you might need to extract the error text yourself from the relevant insert record or from REVERROR.DAT.
  • ok, i realised that all of these error messages are stored in an insert, so it is possible for me to get them myself. I just thought there would be a function that did this for you built into OI.

    Thanks
  • Depending upon the command that generated the error, Get_Status usually does contain the full error text. I assumed by your question this wasn't the case when the error is coming from CopyOSFile. I didn't attempt to duplicate your situation to confirm. That's why I asked about @FILE_ERROR.
Sign In or Register to comment.