Help please i need vba code to fetch data from mainframe to excel

Hi,

I am looking to ease my work and save lot of time with a simple VBA code my requirement is as follows.

I have some acct numbers in an excel sheet, i need my VBA code to copy the acct number and got to the mainframe application (which is already opened and logged in) and pull the acct information and copy specific line/ value from mainframe to excel sheet beside the account number, and repeat the action till the last acct.

Mainframe: AS400/Rumba mainframe display - Client.
Microsoft Excel Version: 2007.

step wise action in detailed for a better code.
start the first acct>> Copy the acct number>> activate mainframe application >> go to the specific data screen >> pull the acct information >> scrape/ copy the data >> activate excel >> paste the value beside the acct number cell >> loop the action till the accounts end.

account length: 8digits.
value to be copied from main frame about 14 characters.

Thanks in advance, can also email the code to my email so that i can test and let you know if that worked or not.
Hope a quick response for this post.

Regards,
Dilip Kumar.
abhijeet223@gmail.com

Almir's picture

Can you connect through ODBC?

If yes, it should be pretty straightforward. Query acct data with list of acct numbers as parameter.