J
JT
Below is part of the code from an Excel macro. This macro is designed to run
a series of PeopleSoft queries. This works on my machine but a user in a UK
cost center has problems running it. He was able to run it until last month.
He gets a "Type Mismatch Error on the following line:
Set WebDoc = .document
I've checked References and Internet Explorer versions and they are the same
on both machines. Any suggestions on what could be throwing this error would
be GREATLY appreciated.
Thanks for the help....JT
Public ExpApp As InternetExplorer
Public WebDoc As HTMLDocument
For p = 1 To y
vWBCount = Workbooks.Count
vFullPath = vpath
With ExpApp
.navigate vFullPath
Do Until .readyState = READYSTATE_COMPLETE
MyTimer
Loop
Set WebDoc = .document "TYPE MISMATCH ERROR
For Each IElem In WebDoc.forms(0).elements
Select Case IElem.Name
Case "InputKeys_BUSINESS_UNIT"
IElem.Value = vBU(p)
Case "InputKeys_bind2"
IElem.Value = vBegDate
Case "InputKeys_bind3"
IElem.Value = vEndDate
End Select
Next
.navigate
"javascript:submitAction_win0(document.win0,'#ICQryDownloadExcelFrmPrompt');"
a series of PeopleSoft queries. This works on my machine but a user in a UK
cost center has problems running it. He was able to run it until last month.
He gets a "Type Mismatch Error on the following line:
Set WebDoc = .document
I've checked References and Internet Explorer versions and they are the same
on both machines. Any suggestions on what could be throwing this error would
be GREATLY appreciated.
Thanks for the help....JT
Public ExpApp As InternetExplorer
Public WebDoc As HTMLDocument
For p = 1 To y
vWBCount = Workbooks.Count
vFullPath = vpath
With ExpApp
.navigate vFullPath
Do Until .readyState = READYSTATE_COMPLETE
MyTimer
Loop
Set WebDoc = .document "TYPE MISMATCH ERROR
For Each IElem In WebDoc.forms(0).elements
Select Case IElem.Name
Case "InputKeys_BUSINESS_UNIT"
IElem.Value = vBU(p)
Case "InputKeys_bind2"
IElem.Value = vBegDate
Case "InputKeys_bind3"
IElem.Value = vEndDate
End Select
Next
.navigate
"javascript:submitAction_win0(document.win0,'#ICQryDownloadExcelFrmPrompt');"