T
TW Bake
Hi all,
I'm trying to post text to a web browser control within a spreadhseet
and am not having any luck, I've browsed several previous posts and I
cannot seem to get any of the code to work. Do any of you have any
precanned code/sheets that are currently working ???
1) I don't know the names of the fields within the spreasheet forms
but I can get that info from the web developer.
2) There are several fields that I want to post data to so it would
need
to be able to loop through the list.
3) Are there special libraries that have to be referenced?
4) It would be nice to 'Post' the data as well, but not necessary as
our
users can do that when submitting the info.
It seems like the problem is getting it to reference a form within an
HTML web page and referencing the text fields ....
The code I have is a mess and shows my utter lack of knowledge with
the browser objects but it's included below.
Kindest Regards,
TW Bake
'Sub test2()
'
'Dim IElem As HTMLInputElement
'Set WebDoc = Worksheets(1).WebBrowser1.Document
' For Each IElem In WebDoc.forms(0).HTMLInputElement ' Doesn't even
make it past here ...
' Select Case IElem.Name
' Case "UNKNOWN"
' IElem.Value = ShopNum ' for when I will know the
field names
' Case Else
' MsgBox IElem.Name ' to find out the field names
' End Select
' Next IElem
'End Sub
I'm trying to post text to a web browser control within a spreadhseet
and am not having any luck, I've browsed several previous posts and I
cannot seem to get any of the code to work. Do any of you have any
precanned code/sheets that are currently working ???
1) I don't know the names of the fields within the spreasheet forms
but I can get that info from the web developer.
2) There are several fields that I want to post data to so it would
need
to be able to loop through the list.
3) Are there special libraries that have to be referenced?
4) It would be nice to 'Post' the data as well, but not necessary as
our
users can do that when submitting the info.
It seems like the problem is getting it to reference a form within an
HTML web page and referencing the text fields ....
The code I have is a mess and shows my utter lack of knowledge with
the browser objects but it's included below.
Kindest Regards,
TW Bake
'Sub test2()
'
'Dim IElem As HTMLInputElement
'Set WebDoc = Worksheets(1).WebBrowser1.Document
' For Each IElem In WebDoc.forms(0).HTMLInputElement ' Doesn't even
make it past here ...
' Select Case IElem.Name
' Case "UNKNOWN"
' IElem.Value = ShopNum ' for when I will know the
field names
' Case Else
' MsgBox IElem.Name ' to find out the field names
' End Select
' Next IElem
'End Sub