Exporting more than one line of text in a fld
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
- Posts: 78
- Joined: Fri Oct 03, 2008 10:13 am
Exporting more than one line of text in a fld
I am trying to export text from a stack to a vb file , one of the fields has two lines of text in it, the problem is that when i try to send the data both lines are included in the string, starting and ending with a " but because i use a cr to put it into two lines it wont send it, i need each line to start and end with "
i can send it as one line ok but when i use return to put it into two lines it wont send
i hope someone knows what i mean
wee wullie
i can send it as one line ok but when i use return to put it into two lines it wont send
i hope someone knows what i mean
wee wullie
Re: Exporting more than one line of text in a fld
Hi wullie,
for storing (or sending or whatever) multiline text in ONE line, I always "urlEncode" the string.
And later "urlDecode" it to get the multiline text back.
No problem if you urlEncode and then urlDecode a one-liner
Best
Klaus
for storing (or sending or whatever) multiline text in ONE line, I always "urlEncode" the string.
And later "urlDecode" it to get the multiline text back.
No problem if you urlEncode and then urlDecode a one-liner

Best
Klaus
-
- Posts: 78
- Joined: Fri Oct 03, 2008 10:13 am
Re: Exporting more than one line of text in a fld
Hi Klaus, i tried to use urlencode for the entire string and just the variable and it doesn't seem to work, this is the string:
perhaps i'm missing something
Code: Select all
put "Tr Type:" && the selectedText of btn "TrType" of stack "myStack" & cr & "Tk Type:" && the Text of fld "TkType" of stack "myStack" into tParr
Re: Exporting more than one line of text in a fld
WHAT did you try?
Something like this:
...
put "Tr Type:" && the selectedText of btn "TrType" of stack "myStack" & cr & "Tk Type:" && the Text of fld "TkType" of stack "myStack" into tParr
put urlEncode(tParr) into tVarWith_the_ONE_liner
...
?
Need to look at the script(s), since this has been working for many, many years for me
Something like this:
...
put "Tr Type:" && the selectedText of btn "TrType" of stack "myStack" & cr & "Tk Type:" && the Text of fld "TkType" of stack "myStack" into tParr
put urlEncode(tParr) into tVarWith_the_ONE_liner
...
?
Need to look at the script(s), since this has been working for many, many years for me

Re: Exporting more than one line of text in a fld
You can of course urlencode your string directly, no need for an extra variable:
...
put urlencode("Tr Type:" && the selectedText of btn "TrType" of stack "myStack" & cr & "Tk Type:" && the Text of fld "TkType" of stack "myStack") into tParr
...

...
put urlencode("Tr Type:" && the selectedText of btn "TrType" of stack "myStack" & cr & "Tk Type:" && the Text of fld "TkType" of stack "myStack") into tParr
...

-
- Posts: 78
- Joined: Fri Oct 03, 2008 10:13 am
Re: Exporting more than one line of text in a fld
Hi Klaus, i tried to use this:
i think this is the direct way
Code: Select all
on mouseUp
open stack "FTdoc"
put "FTr" && "--" && fld "firstname" of stack "FTDoc" && fld "lastname" of stack "FTDoc"into fld "Subject" of stack "myStack"
put urlencode( "TrType:" && the selectedText of btn "TrType" of stack "FTDoc" & cr & "TkType:" && the Text of fld "TkType" of stack "FTdoc") into tParr
put tParr into fld "Body" of stack "myStack"
end mouseUp
Re: Exporting more than one line of text in a fld
Well, that's what I wrote in my last posting 

-
- Posts: 78
- Joined: Fri Oct 03, 2008 10:13 am
Re: Exporting more than one line of text in a fld
Indeed it certainly was Klaus
its good that you can use both methods, transcript is very flexible, i love it!!!
cheers Klaus

its good that you can use both methods, transcript is very flexible, i love it!!!
cheers Klaus
Re: Exporting more than one line of text in a fld
Hi wullie,
well, sometimes it is desired to use an "intermediate" variable,
e.g. this way you can see what's in that string/variable when debugging!
Best
Klaus
well, sometimes it is desired to use an "intermediate" variable,
e.g. this way you can see what's in that string/variable when debugging!
Best
Klaus