on 01-27-2010 3:24 PM
Hi all,
I would like to have a global variable to use for formatting log entries. It would be something like this which is from an
assignment action: datenow & tab & "APPNAME: "
Is it possible?
--Thanks
--Amy Smith
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Here is what I get in the log. It looks like it takes the global variables as constants.
I defined logPrefix as this: datenow & tab & IllumLoginName & tab & "APEX" & tab
Write Action Block writes this:
Globals.logPrefix & "Confirm and Pack: Failed with Confirm message:" & Create_Time_Ticket.LastErrorMessage & crlf
And got this in the log:
datenow & tab & IllumLoginName & tab & "APEX" & tabConfirm and Pack: Failed with Confirm message:
It looks like it takes the global variables as constants. I was hoping there was some coding like {} or ## that would allow variables.
Why? To have a fixed prefix for every log record written without having to remember what it is and type it all in correctly for EVERY log record.
--Amy Smith
--Haworth
I DID
IllumLoginName doesn't get translated.
Seems what you are implying is that it will be translated if it is in the first position of the global. Is that what you mean?
Thanks for your help. I would like to know from someone who has done this and had it work or knows that it doesn't work.
--Amy Smith
--Haworth
Amy,
the global variable is a fixed value you can use in all BLTs but which is not interpreted.
To have a "global" log prefix, I guess a small helper BLT should work which you can call and which returns the prefix you want.
The IllumLoginName is only available in your BLT if the Autobind is on like Chanti described and if the BLT is called from a Xacute query from the web.
Hope this helps.
Michael
User | Count |
---|---|
12 | |
7 | |
3 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.