Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Database & SysAdmin
  3. Database
  4. I'm about to go nutz over here, what is it with the sql 2008 express and visual studios 2008 express that doesn't like my dataconnection?

I'm about to go nutz over here, what is it with the sql 2008 express and visual studios 2008 express that doesn't like my dataconnection?

Scheduled Pinned Locked Moved Database
databasehelpquestioncsharpsql-server
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    tonyonlinux
    wrote on last edited by
    #1

    Okay, here is what I have done. I went to sql manager and i made my database and all is fine. I then wanna of course make a program to interface it. So I add linq to sql to my winform then I take and add the dataconnection. I take and hit sql and i go and find the mdf file that is in the sql server data directory. That seems all fine and dandy. Then visual studios tells me that it wants to make the files local so I hit yes( should i hit no, cause i wanna use the one that is on the server not local). Anyway I hit yes. So then I have my tables and I can drag it to the dbml that seems great. But the problem is when i go to load the dang program it constantly tells me login failed. so i take and go back to sql manager and the dang database is no longer attached ? why? It is making me go in a circle. I tried to add a connection string for the remote under settings it adds it but i can't select it on dbml for some reason it simply doesn't populate the connection dropdown box. so i have been trying to do using (var db = mylittledatabase(properties.settings.default.remote) and that is when i get the whole login issue. Please help this is driving me nuts.

    A 1 Reply Last reply
    0
    • T tonyonlinux

      Okay, here is what I have done. I went to sql manager and i made my database and all is fine. I then wanna of course make a program to interface it. So I add linq to sql to my winform then I take and add the dataconnection. I take and hit sql and i go and find the mdf file that is in the sql server data directory. That seems all fine and dandy. Then visual studios tells me that it wants to make the files local so I hit yes( should i hit no, cause i wanna use the one that is on the server not local). Anyway I hit yes. So then I have my tables and I can drag it to the dbml that seems great. But the problem is when i go to load the dang program it constantly tells me login failed. so i take and go back to sql manager and the dang database is no longer attached ? why? It is making me go in a circle. I tried to add a connection string for the remote under settings it adds it but i can't select it on dbml for some reason it simply doesn't populate the connection dropdown box. so i have been trying to do using (var db = mylittledatabase(properties.settings.default.remote) and that is when i get the whole login issue. Please help this is driving me nuts.

      A Offline
      A Offline
      Andy_L_J
      wrote on last edited by
      #2

      tonyonlinux wrote:

      Then visual studios tells me that it wants to make the files local so I hit yes( should i hit no, cause i wanna use the one that is on the server not local). Anyway I hit yes.

      Try and edit your connection string to change the "UserInstance=True" to "UserInstance=False" and see what happens. You maybe copying the db to the output directory every time you run debug and the changes you make are not persisted in the db on the server. Just a guesss. I have been through all these issues many years ago. Just wish I had written everything down.

      I don't speak Idiot - please talk slowly and clearly 'This space for rent' Driven to the arms of Heineken by the wife

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups