Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Lineing up Text in a string
Message
From
04/12/2006 12:36:01
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Lineing up Text in a string
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01174648
Message ID:
01174648
Views:
56
I am using the following to build a string:

tsoVars.getMiscString = ""
getMiscDataString = "Select * From webprddt6.tsotagtblm Where cono = '" + tsoVars.conumber + "'"

IF SQLEXEC(tsoVARS.as400con, getMiscDataString, "getMiscDataQuery") <> -1 Then
IF RECCOUNT("getMiscDataQuery") > 0 Then

SCAN
tsoVars.getMiscString = ALLTRIM(tsoVars.getMiscString) + PADR(ALLTRIM(getMiscDataQuery.partno),25) + " " + PADR(ALLTRIM(STRTRAN(getMiscDataQuery.seatdesc,","," ")),75) + " " + ALLTRIM(STR(getMiscDataQuery.partqty)) + ","

EndScan

tsoVars.getMiscString = SUBSTR(tsoVars.getMiscString,1,LEN(tsoVars.getMiscString)-1)
tsoVars.getMiscString = STRTRAN(tsoVars.getMiscString,",",CHR(13)+CHR(10))

ELSE
*Return "Unknown"
EndIf
Else
If Aerror(odbcerrormsg) > 0 Then
MessageBox(odbcerrormsg(2))
ENDIF
*Return "Unknown"
ENDIF

It gives me a string:

854121-401 Part1 3
854121-403S Part2 3
854121-1 Part3 3

How can I get the parts of the string to line up together?
Next
Reply
Map
View

Click here to load this message in the networking platform