Hello,
I have developed a global script which will get the page and controlname like
script(char p_sPage, char p_sCtrl).
Now i hide the control in the script with
interpret 'hide ' + p_sCtrl+ ' on ' + p_sPage;
works fine. How can I set text with the same technique.
interpret 'set ' + sWelcome + '.text = \'Bla\'' + ' on ' + p_sPageName;;
Will not work, cause there is no on page clause in a set.
a
"interpret 'set ' + sWelcome + '.text = \'Bla\'';" (without on page) will lead to the error:
Script EXECUTEREFRESHLINK: Invalid fieldname
because the global script is called from another page.
Can someone help me?
Cheers
Pnirff
Setting text in a global script
Moderators: Jon, Steve, Ian, Dave
-
- Moderator
- Posts: 1342
- Joined: Wed Sep 12, 2007 12:49 pm
With FPL you can only change a text using its text reference id - double click on any text and you'll see this at the bottom of the screen. So your command would be something like:
You could make this into a global script like this:
but I'm not sure it's worth the effort.
With the Javascript scripting language (available from Ebase V4.4) , you have many more possibilities.
Code: Select all
set text TXT212 = 'new text';
Code: Select all
script(char textref, char text)
interpret 'set text ' + textref + '= \'' + text + '\'';
With the Javascript scripting language (available from Ebase V4.4) , you have many more possibilities.
0 x
Who is online
Users browsing this forum: No registered users and 23 guests