-SET &FIL='&EDATEMP.EVAL'||'test.trc'; -RUN -* SET TRACEUSER=&FIL.EVAL -RUN -? &
FILEDEF TRACE DISK &FIL.EVAL -RUN
APP PATH BASEAPP DEFINE FILE TRACE RESULT/A175 = SUBSTR(200,LINE,41,200,155,'A155'); END TABLE FILE TRACE PRINT RESULT WHERE LINE CONTAINS 'NGtrEvnt' WHERE (LINE CONTAINS '>' OR LINE CONTAINS '<' OR LINE CONTAINS '%3C' OR LINE CONTAINS '%3c' OR LINE CONTAINS '%3E' OR LINE CONTAINS '%3e' ) ; ON TABLE HOLD END -RUN
The logic works fine, Only issue is i want to suppress all the &variables when try to view the source by right clicking...
Thanks
webfocus 7x windows
February 25, 2011, 04:28 PM
Tom Flynn
Well, if they are just running Focexec's, out of luck, unless you render the output in HTMLFORM.
If through HTML, search Google, Javascript Disable right clck, plenty of stuff out there, and incorporate into HTML...
If not, the link I gave above relates how to turn it off..
search all the fexcodes with a read commando put the fex name and the line that holds the & value in a table make a report on the eind result
Frank
prod: WF 7.6.10 platform Windows, databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7 test: WF 7.6.10 on the same platform and databases,IE7
February 28, 2011, 04:39 AM
Computix
Hi,
you could do something like this:
SET &T = '-? &';
&T.EVAL
- You can set &T at runtime if you want traces and set it to empty if you don't.
Regards, Markus
WF 7.6.6 (MRE,BID, DevStudio, partly RC) on Windows 2003 /Apache/Tomcat Output: HTML,Excel,PDF,PPT Adapters: SQL Server, DB2, Oracle
February 28, 2011, 12:50 PM
dcs
Sorry Markus,That didnt help me.
Could you do it with some examples?
webfocus 7x windows
March 02, 2011, 04:17 AM
Computix
Hi,
I guess you have some kind of initialisation. There you can define a rule, when to activate the trace-Statement. For example you want the trace to be active if you are user1:
-SET &TRACE = IF &IBIMR_user EQ 'user1' THEN '-? &' ELSE '';
In your report you simply write where you want to see the traces:
&TRACE.EVAL
This way, if you are user1 you will see the traces, otherwise you do not see them. Regards, Markus
WF 7.6.6 (MRE,BID, DevStudio, partly RC) on Windows 2003 /Apache/Tomcat Output: HTML,Excel,PDF,PPT Adapters: SQL Server, DB2, Oracle
March 02, 2011, 06:17 AM
GamP
If I understand you correctly, you want the output of the -? & command to be put in the trace file, which you then can table to find all offending values. So far OK. But when that process is done you will have to send something back to the browser, but that will contain the result of the -? & command also, visible when doing a view source. And that is something you do not want. Did I undertstand this correctly? You could search for something to prevent doing a right mouse click but that is not 100 % sufficient, I guess. If you do not care what is being presented, as long as it is not the result, you could do something like this after finding ans saving the offending variables:
TABLE FILE SYSCOLUM
ON TABLE SET PREVIEW ON
SUM COMPUTE TOTALOFF/A50 = 'Number of offending variables found = &LINES'; AS ''
ON TABLE PCHOLD FORMAT PDF
END
There is no way to prevent the output of the values aother than outputting something that clears the html comments ... like PDF or XML or something like that.
GamP
- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
March 09, 2011, 12:26 PM
dcs
Thanks for the input guys, Still i am able to see the displayed values of -? &
So I've opened a ticket, such that to find a way to read all the active variables in a file rather than using '-? &' command. They are still researching on it.
webfocus 7x windows
March 09, 2011, 01:22 PM
Francis Mariani
I don't get the point of this. First you want to "suppress the -? & command", then you want to "trace all the & variables", sounds like opposites. Then you want to "read all the variables and scan for unwanted codes" with which you probably mean "read all the code to look for unwanted code".
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