Wrox Programmer Forums
|
BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8
This is the forum to discuss the Wrox book Beginning ASP.NET 2.0 by Chris Hart, John Kauffman, David Sussman, Chris Ullman; ISBN: 9780764588501
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old March 14th, 2006, 10:16 PM
NuB NuB is offline
Registered User
 
Join Date: Mar 2006
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Problem with Data Connections

Try It Out section never work right on me. I am able to set up WroxUnited site and see it at http://localhost/wroxunited/default.aspx. However when I open a site, let say C:\BeginningASPNET20\Begin\Chapter03\WroxUnited in VWD I always got the error below.

Failed to generate a user instance of SQL Server due to a failure in starting the process for the user instance. The connection will be closed. [CLIENT: <local machine>]

I logged in as local admin. That is same and only user acct I use on this machine. I did delete SQLEXPRESS folder in C:\Documents and Settings\Administrator\Local Settings\Application Data\Microsoft\Microsoft SQL Server Data\ and reboot but it is recreated later. However in VWD, when I open Data Connections in Solution Explorer if I change User Instance to False then I can connect to the database. But that's it. After I changed User Instance to False, save All, and choose to Build Web Site Again I still got the same error. Toggling b/w False and True for User Instance doesn't help. I use SSEUTIL -L, it shows same error.

What should I do now? Thx.

 
Old March 15th, 2006, 06:17 AM
Wrox Author
 
Join Date: Jun 2004
Posts: 59
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi
   This one has baffled us so far.We've already discussed this in the thread http://p2p.wrox.com/topic.asp?TOPIC_ID=39909. I've seen several solutions on google and posted some and none seem to work. No doubt Microsoft will claim this is intended behaviour and that we're the ones doing something wrong - however at the moment it seems like this is a problem. Plenty of people seem to have this problem, all in differing situations. I'll keep looking, but it maybe something that gets sorted in the first service pack.

Chris

Chris Ullman
Programmer/Technical Author
http://www.cuasp.co.uk
 
Old March 15th, 2006, 02:28 PM
NuB NuB is offline
Registered User
 
Join Date: Mar 2006
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for promptly reply. If I want to use SQL database instead of SQL data file in the connection string, what does the string look like? Currently in web.config:

<connectionStrings>
     <add name="WroxUnited"
      connectionString="Data Source=.\SQLEXPRESS;AttachDbFilename=|DataDirector y|WroxUnited.mdf;Integrated Security=True;User Instance=True"
      providerName="System.Data.SqlClient" />
  </connectionStrings>

Let's say if I manually copy WroxUnited.mdf and WroxUnited.ldf to SQLEXPRESS data folder, attach them as WroxUnited database, delete WroxUnited.mdf in App_Data folder, create a new Data Connection to WroxUnites database on SQLEXPRESS server then what the new connection string looks like? With the new connection string, is Web.config the only file I must edit in order to make the site work?

Regards,

 
Old March 15th, 2006, 08:52 PM
NuB NuB is offline
Registered User
 
Join Date: Mar 2006
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

:)

I had the problem using remote desktop to connect to the computer. So I restarted the computer, logged on locally, then remotely connected to that computer using the same login. Bingo, I can load and build the site now.

It reminded me of similar problem when I wasn't able to setup SQL mail using Outlook on one of our SQL 7 servers. Later I used Norton PC Anywhere instead of MS remote desktop to setup SQL mail and it worked fine.

Thanks again.








Similar Threads
Thread Thread Starter Forum Replies Last Post
removing "data connections" jerryham VB.NET 3 September 25th, 2008 11:09 AM
Using Several Data Connections for 1 Listbox??? lnickol22 Visual Basic 2005 Basics 3 February 12th, 2008 12:58 PM
Help with connections dotnetfreak ASP.NET 1.0 and 1.1 Basics 21 January 18th, 2007 02:07 PM
Wacky ASP Connections to SQL Server-PROBLEM SOLVED buddyz Classic ASP Databases 13 August 24th, 2006 08:29 AM
Connections saulodet ADO.NET 2 January 2nd, 2004 04:55 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.