Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Replace question
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00136915
Message ID:
00137428
Views:
15
ALLTRIM should work. TRIM should not work. A string that was created using STR() is now just a character string like any other character string. All string manipulation functions should work as advertised.

>Joseph,
>
>I found what my trouble was, and it was a rookie mistake. Here it is:
>
>lnATAFValue = EVAL('xtab.'+lcFName)
>lcATAFValue = STR(lnATAFValue) &&convert from numeric to character
>SELECT ATA_Report
>GO BOTTOM
>REPLACE (lcATAFName) WITH LTRIM(lcATAFValue)
>I tried trim() and alltrim() they didn't work. With the LTRIM() function it removed the blank spaces from the string. Apparently, only L(or R)TRIM(), is the only way to remove blank spaces from a character string that has been created with STR().
>
>Thanks for everyone's suggestions
>
>
>>Perry, have you set a breakpoint and done the usual things like watching any variables that apply, browsing the table before the replace, browsing the table after the replace, etc? Frankly, there have been some suggestions that have been all but ignored and this is either a simple problem (wrong work area selected, not pointing at a record, variable is not what you expect) or a big problem (your installation of VFP doesn't work), so maybe you could try some of the suggestions and report your findings here.
>>
Joseph C. Kempel
Systems Analyst/Programmer
JNC
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform