----Formshow
NewPath: = '/storage/sdcard0/dcim/100andro/grjkdaglgxysf ';
If not tdirectory.exists (NewPath) THEN BEGIN
Tdirectory.createdirectory (NewPath); Create a folder
End
NewPath: = NewPath + '/';
----Deposit to this machine
Var
filename:string;
Newfile:tfilestream;
Begin
FileName: = ' update_sf_ ' + formatdatetime (' Yyyy-mm-dd ', now) + Gxyglkid;
NewFile: = tfile.create (NewPath + filename);
NewFile. Free;
Clientdatasetlocal. SaveToFile (NewPath + filename,dfxml);
End
---Create a file
Var
newpath:string;
Newfile:tfilestream;
Begin
NewPath: = '/STORAGE/SDCARD0/DCIM/100ANDRO/GRJKDAGLF ';
If tfile.exists (NewPath + '/update.xml ') THEN BEGIN
ShowMessage (' File exists ');
End
ELSE begin
NewFile: = tfile.create (NewPath + '/update.xml '); Create a file (stream)
NewFile. Free; Clear Stream
Speedbutton5click (self); Close the window
TotalWork (path, True); Update the list
End
---Create a file path
Var
newpath:string;
Begin
NewPath: = '/STORAGE/SDCARD0/DCIM/100ANDRO/GRJKDAGLF ';
ShowMessage (NewPath);
If Tdirectory.exists (NewPath) THEN BEGIN
ShowMessage (' Folder exists! ');
End
ELSE begin
Tdirectory.createdirectory (NewPath); Create a folder
ShowMessage (' Folder created! ');
Speedbutton5click (self); Close the window
TotalWork (path, True); Update the list
End
This article is from the "All for the law, such as Fleeting Dream" blog, please be sure to keep this source http://kaixinbuliao.blog.51cto.com/2567365/1535172