Jump to content
Macro Express Forums

Copy File/Flies Command Issue

Recommended Posts


I started out loving Macro Express 4 but now I am getting a bit frustrated.

I have this bit of code (see below) that runs but the copy file/files does copy the file.

So what I did to test it is change %T1% to the value in clipboard which is C:\Users\desmo\Desktop\Holder\05. Dancewitme.mp3 which works fine and copied the file.

So my question is why does it not work when using the variable %T1%, but works when replace %T1% with the value of the clipboard.

I added a Message box (see below) to check the value of %T1% and it is C:\Users\desmo\Desktop\Holder\05. Dancewitme.mp3

And help would much appreciated






Link to comment
Share on other sites

Looks like it should work.

This is a shot in the dark, but try using Variable Modify String [Trim] on variable %T1% before the Copy File line.  If there are any "invisible" characters on one end or the other of the clipboard contents, this probably will get rid of them. 

Another way to find out if there are non-display characters in a text string is, instead of displaying %T1% in a text box, display ***%T1%***.  If there are no invisible characters, what you will see in the text box will be ***ABC***,, with no empty space between the asterisks and the variable contents.  With invisible characters in the text, the text box might appear as ***  ABC      *** (non-display bytes both before and after the text you expect to see).

Link to comment
Share on other sites

  • 2 weeks later...

Check for leading or trailing non-printing characters. In some programs like Excel it will add a newline set. Open it in a hex editor and see if there is any extra characters. Or see how long it is in MEP. If it's length is 2 longer than what is visible, you probably have a newline set at the end. Or just try a trim command after copying the clipboard contents.

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.

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.

  • Create New...