Re: Posting to a Web Form and Displaying the Result in Normal Browser
- From: "David W. Fenton" <XXXusenet@xxxxxxxxxxxxxxxxxxx>
- Date: Sat, 07 Apr 2007 17:54:47 -0500
rkc <rkc@xxxxxxxxxxxxxxxxxxxxxxxx> wrote in
news:4616f4a2$0$27057$4c368faf@xxxxxxxxxxxxxx:
David W. Fenton wrote:
Tom van Stiphout <no.spam.tom7744@xxxxxxx> wrote in
news:958b135qfm6lf2h964mq296g3bbssjf4el@xxxxxxx:
In cases where I had to poke values into a webpage, I would use
the WebBrowser control, and use the DOM (document object model).
Example:
If WebBrowser1.LocationURL =
URL_PHOENIX_LIBRARY_REFERENCE_USA And
WebBrowser1.Document.getElementsByName("cardnum").length > 0
Then
WebBrowser1.Document.All("cardnum").innerText =
LIBRARY_CARD_NUMBER
WebBrowser1.Document.All("cardname").innerText =
LIBRARY_CARD_NAME
WebBrowser1.Document.Forms(0)("Submit").Click
Else
MsgBox "This button only works when you are on the Login
page.", vbInformation
End If
But the web browser control is disastrously incompatible with
A97, at least, the last time I checked. That was the original way
I conceived this, about 3 or 4 years ago, but could never make it
work, even when I was controlling the version of IE on al
installed machines.
I guess what I could do is the equivalent of some kind of
database-driven session management on the website, and have the
script on the website store the data with the session key and
return the session key as its output, then use FollowHyperlink to
pass the session key back to a different script that would open
in the browser and display the data that was passed.
But surely this ought to be doable without persisting data on the
website?
Why do you want to display the data in a web browser?
Because I want to have them confirm the add/update, and have the
opportunity to edit if they need, and to preview how it will look on
the web page.
Is your plan to add items to a database on a web server using an
Access front end and then view how those items are displayed when
requested from the site?
That's part of it. What is happening is transferring items from the
Access inventory database to the online database that drives the
website. If it were a 1:1 transfer, it would be easy, but everything
has to be extensively processed for the website (it's very complex).
If it were 1:1, I wouldn't be worrying about displaying a confirm.
I have done something similar to that for a web store, but did not
view the results in a browser. I used xmhttp to request the page
with the new data and simply parsed it and displayed what I needed
to know in an Access form.
But I can't do that, because I can't show how it will look on the
web page.
I actually automated the request by item number and just sat there
and watched the results be displayed in the form.
I wish I could do that, but I can't.
I guess what I want is not possible without using some kind of
persistent storage on the website. I guess it makes more sense to
just add the new record, then display it for confirm/editing.
--
David W. Fenton http://www.dfenton.com/
usenet at dfenton dot com http://www.dfenton.com/DFA/
.
- Follow-Ups:
- References:
- Posting to a Web Form and Displaying the Result in Normal Browser
- From: David W. Fenton
- Re: Posting to a Web Form and Displaying the Result in Normal Browser
- From: Tom van Stiphout
- Re: Posting to a Web Form and Displaying the Result in Normal Browser
- From: David W. Fenton
- Re: Posting to a Web Form and Displaying the Result in Normal Browser
- From: rkc
- Posting to a Web Form and Displaying the Result in Normal Browser
- Prev by Date: Re: When Checkbox is Checked on Form, want report to print Yes/No
- Next by Date: Re: This newsgroup interface is old ... we need a new forum.
- Previous by thread: Re: Posting to a Web Form and Displaying the Result in Normal Browser
- Next by thread: Re: Posting to a Web Form and Displaying the Result in Normal Browser
- Index(es):
Loading