1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

Connecting to Remote Database from Windows Forms

Discussion in 'Web Design & Development' started by mirracllee, Dec 5, 2016.

Thread Status:
Not open for further replies.
  1. mirracllee

    mirracllee Thread Starter

    Joined:
    Dec 5, 2016
    Messages:
    1
    I have a question regarding C# Windows Forms connecting to external hosted databases.

    I have asphostportal.com SQLServer 2008 database that I use for my web development database purposes. I am creating a C# windows form and I need that to connect to the database. I know how to connect a C# Windows Form to a local database, so I figured that the only difference would be to use a different connection string.

    The connection string I am using is as follows:

    Code:
    DataSource=limeoatsdb.db.8996219.hostedresource.com;InitialCatalog=database;User ID=userid;Password=password; 
    
    
    I replaced the values above with dummy values, but obviously in my code they have the correct values.

    First of all, is it even possible to connect a C# windows form to a asphostportal database?

    Secondly, if it is possible, any ideas on what I am doing wrong?
     
  2. JiminSA

    JiminSA

    Joined:
    Dec 15, 2011
    Messages:
    3,259
    First Name:
    Jim
    Welcome to TSG, miracllee:)
    I have never developed in C#, just good old html and PHP.
    That said I imagine that you simply need to download Microsoft's SQL Server 2008 Express (here) to your device and follow the Install Instructions;)
    As far as connecting is concerned, their documentation must surely cover it (haven't waded through the instructions or the additional information, but if you have no joy you can always address the problem in their user forum, which has a link on the page) - Bonne Chance!
     
  3. JiminSA

    JiminSA

    Joined:
    Dec 15, 2011
    Messages:
    3,259
    First Name:
    Jim
    Yup, (AFAIK) it's not possible to connect to an online database from a desktop platform.
     
As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Tags:
Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/1181955

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice