PDA

View Full Version : Set Variable & Append to Existing Value



NewsArchive
04-05-2011, 12:37 AM
Friedrich, Long time no see!

Got a quirky issue, and I am sure I am doing something wrong... however...

Set Variable %ABC% to "abc def ghi"
Set Variable %ABC% to " jkl" [Append Value]

This gives me "abc def ghijkl". Note the space is gone after ghi...

How do I get a space when I am adding onto a string?

Hope you are well,
-Glenn.

NewsArchive
04-05-2011, 12:37 AM
Hi Glenn

>Set Variable %ABC% to "abc def ghi"
>Set Variable %ABC% to " jkl" [Append Value]

The clipping of leading spaces in the set var has always been there and I have worked
around it by doing something like this...

Set Variable %ABC% to "abc def gh"
Set Variable %ABC% to "i jkl" [Append Value]

I hit this problem trying to build long command line params. Breaking the last word in
initial string works around the feature.

John Griffiths

NewsArchive
04-06-2011, 12:50 AM
I am fixing my code exactly like that.

So, our best friend Friedrich....
How about an option when you check "Append Value" that is an "Append
Character"?
Could give options like space, comma, pipe, tab... Could see a lot of value
in that.

Thanks,
-Glenn.

NewsArchive
04-06-2011, 12:50 AM
Glenn,

Unfortunately, this is caused by a compiler thing (and goes back to the year
2003). It always removes the leading spaces in script commands to function
properly. It's some kind of design issue and needs a rewrite.

I already played with the code all day, but it's in a very sensitive area of
the compiler system.

Friedrich

NewsArchive
04-06-2011, 12:50 AM
Friedrich,

> but it's in a very sensitive area of the compiler system.

Then, by all means, be very gentle!

--
Lee White

RPM Report Viewer.: http://www.cwaddons.com/products/rpm/
RPM Review........: http://www.clarionmag.com/cmag/v11/v11n06rpm.html
Report Faxing.....: http://www.cwaddons.com/products/afe/
---Enroll Today---: http://CWaddons.com

Enhanced Reporting: http://www.cpcs-inc.com


Product Release & Update Notices
http://twitter.com/DeveloperPLUS

NewsArchive
04-06-2011, 12:51 AM
Let him borrow your velvet glove.

--
Russell B. Eggen
www.radfusion.com
Clarion developers: www.radfusion.com/devs.htm

NewsArchive
04-06-2011, 12:51 AM
> Let him borrow your velvet glove.

Hahahaha...

Friedrich

NewsArchive
04-15-2011, 12:45 AM
Update: the installer runtime can handle leading spaces in the "Set
Variable..." and "Set VariableEx..." script functions now.

This will be available in the next maintenance build.

Thanks,
Friedrich

NewsArchive
04-19-2011, 02:22 AM
WOOHOO! You da man!
Thanks Friedrich!

Glenn Paschal