Thanks for answering... finally someone answered ! :)
1."sql remote connection settings"... Do i need "trusted connection =False" or something?
2. "same ASP.Net version".. how can I check this?
Main Topics
Browse All TopicsI gave my app to a client. I didnt "package" it. I compiled it and gave them the folder. They installed it on a webserver and only the first page comes up. When the app gets to "dbconnection.open", they get a null-reference.
I added debug steps to the code...thinking maybe the userID is null or maybe the connection string is null but they're not. They can also ping the server that has SQL server on it from the web server...
***Do I need to "package" the app ? I remember in VB6, packaging the app included all the necessary dlls in the package..so if a server doesnt have the dlls..it would get it with the package...
*** what is the dll that sql connection looks for? I have sqlsvr32.dll on my laptop...
Thanks for any help...
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
well depending on what the SQL Server authentication mechanism is used, you'll have to adjust your connection string - ie if it's using windows authentication, you'll have to add a login to SQL for the aspnet user. but a SQL login error would not normally throw a null-reference exception... do you have more error info and some code?
to check the ASP.NET version you can either open up the IIS configuration (Control Panel > Administrative Tools > IIS) and check in the properties of the app (the ASP.NET tab for IIS6, i think you'll have to look up in the application pool settings for IIS7). Alternatively if your exception isn't caught and you get the generic ASP.NET error screen, the version would appear at the very bottom of the page after the error message details.
Hi Farzadw,
SQL Connection Issue
Try a simple Telnet to the SQL server address to port 80: e.g: Telnet 123.456.789.10 80 see if there are any error messages coming back.
Im guessing that your app was written for .NET Framework 2.0, check that the virtual directory/application is set to run under the .NET Framework 2.0.
Go to IIS Manager > Right Click On Virtual Directory/Application > Go to the ASP.NET Tab > check ASP.NET Version is set to 2.0
THanks
Jay Eire
1.They're not using Windows authentication. They're using Login authentication. They created the login/pwd in the database. They say they've made that login a dbo owner. *** I havent checked to make sure what they're saying is correct . I will do that ***
2. I think they have IIS6 and I asked them to make sure the site is 2.0 and not 1.1. Will double check this again
3. Yes, i do have code. I even added debugging to it and gave it to them. It logged to a textfile and what I suspected that could be null...were not null. My code is below.
4. I dont have "trusted connection" in my webconfig.
**** The "debug" code in "try-finally" didnt get logged in to the textfile. So, dbconnection.open even fails.
*** I'm guessing something related to sql server is missing on their box but i really dont know...
*** The error is this and points to "dbmanager.close". So, it cant even open a connection and it tries to close it..
System.NullReferenceExcept
Object reference not set to an instance of an object.
Have a look at thsi porst - Telnet shoud be against port 1433
http://forums.microsoft.co
Business Accounts
Answer for Membership
by: VelioPosted on 2008-02-10 at 04:25:22ID: 20860877
you don't need to package it if you're using System.Data.SqlClient to connect to the DB, they'll already have it when they installed the .NET framework.
i would check the following:
1. is the connection string valid (you say they can ping the server, but that doesn't necessarily mean they can connect to it), eg check database permissions, sql remote connection settings, protocols etc.
2. is IIS using the same ASP.NET version on the client environment as it is on your dev environment.