| |
 |
|
| Computers Forum Index » Computer - Databases - Filemaker » Escape $ to insert the actual vaue of the variable in... |
|
Page 1 of 1 |
|
| Author |
Message |
| Diego B... |
Posted: Sun Oct 11, 2009 9:20 pm |
|
|
|
Guest
|
Hi all,
I have a very simple script (FM 10 adv Win XP) that is supposed to
send a mail regularly, and it works fine.
I would like to insert some numbers in the body of the mail. These
numbers are stored in 2 variables:
$NbNewRecords (= SomeField)
$NbGrandTotal (= SomeOtherFiled)
The message would be something like:
"Hello, in the last month we had $NbNewRecords enrollments, thus to
date, the total number is $NbGrandTotal"
Obviously, I would like to replace the $... with the actual number but
I cannot get it.
I tried different escape characters: \, ", or "" but I get something
like:
$NbNewRecords
$NbGrandTotal
or
"$NbNewRecords"
"$NbGrandTotal"
Might you help in this ?
Thanks always !
Diego |
|
|
| Back to top |
|
|
|
| Grip... |
Posted: Mon Oct 12, 2009 12:07 am |
|
|
|
Guest
|
On Oct 11, 3:20 pm, Diego B <messa... at (no spam) yahoo.it> wrote:
Quote: Hi all,
I have a very simple script (FM 10 adv Win XP) that is supposed to
send a mail regularly, and it works fine.
I would like to insert some numbers in the body of the mail. These
numbers are stored in 2 variables:
$NbNewRecords (= SomeField)
$NbGrandTotal (= SomeOtherFiled)
The message would be something like:
"Hello, in the last month we had $NbNewRecords enrollments, thus to
date, the total number is $NbGrandTotal"
Obviously, I would like to replace the $... with the actual number but
I cannot get it.
I tried different escape characters: \, ", or "" but I get something
like:
You don't need to escape the variable, you're combining text strings
with variables. Concatenation is handled with an ampersand:
"Hello, in the last month we had " & $NbNewRecords & " enrollments,
thus to date, the total number is " & $NbGrandTotal "."
G |
|
|
| Back to top |
|
|
|
| Your Name... |
Posted: Mon Oct 12, 2009 4:16 am |
|
|
|
Guest
|
"Grip" <grip at (no spam) cybermesa.com> wrote in message
news:124cf4b5-a075-4cc7-aa0b-8cc30a3ba72f at (no spam) o9g2000prg.googlegroups.com...
On Oct 11, 3:20 pm, Diego B <messa... at (no spam) yahoo.it> wrote:
Quote:
You don't need to escape the variable, you're combining text strings
with variables. Concatenation is handled with an ampersand:
"Hello, in the last month we had " & $NbNewRecords & " enrollments,
thus to date, the total number is " & $NbGrandTotal "."
Oops! A typo - you left out one concatenation & just before the "." at the
end.
i.e.
Hello, in the last month we had " & $NbNewRecords & " enrollments,
thus to date, the total number is " & $NbGrandTotal & "."
Helpfull harry ) |
|
|
| Back to top |
|
|
|
| Diego B... |
Posted: Mon Oct 12, 2009 12:42 pm |
|
|
|
Guest
|
On Oct 11, 7:16 pm, "Your Name" <your.n... at (no spam) isp.com> wrote:
Quote: "Grip" <g... at (no spam) cybermesa.com> wrote in message
news:124cf4b5-a075-4cc7-aa0b-8cc30a3ba72f at (no spam) o9g2000prg.googlegroups.com...
On Oct 11, 3:20 pm, Diego B <messa... at (no spam) yahoo.it> wrote:
You don't need to escape the variable, you're combining text strings
with variables. Concatenation is handled with an ampersand:
"Hello, in the last month we had " & $NbNewRecords & " enrollments,
thus to date, the total number is " & $NbGrandTotal "."
Oops! A typo - you left out one concatenation & just before the "." at the
end.
i.e.
Hello, in the last month we had " & $NbNewRecords & " enrollments,
thus to date, the total number is " & $NbGrandTotal & "."
Helpfull harry  )
Great !
Thank you so much for the advice, it works like a champ : )
Diego |
|
|
| Back to top |
|
|
|
| Bizouman... |
Posted: Tue Oct 13, 2009 1:19 am |
|
|
|
Guest
|
On 12 oct, 08:42, Diego B <messa... at (no spam) yahoo.it> wrote:
Quote: On Oct 11, 7:16 pm, "Your Name" <your.n... at (no spam) isp.com> wrote:
"Grip" <g... at (no spam) cybermesa.com> wrote in message
news:124cf4b5-a075-4cc7-aa0b-8cc30a3ba72f at (no spam) o9g2000prg.googlegroups.com...
On Oct 11, 3:20 pm, Diego B <messa... at (no spam) yahoo.it> wrote:
You don't need to escape the variable, you're combining text strings
with variables. Concatenation is handled with an ampersand:
"Hello, in the last month we had " & $NbNewRecords & " enrollments,
thus to date, the total number is " & $NbGrandTotal "."
Oops! A typo - you left out one concatenation & just before the "." at the
end.
i.e.
Hello, in the last month we had " & $NbNewRecords & " enrollments,
thus to date, the total number is " & $NbGrandTotal & "."
Helpfull harry  )
Great !
Thank you so much for the advice, it works like a champ : )
Diego
Is there any way to add the variable into merge field ??
<<table::field>> & $variable <<table::field2>> ???
Or it's another no do with FM10 and will be in FM12 ?? :O) |
|
|
| Back to top |
|
|
|
|
|
All times are GMT
The time now is Sun Nov 22, 2009 6:23 am
|
|