Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Giovane
Creator
Creator

Loading a Spreadsheet - Testing Before Loading

I'm loading a spreadsheet on a station outside the server, and I want for testing the connection between the server and the station before the load statement to be performed. This will be done to prevent an error. The idea is: If the connection is active, the load is performed, else the load statement is jumped, and the rest of the script continues  How can I do that?

Thanks a lot !!!

Giovane

1 Solution

Accepted Solutions
MindaugasBacius
Partner - Specialist III
Partner - Specialist III

I think this is exactly what you wish:

SET ErrorMode=0;

CONNECTION STATEMENT

SET ErrorMode=1;


It simply ignores the errors that occurs on connection statement and moves on to the rest of the script.

I suggest you reading more about ErrorMode and ScriptError variables:

https://help.qlik.com/en-US/qlikview/12.0/Subsystems/Client/Content/Scripting/ErrorVariables/ErrorMo...

https://help.qlik.com/en-US/qlikview/12.0/Subsystems/Client/Content/Scripting/ErrorVariables/ScriptE...

View solution in original post

2 Replies
MindaugasBacius
Partner - Specialist III
Partner - Specialist III

I think this is exactly what you wish:

SET ErrorMode=0;

CONNECTION STATEMENT

SET ErrorMode=1;


It simply ignores the errors that occurs on connection statement and moves on to the rest of the script.

I suggest you reading more about ErrorMode and ScriptError variables:

https://help.qlik.com/en-US/qlikview/12.0/Subsystems/Client/Content/Scripting/ErrorVariables/ErrorMo...

https://help.qlik.com/en-US/qlikview/12.0/Subsystems/Client/Content/Scripting/ErrorVariables/ScriptE...

Giovane
Creator
Creator
Author

Thank you, Mindaugas...you got it right. Problem solved !!!

Thanks a lot.

Giovane