Jump to content
Macro Express Forums

Multifile Selection


bobchernow

Recommended Posts

Just wondering if anyone has written a macro to allow for multifile selection. I would like to write a macro to FTP files that can be selected from one or more directories. The current FTP FILE command only allows one file to be selected and sent. I want to select a directory, then display all files and allow for multiple files to be selected and then sent

 

Bob

Link to comment
Share on other sites

Hi Bob,

 

Nice to see another member!

 

I'll be interested in other's reply; I don't think there is an inbuilt MultiFile Picker?

 

It would be a good request for add-on?

 

I could write one, given time!

 

Here's my suggestion in the meantime; copy files to an "Out" folder, then FTP using a wildcard on files in that folder. (The rest of the FTP macro would run after you shut your "OUT" directory in this case.

 

Either manually, or try this code (copy into ME editor)

 

<REM2:FTP File Pick - -TEMPORARY SOLUTION?><MINIDESK><DOFILE:02:NN:C:\backup\FTP_OUT_Folder>><WAITFOLDER:000010:000000:C:\backup\FTP_OUT_Folder><DOFILE:02:NN:C:\backup\FTP_Moved_Folder>><WAITFOLDER:000010:000000:C:\backup\FTP_Moved_Folder><DOFILE:07:YY:C:\backup\FTP_OUT_Folder\**>C:\backup\FTP_Moved_Folder><EXPLORE:C:\backup><WAITWIN2:000010:000000:C:\backup><IMSD:100><EXPLORE:C:\backup\FTP_OUT_Folder><WAITWIN2:000010:000000:C:\backup\FTP_OUT_Folder><IMSD:100><REM2:Manually select and copy to the FTP_OUT_Folder ! - Hey, we're only trying here!><REM2:Macro continues when you close this OUT Window in Explorer><WAITWLF2:000010:000000:FTP_OUT_Folder><REP3:08:000002:000002:0001:1:01:N1><IFOTH:12:2:FTP_OUT_Folder><EXITREP><ENDIF><ENDREP><TBOX4:T:1:CenterCenter000278000200:000:GO ahead to FTPFTP Send Files C:\backup\FTP_OUT_Folder\*.*><MSTOP><REM2:FTP command, chdir etc as usual;.......><DIS:<FTPCHDIR:1:abc><REM2:FTP command, to SEND all files from the out Directory....><DIS:<FTPSEND:1:A:C:\backup\FTP_OUT_Folder\*.*>

 

Best, Randall

Link to comment
Share on other sites

Hi, Bob,

 

Here is a first attempt at a file-picker using the HTA call; not very pretty! -perhaps you can beta-test!

 

I have written this program in response to requests for a file picking program in Macro Express. This utility uses the HTA system in Windows as described on the macro express list recently.

 

Obviously it is not as expert as if an appropriate call to Windows were made, but I am not sure of any other way to pick files in a multiple fashion using macro express. If anyone else knows this, could they please let me know!

 

It has not been widely tested, but does seem to work on Windows 98 and Windows ME as well as Windows 2000 and Windows XP as one would expect. I have given an example which is deleted at the end which did work for file transfer protocol for some of my files and demonstrates the use of the results in the registers, Name1, Name2, Name3 and so on (FTP; just insert your own address details). The results are also comma-delimited in the string T22. (There's also an option in the deleted loop to save to a text file; you could loop the program up to here, change it to append each time to the file, (without FTP initially) and select programs from further directories, then "text file process" to FTP loop usingthe text file?.

 

This program works by "writing" an HTA script in three parts. The first and last parts are simply put in by strings. The Middle part is a loop, inserting a line in the script for each file found in the selected directory.

 

If there are any problems with this program I would be interested to hear about it, and my e-mail address is randallc@ozemail.com.au.

 

Best Randall

 

FilePicker.jpg

FilePickerTXT.mxe

Link to comment
Share on other sites

Hi again!

 

See also Joe's recent comments about how to learn at this link;

 

Joe and scripting

 

also Floyd's introduction here

 

HTA Forms -how to...

 

Here is a further remedy along the way. It is not really ready for consumption, but I don't have time for making it neat, and it work sometimes!

 

It is a full Library file to generate a new form in a playeble macro; you design the form for field and button number and names as you go.

 

Not for Win98 or WinME though!

 

FormMakerLibraryFile

 

There are "Script" sites to be found on the internet too.

Best, Randall

Link to comment
Share on other sites

  • 1 month later...

Hi again,

Here is a "nicer" FilePicker using AutoIT3

** Simply run the Macro Express file***

[Required file if you wish to use the Compiled version (fastest) uses the ".exe" as an extra file (available here inside the zip; put in macro express installation directory).]

Run the "mxe" part as stand-alone, or migrate it into your library; again, result of multiple fie selection is in a string result (comma-delimited in registry entry, or %T22%.)

(It will still run the old HTA Filepicker (in 2 line RunmacroInVariableScript) without AutoIT or the "exe" being available)

You do not need the "exe" if you have AutoIT3 installed; this program will generate the script and run it, but take a little longer (perhaps?))

Best, Randall

FilePickerAU3.JPG

FilePickerAU3.zip

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...