Hi everyone,
I have two fields on my card and was wondering if there was any way to get the fields to show a variable that I have defined. I want one of the fields to show the variable itself and the other field to show the variable - 50. I tried using
set field "fieldname" to sVariableName
set field "fieldname" to sVariableName - 50
but I got no success with this and the script wouldnt even run. Does anyone have any suggestions. Any help is much appreciated. Thank you!
Setting a field equal to a variable
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Re: Setting a field equal to a variable
Hi,
try:
you would use the "set some property to some value" only on properties, otherwise you use the "put something into something" syntax.
in your case:
field "fieldName" is a container, you put things into containers.
the borderwidth of field "fieldName" is a property. you would "set the borderwidth of field "fieldName" to tVariable.
It might be a bit confusing but you will get a feeling for when to use which form.
Kind regards
Bernd
try:
Code: Select all
put sVariableName into field "fieldName"
put sVariableName - 50 into field "fieldName"
in your case:
field "fieldName" is a container, you put things into containers.
the borderwidth of field "fieldName" is a property. you would "set the borderwidth of field "fieldName" to tVariable.
It might be a bit confusing but you will get a feeling for when to use which form.
Kind regards
Bernd
-
- Posts: 77
- Joined: Thu Dec 08, 2011 12:19 pm
Re: Setting a field equal to a variable
That worked perfect, thanks BN!