forum.vdsworld.com Forum Index forum.vdsworld.com
Visit VDSWORLD.com
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


simple vdsflist.dll command help please, $$$

 
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help
View previous topic :: View next topic  
Author Message
vtol
Valued Contributor
Valued Contributor


Joined: 05 Feb 2004
Posts: 656
Location: Eastern Indiana

PostPosted: Wed Apr 14, 2004 2:58 am    Post subject: simple vdsflist.dll command help please, $$$ Reply with quote

I need just simple help with the command help of vdsflist.dll.

I have everything pritty close, but I get ERROR on the running of the DLL command, see if you see my simple mistake in below example script please.

ERROR = Invalid Command at line 39...
line 39 = DLL FLIST, LIST,%%loadfile_files


Code:
OPTION DECIMALSEP, "."
#define command,flist
#define function,flist

#define command,DLL
#define function,DLL

directory change,@path(%0)
external vdsflist.dll
rem  flist threads,threads

DIALOG CREATE,loadfiletest,-1,0,400,190
DIALOG ADD,LINE,LINE1,5,5,390,135
DIALOG ADD,LIST,box1,15,11,378,115

DIALOG ADD,BUTTON,abort,148,12,88,24,Abort
DIALOG ADD,BUTTON,stop,148,125,43,19,Stop,,
DIALOG ADD,BUTTON,test,148,185,43,19,Test,,
DIALOG ADD,BUTTON,cancel,148,285,43,19,Exit,,
DIALOG ADD, STATUS,statis,

DIALOG SHOW

LIST CREATE, 1
LIST CREATE, 2

:EVLOOP 
 WAIT EVENT 
 GOTO @EVENT()

:testBUTTON
 LIST clear, 1
 LIST clear, 2
dialog clear,box1
%%loadfile_save = c:\zztest\loadfile.txt
%%loadfile_files = @DIRDLG(Choose your file list,%%loadfile_path,shownewfolderbutton)

rem  DLL FLIST, FLAGS,F
DLL FLIST, LIST,%%loadfile_files
DLL FLIST, SAVE,c:\zztest\loadfile.txt

goto evloop
 
:refresh
:stopBUTTON
 LIST clear, 1
 LIST clear, 2
dialog clear,box1
goto evloop
 
:cancelBUTTON
:close
LIST close, 1
LIST close, 2
exit
Back to top
View user's profile Send private message Visit poster's website
vtol
Valued Contributor
Valued Contributor


Joined: 05 Feb 2004
Posts: 656
Location: Eastern Indiana

PostPosted: Wed Apr 14, 2004 6:16 am    Post subject: Reply with quote

Ok, I got the v3.18.0.0 March 17, 2004 VDSDLL.DLL and the script below works, but I have to click the Reg-nag-screens OK about 10 times to get to the program. (I'm clicking the 'Run Script Play Button' from within the VDS5 IDE...

Code:
#define command,DLL
#define function,DLL
directory change,@path(%0)
rem  the below VDSDLL.DLL is at  c:\vds5\vdsdll\  with the dsc dsp file
external VDSDLL.DLL

DIALOG CREATE,flisttest,-1,0,400,190
DIALOG ADD,BUTTON,test,148,15,43,19,Test
DIALOG SHOW

:EVLOOP 
 WAIT EVENT 
 GOTO @EVENT()

:testBUTTON
DLL FLIST, LIST,c:\Program Files,*.*
DLL FLIST, SAVE,c:\zztest\example.txt
goto evloop

:close
exit


I did find one problem, it seems the DLL file creation dates don't match the 'copy overwrite confirmation' date while over writing the file... Makes it very confusing getting correct version in your folder, I found that overwriting is best way to make sure you have the latest version(if that makes sense to you) Smile
Back to top
View user's profile Send private message Visit poster's website
vtol
Valued Contributor
Valued Contributor


Joined: 05 Feb 2004
Posts: 656
Location: Eastern Indiana

PostPosted: Wed Apr 14, 2004 8:42 am    Post subject: Reply with quote

OK, I had to do this one all my myself - grrrr Laughing
But I did use Martys cool Example and modified it a lot Smile
Hats off to Marty for the cool GOSUBs & stuff in his original Example.
I know Tommys too busy to debug examples..

I used VDSFLIST.DLL v1.1.0.0 JAN 3 2004
I'm using VDS5
VDSFLIST.DLL and the .dsc .dsp files were in same folder together
Test with 'Run Script' Play Button in VDS IDE (demo mode)

Most examples I found were very confusing or wrong Sad

*ABORT works now..
*added a Browse
*added a SAVE to file button

VDSFLIST example below:

Code:
#define command,flist
#define function,flist
OPTION DECIMALSEP, "."
directory change,C:\VDS5\vdsdll
wait "0.2"
external vdsflist.dll
wait "0.2"
flist threads,threads

DIALOG CREATE,flist test,-1,0,400,190
DIALOG ADD,LIST,box1,15,11,378,115
DIALOG ADD,BUTTON,test,148,15,43,19,Test
DIALOG ADD,BUTTON,abort,148,75,43,19,Abort
DIALOG ADD,BUTTON,cancel,148,340,43,19,Close
DIALOG ADD,BUTTON,save,148,275,43,19,Save
DIALOG ADD,STATUS,status,Ready...
DIALOG SHOW

gosub enablesearch

:EVLOOP 
WAIT EVENT 
GOTO @EVENT()

:enablesearch
dialog title,flist test
dialog enable,test
dialog enable,cancel
dialog enable,save
dialog disable,abort
dialog cursor
wait "0.2"
exit

:disablesearch
dialog cursor,wait
wait "0.2"
dialog title,"Please wait, performing search..."
dialog disable,test
dialog disable,save
dialog disable,cancel
dialog enable,abort
exit

:cancel-import
dialog title,flist test
dialog enable,test
dialog enable,cancel
dialog enable,save
dialog disable,abort
dialog cursor
wait "0.2"
goto evloop

:testBUTTON
LIST clear,box1
gosub disablesearch
%%search_area = @DIRDLG(Choose your file list,c:\,shownewfolderbutton)
IF @equal(%%search_area, )
goto cancel-import
END
dialog set,status,Searching on drive    Please wait..
flist flags,F
flist list,%%search_area,*.*,ahrs*
wait "0.2"
goto evloop

:saveBUTTON
FLIST SAVE,c:\zztest\example.txt
wait "1"
info Successefully saved:@FILL(3,,L) C:\ZZTEST\Example.txt
goto evloop

:abortBUTTON
flist abort
wait "0.4"
LIST clear,box1
goto evloop

:FLISTDONE
list assign,box1,@flist(get)
dialog set,status,Number of files found: @count(box1)
wait "0.2"
gosub enablesearch
goto evloop

:cancelBUTTON
:close
flist abort
exit


VDSFLIST is awesome, I'm gonna buy it.
Thanks for a wonderful DLL Tommy Very Happy

This @POST is @EQUAL(%%done,...) (stick a @fork in it())
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    forum.vdsworld.com Forum Index -> General Help All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum

Twitter@vdsworld       RSS

Powered by phpBB © 2001, 2005 phpBB Group