WRQ Reflections - Pulling Data from excel

Scherzzo

New Member
Joined
Jun 2, 2016
Messages
2
Hi to all!,

New member here! Hope someone can help me or point me in the right direction. I'm trying to create a macro in reflections IBM that will automate a repetitive task. Basically the macro should copy a card number from the excel and paste it into reflections in a particular position and also copy and paste the card balance. Here is what I have so far:


Sub Swap()

' Generated by WRQ Reflection for IBM for Windows 12.0.185

dim xlApp as Object
Set xlApp = GetObject(, "ExcelApplication")
xlapp.Visible = True

With Session
.WaitForEvent rcEnterPos, "30", "0", 1, 11
.WaitForDisplayString "KEY", "30", 1, 7
.TransmitTerminalKey rcIBMHomeKey
.TransmitANSI "wcsa"
.TransmitTerminalKey rcIBMEnterKey
.WaitForEvent rcKbdEnabled, "30", "0", 1, 1
.WaitForEvent rcEnterPos, "30", "0", 8, 50
.WaitForDisplayString "DISPLAY", "30", 8, 42
.TransmitTerminalKey rcIBMTabKey
.TransmitANSI "az"
.TransmitTerminalKey rcIBMEnterKey
.WaitForEvent rcKbdEnabled, "30", "1", 1, 1
.WaitForEvent rcEnterPos, "30", "0", 5, 12
.WaitForDisplayString "DT", "30", 5, 8
.TransmitANSI xlApp.Range("1,2").paste
.TransmitTerminalKey rcIBMTabKey
.TransmitANSI "transfer"
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitANSI "0108"
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.Paste
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitANSI xlApp.Range("D1").paste
.TransmitTerminalKey rcIBMLeftKey
.TransmitANSI "09"
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitANSI "boi switch"
.TransmitTerminalKey rcIBMEnterKey
.WaitForEvent rcKbdEnabled, "30", "1", 1, 1
.WaitForEvent rcEnterPos, "30", "0", 8, 18
.WaitForDisplayString "FUNC", "30", 8, 13
.TransmitTerminalKey rcIBMBacktabKey
.TransmitTerminalKey rcIBMBacktabKey
.TransmitTerminalKey rcIBMBacktabKey
.TransmitANSI "0101"
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.Paste
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitANSI xlApp.Range("D1").paste
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitTerminalKey rcIBMTabKey
.TransmitANSI "boi switch"
.TransmitTerminalKey rcIBMEnterKey
End With
End Sub


Appreciate some help if possible!

Regards

Scherzzo
 

Excel Facts

Format cells as date
Select range and press Ctrl+Shift+3 to format cells as date. (Shift 3 is the # sign which sort of looks like a small calendar).
I know this is not the help you want. But when I want to interact to other programs, I use AutoHotkey
 
Upvote 0

Forum statistics

Threads
1,223,247
Messages
6,171,007
Members
452,374
Latest member
keccles

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top