Iseries - Transfer to

R

revinfo

I saw some messages that were old regarding people trying to automate
their data transfers to the Iseries via the client access add-in to
Excel. It seems that recording keystrokes doesn't help any, so you end
up having to use the "Sendkeys" command.

Having said that, here is my code so far that works as long as there
are no errors. I need to pause for a couple of seconds after the
Sendkeys in case there are a couple of messages that pop up that have
to have the user click ok on. Then, it will work to do the
Activesheet.showalldata method.


Sub CAUpload()

'Upload the MJE to AS400 Using Client Access Addin
Dim TransReqFile As String
TransReqFile = Range("Transreqfile").Value
Call HideZeros
Application.DisplayAlerts = False
Range("Start").Offset(1, 0).Select
Range(Selection, Selection.End(xlDown)).Select
Range(Selection, Selection.End(xlToRight)).Select
SendKeys ("/" + "D" + "D" + "D" + "{Enter}" + "{Tab 6}" _
+ TransReqFile _
+ "{Enter}" + "{Tab 2}"), True
ActiveSheet.ShowAllData
Range("a6").Select
End Sub



Bruce Roberson
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top