Rumba Mainframe Excel/VBA Macro

Sachin Shama

New Member
Joined
Feb 6, 2013
Messages
9
Hi ,
I am trying to write a macro which takes the values from my excel sheet & put it into RUMBA mainframe & viceVersa.I have been successful to code the 'excel to Mainframe' copy functionality.However, I am facing issue when I copy text from mainframes to Excel. I have tried using CopyPSToString / CopyPS / CopyFieldToString functions but everytime the string is returned as blank..... I have read somewhere that I have to change default session settings to 'ATTRB' which can be done by using SetSessionParameters , However, I am not able to use it?
Can anybody please help on this?


Thanks,
Sachin
 
Hello Ganesh,
You need not provide any server name.The command retval = WD_ConnectPS(100, "A") should suffice.
I hope that your Rumba and Excel both are on citrix.If your excel is at local machine & rumba on citrix, then I do not think you can link both.
 
Upvote 0

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)
Hi Sachin,

Thanks for your updates :)

Both are in Citrix drivers. Tell me onething, how will we open the Rumba session using VBA code.

Manual activity is to open the Rumba session is follow: Once opened Citrix, I will follow the steps.
1) \\Servername\files\NetManage\Rumba\MFrame\rumba.WDM ==> Double click
2) provide username password etc., ==> Enter
3) go to multiple Rumba screens and copy required screen data in excel or MS-Access tables directly.

FYI, my MS-Access database also is available in the same citix server \\Servername\files\Automation\test.mdb.

It would be great if you can provide the same code for the same.

You can email me the code to ganeshkumars82@gmail.com also.


Thanks in advance :)

Thanks & Regards,
GaneshKumar S
 
Upvote 0
VBA will not open the Rumba.You need to have rumba session already opened for the automation to work.Once it is opened manually, then you can run the code .
PS: I have not worked on MS-access, so do not know much about it.However, my suggestion should go well with Ms Excel.
Hope it helps!
 
Upvote 0
Thanks for the updates. Can you please provide the sample code in excel if you have already.

Thanks in advance :)

Regards,
Ganesh
 
Upvote 0
Its very good and simple code but i am not able to figure out few things
17.jpg
18.jpg
19.jpg
20.jpg
 
Upvote 0
Hi Ganesh,
I have already posted a sample code in this forum.Let me know if you are stuck somewhere specifically, then we can see what is the issue.

Thanks
 
Upvote 0
Hello Sachin,

Forgive me if I overlooked something, but I don't see where anyone has answered your question yet. You are on the right track with WD_CopyPSToString, but I don't see where you reserved the space for you string to return. Try the following and let me know if I can be of further assistance:

Function Scrape(xCol as Integer, yRow as Integer) as String

Dim lngLocation As Long
Dim retVal As String
Dim intStrLength as Integer
Dim sessingInstance as Integer

sessionInstance = 100 'Value taken from your earlier code
intStrLength = 15 'String length as integer

lngLocation = ((xRow-1)*80) + yCol 'Converts coordinates to a single integer value of variable type Long
retVal = String$(Val(intStrLength), " ") 'Reserves 15 characters in memory for the return string
V = WD_CopyPSToString(sessionInstance, lngLocation, retVal, intStrLength)

Scrape = retVal
debug.print retVal


End Function
 
Last edited:
Upvote 0
Hello Sachin - I tried your code and getting error "Run Time Error - 53 : File Not Found" - on this step - E = WD_Sendkey(100, "@E") ' Enter command.
I tried changing
Eehllapi.dll to ehlapi32.dll but this time i got error "Special dll function not found".
Please help.

Thanks!!
 
Upvote 0

Forum statistics

Threads
1,217,367
Messages
6,136,143
Members
449,994
Latest member
Rocky Mountain High

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