monicamarie
Technical User
Hello,
I am trying to edit part of a macro code in Excel that works with Attachmate (shown below). The CardNumber variable is is an Excel worksheet and always contains 19 digits. I want Attachmate to only send the first 16 characters of that string for each loop. If that is possible, can someone help me to make that edit in the code?
Thank you in advance!
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop
CardNumber = ActiveCell.Value
Sess0.Screen.SendKeys ("<Clear>")
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop
Sess0.Screen.SendKeys ("RR00<Enter>")
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop
Sess0.Screen.SendKeys (CardNumber)
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop
Sess0.Screen.SendKeys ("D<Enter>")
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop
Customer_Number = Sess0.Screen.GETSTRING(5, 8, 14)
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop
I am trying to edit part of a macro code in Excel that works with Attachmate (shown below). The CardNumber variable is is an Excel worksheet and always contains 19 digits. I want Attachmate to only send the first 16 characters of that string for each loop. If that is possible, can someone help me to make that edit in the code?
Thank you in advance!
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop
CardNumber = ActiveCell.Value
Sess0.Screen.SendKeys ("<Clear>")
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop
Sess0.Screen.SendKeys ("RR00<Enter>")
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop
Sess0.Screen.SendKeys (CardNumber)
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop
Sess0.Screen.SendKeys ("D<Enter>")
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop
Customer_Number = Sess0.Screen.GETSTRING(5, 8, 14)
Do While Sess0.Screen.OIA.Xstatus <> 0: Loop