Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Nice order to create
Message
From
18/03/2016 07:22:27
Lutz Scheffler
Lutz Scheffler Software Ingenieurbüro
Dresden, Germany
 
 
To
18/03/2016 06:34:04
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 8.1
Network:
SAMBA Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01633318
Message ID:
01633336
Views:
45
This will fail on the 5;03;10

but I guess I can do it from here. Antonios Code looks very nice for the transform and I will get an idea about the number of chgaracters per group.

Thank you (_ _)

>
>TEXT TO lcx NOSHOW  
>1
>10
>2
>03
>1.1
>12.R
>1.1.R
>1201.1.RBX.250.R.1
>1.R
>1.R.1
>A
>B
>AA
>5.R
>CDXB
>ENDTEXT &&lcx 
>
>STRTOFILE(lcx,'xyz.tmp')
>
>CREATE CURSOR curXYZ (cField c(40), cSortFld c(240))
>APPEND FROM xyz.tmp DELIMITED WITH TAB
>DELETE FILE xyz.tmp
>
>replace ALL cSortFld WITH IP_Ascii (cField)
>INDEX on cSortFld TAG cSortFld
>browse
>
>
>FUNCTION IP_ASCII(tcRow)
>LOCAL lnColLen, lnMaxCol, lnColCnt, laCols[1], lcErg, lcAdd, luCol
>lnColLen = 5
>lnMaxCol = 7
>lnColCnt = ALINES(laCols, UPPER(tcRow),1,".")
>lcErg = ""
>FOR lnCurCol = 1 TO lnMaxCol
>   lcAdd = IIF(lnColCnt>=lnCurCol,laCols[lnCurCol], "")
>    lcErg = m.lcErg + PADL(m.lcAdd, m.lnColLen, iif (EMPTY(m.lcAdd), CHR(45), IIF(ISAlpha(m.lcAdd), CHR(64), CHR(47)))) + "." 
>next
>RETURN m.lcErg
>
>
Words are given to man to enable him to conceal his true feelings.
Charles Maurice de Talleyrand-Périgord

Weeks of programming can save you hours of planning.

Off

There is no place like [::1]
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform