TheEntertainer
MIS
Dear All,
Well there not really strange just not what I've seen before.
I've come across a couple of formulas in some sample Crystal Reports and I'm just wondering what it is they are doing and what language they are referencing.
Here is the first example, which I don't know what its doing:
and the Here is the second, which I've partly figured out is using wingdig format to display a colour coded circle on screen:
Cheers
![[afro] [afro] [afro]](/data/assets/smilies/afro.gif)
Well there not really strange just not what I've seen before.
I've come across a couple of formulas in some sample Crystal Reports and I'm just wondering what it is they are doing and what language they are referencing.
Here is the first example, which I don't know what its doing:
Code:
whileprintingrecords;
shared numbervar objid;
"<script>"
+ "function openupcsp() {"
+ "var url ='/crystal/enterprise10/adhoc/mainframes.csp?isAdmin=false&mode=interactive&fromeportfolio=false&currID=" + totext(objid,0,"") + "&tab=report';"
+ "var features = 'scrollbars=no,status=no,location=no,resizable=yes,width=0,height=0,left=0,top=0';"
+ "window.open(url,'',features);"
+ "}"
+ "</script>"
+ "<a class=EmbeddedLink href=""javascript:openupcsp()"" style='color: #1f4399'>"
+ ">> VIEW EMPLOYEE TERMINATIONS"
+ "</a>"
+ Chr(13) + "<A href=""javascript:"" style='display:none'"
and the Here is the second, which I've partly figured out is using wingdig format to display a colour coded circle on screen:
Code:
numbervar input;
numbervar lower;
numbervar upper;
lower:= 50;
upper:= 59;
input:= round({@Grading Alert Value},0);
stringvar S;
stringvar A;
stringvar G;
if input <= lower then (stringvar S:="cf1";stringvar A:="cf5";stringvar G:="cf6");
if input in lower to upper then (stringvar S:="cf4";stringvar A:="cf2";stringvar G:="cf6");
if input >= upper then (stringvar S:="cf4";stringvar A:="cf5";stringvar G:="cf3");
"{\rtf1\ansi{\fonttbl{\f0\fnil\fcharset2 Wingdings;}}" +
"{\colortbl;\red214\green34\blue38;\red220\green205\blue55;\red0\green142\blue50;\red0\green0\blue0;\red0\green0\blue0;\red0\green0\blue0;}" +
"\viewkind4\uc1\pard\f0\fs28\qc\" + S + " l" +
"\par\" + A + " l" +
"\par\" + G + " l?" +
"\par" + "}"
Cheers
![[afro] [afro] [afro]](/data/assets/smilies/afro.gif)