Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win


VB -Client Server to Web server Data transfer

Posted on 2002-07-02
Medium Priority
Last Modified: 2013-11-13
Hi all,
This is a very challenging thing i have come accross now.
I Have a Client server application in VB.This has  a form with say 10 data input fields.When i press the
"save" button the data from the form gets saved in the sql server in my local network.

Now what i want is when i press the "save" Button the data has to be saved in the database in the Web-Server(any one-IIS...) as well as on the local network.
Could anyone of you guys out there can let me knwo how i can achieve this.
thankx in advance to all,
Question by:peers
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
LVL 143

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 7123998
If there is a SQL Server on a Web Server (i assume it is installed...), you simply connect to your local server and after that update to the web server using the IP Address of that server (even the name should work).

I guess that you would like to have both servers ensured to have the same update, so if 1 update fails, none of the servers should be updated.

For these situations, you either
* use distributed transactions (the client application knows of the different servers to update)
* use MTS server (1 interface for the client application, the MTS component needs to update the servers)
* use replication (client updates only 1 server, replication does the rest)

I think you might think and learn about these things before you decide which strategy to follow.


Expert Comment

ID: 7124145
There is another good,reliable and simple way of doing it.

Have an ASP page located on your web server that contains the code to insert/update the table on your remote IIS Server.

In your VB program,before inserting in the local database,run the ASP page using winsock or inet control.

On successful execution of the ASP page.. only then insert/update the contents in your local database.

Angell.. I dont think replication is a good solution especially when updating remote servers since it depends a lot on the net connectivity and is not reliable for remote updates.


Expert Comment

ID: 7124151
To add.. I have been using this technique in a cramped bandwidth environment for the last 3 years and it seems to work very well.

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.


Author Comment

ID: 7126564
KC-I guess your idea will work out in my case.
The execution of the ASP page should be hidden.i.e when the user saves he should not be knowing a ASP page is also beign submitting simultaneouly.May be that is what you try to say when asking to use socket programming.
Is it possible for you to give me a small sample code so that i could try out this concept since you have beign using this for 3 years.
thankx to all ..keep writing..

Accepted Solution

chops123 earned 800 total points
ID: 7126625

In your VB code... you could do something like this

Inet1.OpenURL ""

Do While Inet1.StillExecuting

If Inet1.ResponseCode <> 0 Then
    MsgBox Inet1.ResponseInfo
End If


Your ASP page "updateDB.asp" can contain the insert statement.



Expert Comment

ID: 7140202
Knock ! Knock ! .. u there  ??

Author Comment

ID: 7148803
hi Kc,
Sorry was not well for some.
i am trying out this code what you have given.will rite here the resullt at the earliest.Thankx a lot for everyone for the response.Keep writing guy if you get any new idea.
LVL 49

Expert Comment

ID: 7971205
Hi peers,
It appears that you have forgotten this question. I will ask Community Support to close it unless you finalize it within 7 days. I will ask a Community Support Moderator to:

    Accept chops123's comment(s) as an answer.

peers, if you think your question was not answered at all or if you need help, just post a new comment here; Community Support will help you.  DO NOT accept this comment as an answer.

EXPERTS: If you disagree with that recommendation, please post an explanatory comment.
DanRollins -- EE database cleanup volunteer

Expert Comment

ID: 8018726
per recommendation

Community Support Moderator @Experts Exchange

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
When we want to run, execute or repeat a statement multiple times, a loop is necessary. This article covers the two types of loops in Python: the while loop and the for loop.
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…
Suggested Courses

597 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question