Page 1 of 1

Check Values number

Posted: August 6th, 2024, 12:54 am
by Arjun Brti
Dear experts

I want to check the value number in any process. For example, I write a logic in Q05: if Q02 = 9 then skip to Q08; endif;. But there is not value 9 in Q02 yet. When I compile the logic, it does not show the error like "there is no value 9 in Q02". How can we check this on CSPro?

Thank you.

-Btri

Re: Check Values number

Posted: August 6th, 2024, 4:21 am
by vgonzalez
Colleague, please try to check the sequence of the fields entered, otherwise I can recommend you to use the VISUALVALUE function.

https://www.csprousers.org/help/CSPro/ ... tion.html


For example:

Code: Select all

	if visualvalue(Q02) = 9 then 
		skip to Q08; 
	endif;

Re: Check Values number

Posted: August 6th, 2024, 12:52 pm
by sherrell
Hi Btri,

A compilation of your CSPro logic only means that your logic is correct--any number of things can go wrong with that logic during execution.

But I'm not following the problem. Is field Q02 captured before field Q05 is captured ? If so, then the value of Q02 will be available when you reach the logic in PROC Q05.

Do you want to capture data for Q05 when Q02=9?
  • If yes, then place your logic in the postproc of Q05.
  • If no, then place your logic in the preproc of Q05.
Sherrell