Sunday, February 12, 2012

ASP.Net dev site not running using ASPNET account?

VS2005

Hi

If I run the below code (this simply connects to SQL Server and returns the user name the connection is made under):

 Dim ConnectionAs New SqlConnection(System.Configuration.ConfigurationManager.ConnectionStrings("LocalSqlServer").ToString)Dim AttCommandAs New SqlCommand("SELECT System_USER", Connection) Connection.Open()Dim AttendanceReaderAs SqlDataReader = AttCommand.ExecuteReader AttendanceReader.Read() Debug.Print(AttendanceReader.Item(0).ToString)
I get:

MyDomain\pootle.flump

Which is the account I am running on the dev machine. I expected ASP.Net to run as ASPNET irrespective of the currently logged in account. Am I plain wrong? Do I need to change something in IIS? Do I need to change something in ASP.Net?

Any help greatly appreciated

Thanks

VS2005 by default uses a local web server running under your account, rather than a web site running under IIS. This is a change from VS2002/2003.

|||

Thank you

You say this is default - is there a way to change this?

|||

Hi

Does anyone know how to (or if I should be...) run the site (on dev machine) using the ASPNET account?

Thanks

No comments:

Post a Comment