Handling output for multiple error messages

Started by Omar

Omar

Handling output for multiple error messages   06 August 2019, 21:41

I am using a remote VB script (essentially the same as your logged on user script built into the software). In the column view, how do I enter the Regular Expression so that I can have it replace multiple values?

For example, when I run the scan, it gives me one of the following:
  • Name of the user
  • No one is logged onto the computer, the search filter cannot be recognized
  • The remote server machine does not exist or is unavailable
I want to replace anything that is not the name of the user with just "none" or something else. I am not very familiar with using RegEx. What is the easiest way to do this?
SoftPerfect Support forum - Ann avatar image
Ann

Re: Handling output for multiple error messages   06 August 2019, 22:53

It would not be easy to use a regular expression here since there are many possible error messages.

What you could do instead as add the following line at the beginning of your script:
On Error Resume Next
This will silently absorb all execution errors. You may still need to handle some errors in the code, depending on what exactly the script is doing.

Alternatively, you could set up a display filter via View - Setup Filter and hide the lines that contain error messages.

Reply to this topic

Sometimes you can find a solution faster if you try the forum search, have a look at the knowledge base, or check the software user manual to see if your question has already been answered.

Our forum rules are simple:

  • Be polite.
  • Do not spam.
  • Write in English. If possible, check your spelling and grammar.

Author:

Email:

Subject

A brief and informative title for your message, approximately 4–8 words:

     

Spam prevention: please enter the following code in the input field below.

 ********    *******    ******    **      **  **     ** 
 **     **  **     **  **    **   **  **  **  **     ** 
 **     **         **  **         **  **  **  **     ** 
 **     **   *******   **   ****  **  **  **  **     ** 
 **     **         **  **    **   **  **  **   **   **  
 **     **  **     **  **    **   **  **  **    ** **   
 ********    *******    ******     ***  ***      ***    

Message: