Jump to content
Macro Express Forums

copy from excell to variabel


koden

Recommended Posts

Hi

 

I have used macro express before..but more than 10 years ago.

 

So I'm starting from almost scratch 🙂

 

I need to paste some text and numbers in from a excell into a web side.

Actually quite simple

 

In excell I have 3 columns with more than 1000 rows.

 

What i need is to copy column 1,2 and 3 row 1 content into 3 variables and then go to website and paste it to right places.

Empty the 3 variables after use.

Then go back to excell and again copy row 2 into the 3 variables

 

But I have forgot how to do this the right way

 

What is the best solution?

 

to be in excell column 1 and row 1 and ctrl+C put into variabel T1, tab ctrl+c put into var. 2 a.s.o.

 

I know how to jump between the windows and tab around and that kind...

Link to comment
Share on other sites

3 hours ago, koden said:

to be in excell column 1 and row 1 and ctrl+C put into variabel T1, tab ctrl+c put into var. 2 a.s.o.

I know how to jump between the windows and tab around and that kind...

You could put that logic into a "REPEAT 1000 times" loop.  It would be pretty time-consuming to run.  However, the biggest problem is that something would get out-of-sync long before the macro finished a thousand repetitions.  Timing issues within Windows will doom the process, where just a single tab from field to field fails, or a single copy-to-clipboard takes too long, or alt+tab to the other window is too slow. 

 

I would recommend exporting the whole spreadsheet to a comma delimited file -- either manually, or code the macro to do it -- then use ASCII FILE PROCESS to read the file, extract the data fields, and paste/type them into the web form.  You may still have timing or other issues on the web side, but accessing the data accurately will be vastly faster and more reliable than pulling fields one at a time from the spreadsheet.  Macro Express Help has a pretty good explanation of ASCII FILE PROCESS. 

Link to comment
Share on other sites

Thanks...

 

Actually I did finish the macro yesterday with simple TAB commands.

Because we have to use it right now.

 

Will have a look at the ASCII file version as soon I have the time.

 

I got a little problem on the web site that I can't find out.

 

Web site seems to be in 2 parts. An upper and a lower part.

I can't get to the lower part without a mouse click.

I hate to use mouse.... but at the moment I can't get TAB or anything else to catch the point.

 

Could there be a solution for that which I don't know about.

I know it's difficult to say much about without info about the website.

Link to comment
Share on other sites

3 hours ago, koden said:

I can't get to the lower part without a mouse click.

I hate to use mouse....

Nothing improper about using the mouse -- it's fast, and if it works reliably then why not?  You might need a quarter-second delay after the mouse click if the system doesn't respond instantly.  

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...