Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to use Java in Excel VBA?
Hi,
On our intranet, we have a wab page where we can type a doc number and click on submit button. When we click on submit button the doc no is sent to the server and server in return sends the most recent version of that document to the wab page. I want to get the latest version no for series of doc nos listed in excel file. I succeded in opening the pageand typing the doc number but unable to click on the submit button programatically.The error is runtime error no 91 " object variable or with block variable not set" So far I have this. Sub NEW_DOC_NO() Set ie = CreateObject("InternetExplorer.Application") With ie .Visible = True .Navigate "http://docser.gis.com/webapp/jsp/nochang e/YourNewNumber.jsp" Do Until Not .Busy DoEvents Loop Set ipf = ie.document.all.Item("OLD_MDN") ipf.Value = "02232601093" Set ipf = ie.document.all.Item("button") ipf.Value = "Submit" <<<<ERROR LINE ipf.Click Do Until Not .Busy DoEvents Loop End With ie.ExecWB 17, 2 ie.ExecWB 12, 0 Range("A1").Select ActiveSheet.Paste End Sub The submit button uses the following two java codes. code1 <input type="button" name="Submit" class="buttonskeen" value=" Submit " onclick="javascript:validateData()" code 2 { document.Mainform.action"http://docser.gis.com/webapp/jsp/n ochange/YourNewNumber.jsp"; document.Mainform.submit(); } May I know whats wrong with my code? Any help is much appreciated. Thanks. Sirin |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Convert excel to java | Excel Discussion (Misc queries) | |||
Does Excel Support Java? | Excel Programming | |||
Execute Excel Macro using Java | Excel Programming | |||
Using Excel XLL in Java | Excel Programming | |||
Start Excel from Java | Excel Programming |