Help with SQL remote conneciton

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Tony M

    Help with SQL remote conneciton

    vs 2005 - vb .net (desktop app) - XP Pro

    Trying to manipulate data form a desktop app. to a remote hosted website?
    Just trying to connect for now. Anyone know what I can change to make
    connection?
    xxxxxx, yyyyyy and DB are substituted for real values.
    Below is the code:

    Imports Microsoft.SqlSe rver
    Imports System.Data.Sql
    Imports System.Data.Sql Client
    Dim Con
    Dim Sql As String
    Sql = "Server=67.19.2 3.66;Database=d ialer;Uid=xxxxx x;Pwd=yyyyyy;"
    Con = New SqlConnection(S ql)
    Try
    Con.Open()
    Catch ex As Exception
    TextBox1.Text = ex.ToString
    End Try

    Below is error message:
    System.Data.Sql Client.SqlExcep tion: Cannot open database requested in login
    'DB'. Login fails.
    Login failed for user 'xxxxxx'.
    at
    Microsoft.Visua lBasic.Compiler Services.Symbol s.Container.Inv okeMethod(Metho d
    TargetProcedure , Object[] Arguments, Boolean[] CopyBack, BindingFlags Flags)
    at
    Microsoft.Visua lBasic.Compiler Services.NewLat eBinding.CallMe thod(Container
    BaseReference, String MethodName, Object[] Arguments, String[]
    ArgumentNames, Type[] TypeArguments, Boolean[] CopyBack, BindingFlags
    InvocationFlags , Boolean ReportErrors, ResolutionFailu re& Failure)
    at Microsoft.Visua lBasic.Compiler Services.NewLat eBinding.LateCa ll(Object
    Instance, Type Type, String MemberName, Object[] Arguments, String[]
    ArgumentNames, Type[] TypeArguments, Boolean[] CopyBack, Boolean
    IgnoreReturn)
    at DialerTest.frmD ialerMain.btnCr eateDB_Click(Ob ject sender, EventArgs e)
    in C:\DialerTestFo lder\DialerTest VB\DialerTest\F orm1.vb:line 17


    Thank You


  • Mr. Arnold

    #2
    Re: Help with SQL remote conneciton


    "Tony M" <TonyMast_NOSPA M@msn.comwrote in message
    news:OYaMZh8$IH A.4528@TK2MSFTN GP05.phx.gbl...
    vs 2005 - vb .net (desktop app) - XP Pro
    >
    Trying to manipulate data form a desktop app. to a remote hosted website?
    Just trying to connect for now. Anyone know what I can change to make
    connection?
    1) Either the user-id and or psw for the database that you're trying to log
    in with is invalid.

    2) That IP that is being pointed to 67.19.23.66 is a Web server IP and is
    not pointing to an IP that's hosting SQL Server, which I don't see how any
    Web site is going to allow you to access SQL server like that, sending an
    unprotected text connection string over the Internet with User-id and psw
    showing that can be spoofed by a hacker.

    I don't see how any Web site is going to be exposing SQL Server to the
    Internet so that you can connect to it remotely, in the manner that you are
    doing.

    However, you could be trying to do this on a LAN behind a firewall.


    Comment

    • Tony M

      #3
      Re: Help with SQL remote conneciton

      Haven't spoken to my website provider yet, but what other options do I have?
      If I can't communicate with my website via SQL, How else can I do this from
      a remote desktop solution?

      Thanks for your advice


      "Mr. Arnold" <MR. Arnold@Arnold.c omwrote in message
      news:%23$ELB%23 8$IHA.3936@TK2M SFTNGP06.phx.gb l...
      >
      "Tony M" <TonyMast_NOSPA M@msn.comwrote in message
      news:OYaMZh8$IH A.4528@TK2MSFTN GP05.phx.gbl...
      >vs 2005 - vb .net (desktop app) - XP Pro
      >>
      >Trying to manipulate data form a desktop app. to a remote hosted website?
      >Just trying to connect for now. Anyone know what I can change to make
      >connection?
      >
      1) Either the user-id and or psw for the database that you're trying to
      log in with is invalid.
      >
      2) That IP that is being pointed to 67.19.23.66 is a Web server IP and is
      not pointing to an IP that's hosting SQL Server, which I don't see how any
      Web site is going to allow you to access SQL server like that, sending an
      unprotected text connection string over the Internet with User-id and psw
      showing that can be spoofed by a hacker.
      >
      I don't see how any Web site is going to be exposing SQL Server to the
      Internet so that you can connect to it remotely, in the manner that you
      are doing.
      >
      However, you could be trying to do this on a LAN behind a firewall.
      >
      >

      Comment

      • Jason Keats

        #4
        Re: Help with SQL remote conneciton

        Tony M wrote:
        Haven't spoken to my website provider yet, but what other options do I have?
        If I can't communicate with my website via SQL, How else can I do this from
        a remote desktop solution?
        Research ".NET Web Service".

        Comment

        • Mr. Arnold

          #5
          Re: Help with SQL remote conneciton


          "Tony M" <TonyMast_NOSPA M@msn.comwrote in message
          news:Og2fraAAJH A.4740@TK2MSFTN GP03.phx.gbl...
          Haven't spoken to my website provider yet, but what other options do I
          have?
          If I can't communicate with my website via SQL, How else can I do this
          from a remote desktop solution?
          >
          Thanks for your advice
          Normally, your Web services provider would need to provide a Web Service for
          you with your Desktop solution being the Web service client. Your program
          as a Web service client would make contact with the Web service at the Web
          site/Web server. The Web Service would do the accessing of SQL server,
          because the client issued commands to the Web service to access SQL server
          on the Web site's LAN, and the Web service gives information back to the
          client, just like a Web browser and a Web application on a Web site/Web
          server communicate with each other.

          You need to talk to your Web site provider asto the best way to do that and
          what you'll need to do on your end, if the Web site as a Web service in
          place.
          >
          >
          "Mr. Arnold" <MR. Arnold@Arnold.c omwrote in message
          news:%23$ELB%23 8$IHA.3936@TK2M SFTNGP06.phx.gb l...
          >>
          >"Tony M" <TonyMast_NOSPA M@msn.comwrote in message
          >news:OYaMZh8$I HA.4528@TK2MSFT NGP05.phx.gbl.. .
          >>vs 2005 - vb .net (desktop app) - XP Pro
          >>>
          >>Trying to manipulate data form a desktop app. to a remote hosted
          >>website?
          >>Just trying to connect for now. Anyone know what I can change to make
          >>connection?
          >>
          >1) Either the user-id and or psw for the database that you're trying to
          >log in with is invalid.
          >>
          >2) That IP that is being pointed to 67.19.23.66 is a Web server IP and is
          >not pointing to an IP that's hosting SQL Server, which I don't see how
          >any Web site is going to allow you to access SQL server like that,
          >sending an unprotected text connection string over the Internet with
          >User-id and psw showing that can be spoofed by a hacker.
          >>
          >I don't see how any Web site is going to be exposing SQL Server to the
          >Internet so that you can connect to it remotely, in the manner that you
          >are doing.
          >>
          >However, you could be trying to do this on a LAN behind a firewall.
          >>
          >>
          >
          >

          Comment

          • Cor Ligthert[MVP]

            #6
            Re: Help with SQL remote conneciton

            Tony,

            Have a look at these,

            404 - Page Not Found. Shown when a URL cannot be mapped to any kind of resource.


            As the one you have choosen does not work, then contact your provider.

            The security of an SQL server can be very fine tuned. Be aware that the SQL
            server is created to act on Internet, so the Administrator can have set his
            security accoording that.

            Cor
            >

            Comment

            Working...