Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

PB to ASP

Status
Not open for further replies.

extempore

Programmer
Jun 1, 2001
71
US
I need to display the data on an ASP page from PB datawindow. I am moving the data as variable arguements to the ASP URL. I heard there is a limitation for the length of the URL for ASP page. Is it true and if so is there any other way from PB for sending the data to ASP page. Can someone help me in this. Sample code would be nice.

E.g the URL I am trying to open is something like this
Is there an easy way of sending the data?

Thanks

Extempore
 
I insert microsoft web control in a window developed by pb,
then i use ole_1.navigate(url) to browse the url, but i can't visit the control in the url to fill a value in the url automatically not by hand. can you help me, thank you very much!

yours sincerely: smaller
 
Hi

Well this depends on whether you want to display the ASP page inside your application or open a browser window from your application. I also take it that the ASP page you are trying to open is working fine as long as you send it the correct URL with all the variables.

OK open or create the window you want to do this on. Then click the OLE control and select the Insert Control tab on the next window. Then select Microsoft Web Browser from the list and click OK. Then click on the window. This will place the browser control on your window as ole_1.

To test this, just place a button on the window and enter the following script in the clicked event:

ole_1.object.navigate("
This will load the ASP page into the OLE control, so all you have to do is make sure the string with values you send it is build up correctly in PB.

If you want to open the ASP page in your browser enter the following code in the button:

Inet linet_base

GetContextService("Internet", linet_base)

linet_base.HyperlinkToURL("
If IsValid(linet_base) Then Destroy linet_base

Hope this is what you wanted. Regards

Tentacle
 
Thanks for replying. I need to use the method in which i can open a browser window and display the values i have in my pb screen to the ASP page. I am exactly doing the same thing what u suggested. But someone was telling me that there is a limitation to the length of the URL string I calling from PB. (e.g. linet_base.HyperlinkToURL(" I heard there is a limitation of 2083 characters and I just wanted to see if there is any other method available which is not bouded by any limitations like the post method is asp which passes large amts of data from one asp page to another.

Please advise.
 
I'm not sure about the limitation of character you can send to an ASP page, which will be a browser limitation and not a PB one. Anyway, my suggestion for sending big amounts of data to an ASP page would be to write all the info you need to a database which the ASP page can also access and then pull all the data from the database with the ASP page using a simple SQL statement. Unfortunately that's all I can think of to help solve your problem, I normally only send key information to my ASP pages and have the ASP page retrieve and pickup the rest, and never ran into any character limitation problem. Sorry I can't be of more help.
 
Hi Tentacle, I used webBrowser control in my window, it works fine, can I just read everything in the control into a string? Like, is there a text property for this control? Or is there a function that return the content of it?

Is there a help file available for this file?

Thank you so much.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top