I am working on display of customized error handling for the foc errors. I am able to handle the errors that populates with respect fields or no data senarios. But i am not able to display a custoimized message for " (FOC295) A VALUE IS MISSING FOR: &SEATS". Could someone help me with this
Example: -*-SET &SEATS= 2; -SET &ECHO = ALL;
TABLE FILE CAR PRINT COUNTRY CAR WHERE SEATS EQ &SEATS END
-IF &FOCERRNUM NE 0 THEN GOTO LBL_NODATA ELSE GOTO CONT;
-LBL_NODATA -INCLUDE ERROR_PAGE -CONT -EXIT
I am un able to display the cutomized error message for missing parameter value.This message has been edited. Last edited by: <Kathryn Henning>,
WebFOCUS 7.6.9 Windows all output (Excel, HTML, PDF)
May 21, 2013, 11:01 AM
ebaig
There are probably more elegant ways of doing this, but you could try something like:
You can also test for the existence of the variable:
-IF &VAR1.EXISTS EQ 0 GOTO ERR1 ELSE GOTO GOOD;
quote:
.EXIST tests for the presence of a value. If a value is not present, a zero (0) is passed to the expression. Otherwise, a non-zero value is passed.
Francis
Give me code, or give me retirement. In FOCUS since 1991
Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
May 21, 2013, 01:43 PM
Pri
Thank you so much it worked !!
WebFOCUS 7.6.9 Windows all output (Excel, HTML, PDF)
May 21, 2013, 05:47 PM
Waz
Pri, I would strongly suggest that you use -RUN before any test of &FOCERRNUM. This is because of the order of evaulation of Dialog Manager and FOCUS code.