Connecting VB app to a browser session

COSSOFT
09-10-2003, 06:05 AM
Hi all.

My question spans several of the forums, so I've posted it here. I'm writing a VB6 /web based application that operates as follows:-

1. Customer goes to web site and browses, adding stuff to a shopping cart. However, these are digital products, not physical ones.

2. To check out, customer then fires up a previously downloaded VB app.

3. The app connects to the web site's server, and the same hardware server begins streaming out the products to the customers PC through a serial port.

My question is then, how can the VB app identify itself as belonging to the users browsing session (which it must to connect to the correct cart)? To inform, I'll probably use JAVA /JSP on the server side. I'd like to make the process as seemless as possible... Thanks in advance.

alp0001
09-10-2003, 06:40 AM
Hi and welcome to the site.

Well, I never had to use an Activex control in my pages before, so I don't know if the following would work. Possibly add an Activex control to the page which either does all the downloading for you or calls that VB app that you have already created.

COSSOFT
09-10-2003, 06:59 AM
Hi alp0001 and thanks for the welcome.

To be honest, I thought about the ActiveX route and tried it. I still seem to have the same problem thought; how does the control identify itself to the server when making the connection (via Winsock)? As I understand sessions, they refer to the http session between the browser and the web server. The raw socket connection from the control to the server is seperate and distinct from the browsing session..?

mark007
09-10-2003, 07:55 AM
Sorry if this is a lame suggestion but could you possibly save the data in the cart to a DB on the server wehn the check out button is pressed using a unique ID. You could then get it to fire up you VB app as alp0001 suggested using an activeX control that passes the same ID to the app. The app could then connect to the server and DB to retrieve the products using the ID passed to it.

Like I said it's not something I've evr tried to do so I'm completely theorising here!

COSSOFT
09-15-2003, 05:42 AM
The ActiveX approach sounds good, but I'm worried that most people using the internet don't allow ActiveX controls to run due to the security implications... What do you think? Is there a non-ActiveX method?

mark007
09-16-2003, 02:58 AM
What about running a server side script on clicking the checkout button that places the itmes in the basket in a DB along with a unique ID. You can then output this ID to the user on the web page and tell them to copy and paste it into your VB app. The app could then connect to the DB using this ID to retrieve the products and once it has retrieved them delete the entry from the DB or mark it as downloaded at least to prevent use again if necessary. The only issue with this would be to make your ID's long to avoid the chance of people randomly typing them in.

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum