Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Recording macro that interacts with excel or scratchpad .....

Recording macro that interacts with excel or scratchpad .....

Recording macro that interacts with excel or scratchpad .....

Hello. I am having an issue trying to get a macro to interact with either excel or the scratchpad. I have a list of roughly 600 contract numbers that I need to search for and the copy the value of one of the fields and paste into either an excel file or the scratchpad so i can import it into excel. I have tried playing around with the macro recorder but it does not record the actions I performed on the scratchpad.

I included the code from the macro recorder below. The value being pasted was copied from the scratchpad where I pasted my list of contract numbers. I then ran the Scan (S) function and copied the value from R19C67 and pasted that into the scratchpad next to the conract number.

CODE -->

Call ibmCurrentScreen.SendKeys("s")
Call ibmCurrentScreen.SendControlKey(ControlKeyCode_Tab)
Call ibmCurrentScreen.SendControlKey(ControlKeyCode_Tab)
Call ibmCurrentScreen.SendControlKey(ControlKeyCode_Tab)
Call ibmCurrentScreen.Paste
Call ibmCurrentScreen.SendControlKey(ControlKeyCode_Transmit)

ibmCurrentScreen.CursorRow = 19
ibmCurrentScreen.CursorColumn = 67

ibmCurrentScreen.CursorRow = 19
ibmCurrentScreen.CursorColumn = 67

Call ibmCurrentScreen.SetSelectionStartPos(19, 67)
Call ibmCurrentScreen.ExtendSelectionRect(19, 67)
Call ibmCurrentScreen.Copy 

I have some familiarity with VBA macros in excel but none with attachamte. Any help would be appreciated

RE: Recording macro that interacts with excel or scratchpad .....


My advice: do ALL your coding in Excel VBA.

Loop thru your list in your sheet, write the sheet value to the screen at the appropriate coordinates, send keys to process the transaction, look for a response in your message area and react accordingly on the screen.


glassesJust traded in my OLD subtlety...
for a NUance!tongue

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close