| |
|
|
- Page 1 - |
|
Uwe Lang | I have in my Program with the List view.dll one List view prepares. now would like I the Content as CSV Save file together with the Header the scheduler. How must I the Speicherbereich of HeaderToCSV (lvhed#) in WriteFileQuick install so the Header and the Tabelleninhalt together in a File stored becomes? night etlichen erfolglosen try white I do not moreover.
Proc CSV_Speichern
Declare tx$,xs&,lvber#,hd&,lvhed#
Dim lvhed#,1848'amount Split * 264
tx$ = datname$
xs&=GetNeededMemory(lv&,1)
Dim lvber#, xs&
hd&=HeaderToCsv(lv&,lvhed#,59,1)
xs&=ListviewToCsv(lv&,lvber#,59,1)
WriteFileQuick(addr(tx$),lvber#,0,(hd& + xs&))
Dispose lvber#
Dispose lvhed#
ENDPROC
|
|
|
| |
|
|
|
« this Posting watts as Solution marked. » |
|
H.Brill | How I see, have you got indeed XProfan X3. one can thoroughly one List view, with the the List view.dll prepares been is, with XProfans own functions Edit. its so neither absolutely prescribed, whom Content the List view in a Speicherbereich To schieben, circa this then with WritFileQuick() To Save. into subesquent Procs use I The marvellous new Move-functions :
Proc load
Declare Int bytes1, bytes2
Declare String Header
ClearList 0
Move("FileToList", File)
Header = GetString$(0, 0)' here have you got The Headerzeile
DeleteString(0, 0)
' The Headerzeile simply in Header Save and the
' Listboxliste delete. now can you with the Header
' make, what You vorhast or want.
ClearList grid
Move("ListToHandle", grid)
ENDPROC
Proc save
Declare Memory area1
Dim area1, 256
Declare Int bytes1, bytes2, anzahlColumns
Declare String Header
anzahlColumns = GetColumns(grid)
WhileLoop 0, anzahlColumns - 1
Clear area1
GetColumnName(grid, area1, &LOOP)
If &LOOP < (anzahlColumns - 1)
Header = Header + String $(area1, 0) + ","
Else
Header = Header + String $(area1, 0)
EndIf
EndWhile
ClearList 0
AddStrings(0, Header)
Move("HandleToList", grid)
Move("ListToFile", File)
Messagebox(File + " gespeichert", "Info", 0)
Dispose area1
ENDPROC
the lever grid is a with the List view.dll erstelltes List view. the works by me wonderful. How one sees, can The advantages list view.dll (editierbare boxes, PrintListview etc.) with the new Vorteilen of XProfan X3 lovely join. the goes too differently rum, means a with XProfan erstellte GridBOX and the functions list view.dll.
PS : whether there now one comma or one | between whom Einträgen standing, might alike his. If it you disturbing, can you tappt im dunkeln Yes replace. I hope, I could you something help. |
|
|
| Benutze XPROFAN X3 + FREEPROFAN Wir sind die XProfaner. Sie werden von uns assimiliert. Widerstand ist zwecklos! Wir werden alle ihre Funktionen und Algorithmen den unseren hinzufügen.
Was die Borg können, können wir schon lange. | 09/20/15 ▲ |
|
|
|
|
|
| How I the see writes writefilequick 1 memory in 1 File.
Reserviere you 1 memory so big How lvhed# and lvber# together.
copy lvhed# and lvber# into new memory.
writefilequick new memory.
code ungetestet here simply reingepinselt only to that understanding. |
|
|
| |
|
|
|
Uwe Lang | thanks for speedy response, had I in similar shape already. with the same Result, the Header becomes written and thereafter becomes the Content the data base utterly moved. the sees so from as though The Size the Speicherbereichs the Headers larger is as accounts b.z.w pretended. I must over the trouble once more in silence cogitate. |
|
|
| |
|
|
|
H.Brill | lvhead# is indeed not big enough. best is it, The Number of tatsächlichen Split To detect. Also are The Kommas (amount decompose - 1) moreover To calculate. If as Flag with HeaderToCSv() yet The quotation marks moreover come (Flag = 0) must You too yet per slot two " mitrechnen. Also is yet the Nullbyte end the Strings in the area moreover To count.
very these amount bring you then HeaderToCsv(). there one whom area decompose * 264 + The zus. Kommas etc.take must (with GetColumns(H) get one Yes The amount Split the Grid out), would it on the best, a self-contained area with the Result of HeaderToCsv() To dimmen and soviele Bytes of middle-aged area into new To copy.
i think time, this is the Sicherste. |
|
|
| Benutze XPROFAN X3 + FREEPROFAN Wir sind die XProfaner. Sie werden von uns assimiliert. Widerstand ist zwecklos! Wir werden alle ihre Funktionen und Algorithmen den unseren hinzufügen.
Was die Borg können, können wir schon lange. | 09/15/15 ▲ |
|
|
|
|
Uwe Lang | I come first now moreover To Answer, so How I the trouble solve wished have I not hinbekommen. I have the whole first once as Notlösung so made, that I into List view a vain row on position 0 einfüge and thereafter The Spaltenköpfe choose and the Text into suitable boxes eintrage. After the Save entferne I The row again from the List view. the short Geruckel falls not, I to the Save yet Data from another List view hineinkopiere. nevertheless thanks for Notes. If I again little more Time have, I will me the trouble once more look at. |
|
|
| |
|
|
|
H.Brill | How I see, have you got indeed XProfan X3. one can thoroughly one List view, with the the List view.dll prepares been is, with XProfans own functions Edit. its so neither absolutely prescribed, whom Content the List view in a Speicherbereich To schieben, circa this then with WritFileQuick() To Save. into subesquent Procs use I The marvellous new Move-functions :
Proc load
Declare Int bytes1, bytes2
Declare String Header
ClearList 0
Move("FileToList", File)
Header = GetString$(0, 0)' here have you got The Headerzeile
DeleteString(0, 0)
' The Headerzeile simply in Header Save and the
' Listboxliste delete. now can you with the Header
' make, what You vorhast or want.
ClearList grid
Move("ListToHandle", grid)
ENDPROC
Proc save
Declare Memory area1
Dim area1, 256
Declare Int bytes1, bytes2, anzahlColumns
Declare String Header
anzahlColumns = GetColumns(grid)
WhileLoop 0, anzahlColumns - 1
Clear area1
GetColumnName(grid, area1, &LOOP)
If &LOOP < (anzahlColumns - 1)
Header = Header + String $(area1, 0) + ","
Else
Header = Header + String $(area1, 0)
EndIf
EndWhile
ClearList 0
AddStrings(0, Header)
Move("HandleToList", grid)
Move("ListToFile", File)
Messagebox(File + " gespeichert", "Info", 0)
Dispose area1
ENDPROC
the lever grid is a with the List view.dll erstelltes List view. the works by me wonderful. How one sees, can The advantages list view.dll (editierbare boxes, PrintListview etc.) with the new Vorteilen of XProfan X3 lovely join. the goes too differently rum, means a with XProfan erstellte GridBOX and the functions list view.dll.
PS : whether there now one comma or one | between whom Einträgen standing, might alike his. If it you disturbing, can you tappt im dunkeln Yes replace. I hope, I could you something help. |
|
|
| Benutze XPROFAN X3 + FREEPROFAN Wir sind die XProfaner. Sie werden von uns assimiliert. Widerstand ist zwecklos! Wir werden alle ihre Funktionen und Algorithmen den unseren hinzufügen.
Was die Borg können, können wir schon lange. | 09/20/15 ▲ |
|
|
|
|
H.Brill | here another Abfallprodukt, circa rather Stringadressen in a area To shovel, where vorteilhaft is, that it too I really goes. is anyway plainer, as particular with the Bereichsbefehlen To hantieren. SItem() list view.dll desires Yes something like :
SUBPROC Move.StringAdrToMem
Parameters String s, String d, Memory B
' s = the zusammengesetzte String
' d = the Trenner
' B = the area
Declare Long number
Declare String TArray[]
ClearList 0
Clear B, TArray[]
number = Move("StrToList", s, d)
number = Move("ListToArr", TArray[])
Var Int z = 0
WhileLoop 0, number - 1
Long B, z = Addr(TArray[&LOOP])
Inc z, 4
EndWhile
Return number
ENDPROC
Declare Memory area
Dim area, 12' for 3 Stringadressen
Clear area
Move("StringAdrToMem", "Maier,Hamburg,4711", ",", area)
SItem(grid, area, 3)
Clear area
entry = "Müller,Berlin,4714"
Move("StringAdrToMem", entry, ",", area)
SItem(grid, area, 3)
Perhaps can it Yes someone need. |
|
|
| Benutze XPROFAN X3 + FREEPROFAN Wir sind die XProfaner. Sie werden von uns assimiliert. Widerstand ist zwecklos! Wir werden alle ihre Funktionen und Algorithmen den unseren hinzufügen.
Was die Borg können, können wir schon lange. | 09/21/15 ▲ |
|
|
|
|
| certainly, but here in this Topic would it it Yes not find.
rather here with whom Quelltexten post: [...] |
|
|
| |
|
|
|
H.Brill | there have you got right. though I do not white, Why obiges functions. having to some Time the ausprobiert and was astonishes. usually should still to the Proc or. SubProc the TArray[] again released been his or. not More existieren. the TArray[] is Yes pub definiert. accordingly should too The Stringadressen in this not More existieren. nevertheless can tappt im dunkeln outside benefit.
I could me not more than think, that these Arrays nevertheless global are.
or has otherwise yet someone a Statement for ? |
|
|
| Benutze XPROFAN X3 + FREEPROFAN Wir sind die XProfaner. Sie werden von uns assimiliert. Widerstand ist zwecklos! Wir werden alle ihre Funktionen und Algorithmen den unseren hinzufügen.
Was die Borg können, können wir schon lange. | 09/21/15 ▲ |
|
|
|
|
| there's there naturally several Mgl.
to exclude is vlt, that with:
proc so declare lala[] the lala of Roland global as __int__proc_so_lala[] processing becomes because otherwise would z.B. Rekursion not functions. functions tappt im dunkeln?
I wealth sooner, that here windows does what it always does: Speicherhandle enable but Speicherinhalt thereby not antasten and simply überschreiben if time again needed.
or Roland has simply again one own management drübergelegt. |
|
|
| |
|
|
|
H.Brill | I faith, with your supposition with windows have you got right. Have time something played :
Declare Long t[]
Cls
TesteArray()
Print
Print t[0], String $(t[0], 0)
Print t[1], String $(t[1], 0)
Print "Addresse : "; t[0]; " Content : "; String $(t[0], 0)
Print "Addresse : "; t[1]; " Content : "; String $(t[1], 0)
Print t[0], String $(t[0], 0)
Print t[1], String $(t[1], 0)
WaitKey
End
Proc TesteArray
Declare String lokalarray[]
lokalarray[0] = "Hallo"
lokalarray[1] = "Welt"
WhileLoop 0, 1
Print lokalarray[&LOOP]
t[&LOOP] = Addr(lokalarray[&LOOP])
EndWhile
Clear lokalarray[]
ENDPROC
means, leave can itself hereon not. the sees one, if over again Strings ("blabla") with in that game come. therefore is caution geboten, if between Proc-appeal and Weiterverabeitung yet what other made becomes. |
|
|
| Benutze XPROFAN X3 + FREEPROFAN Wir sind die XProfaner. Sie werden von uns assimiliert. Widerstand ist zwecklos! Wir werden alle ihre Funktionen und Algorithmen den unseren hinzufügen.
Was die Borg können, können wir schon lange. | 09/22/15 ▲ |
|
|
|
|
Uwe Lang | After längerer absence come I first now again moreover, me the trouble once more To consecrate. I have now The supra beschriebene Variante chosen and everything with the XProfan Bordmitteln resolved.
my Thanks all, The me with the suggestions helped having. |
|
|
| |
|
|