I'm having a big problem with the DAL that comes with TaskVision and I'm hoping I'm just doing something silly and someone can tell me what I'm doing wrong.
I changed TaskVision so I could use SQL Authentication (just changed the dbConn.ConnectionString in the web.config file and commented out the permission changes in the .sql file that defines the tables)
Now, the first time a call happens on the TaskVisionWS, in AuthService.asmx for example, it works fine. The next WebMethod that's called fails, saying that the login failed for the user in my connection string.
After going through and watching the code execute inside the DAL, I noticed that the second the connection that's initially passed in (dbConn) is OPENED, the ConnectionString is immediately changed from this:
Data Source=MySQLInstance;Initial Catalog=TaskVision;User ID=xxxxx;Password=xxxxx
to this:
Data Source=MySQLInstance;Initial Catalog=TaskVision;User ID=xxxxx;
So basically, for some unknown reason to me, it chops off the password for the connection and since all of the WebMethods pass the same Connection object into it's DAL call, all of the rest of them fail.
Is this a bug or am I doing something totally wrong
Of course if I create a new connection and pass it in every time, it works just fine, but I'd like to not do that if at all possible! :p
Thanx a lot for any help! :)

PROBLEM: Microsoft.ApplicationBlocks.Data
bb_spinoza
"server=sqlservermachine;database=TaskVision;persist security info=true;uid=sa;pwd="
I'm not sure but I think the colons in your connection string may confuse it, i've never used then in a connection string, not sure if they work. The application block doesn't need any changes besides the persist security info to work with sql authentication (this is because occasionally the application block creates a new connection using the connection it was passed's security information).
Paul Tyng
MCrw
Paul Tyng
Domingo Samper
Steven .NET
"data source=MYSQLDB;initial catalog=TaskVision;uid:sa;password:MyPass;persist security info=True"
Is this the only change required Still doesn't work for me. Do I need to modify the DAL
Johan
Makes sense why it didn't work in TaskVision then, because TaskVision just uses the same connection over and over, which works fine with the default settings, but I had changed my instance of TaskVision to use SQL Authentication instead, thus the problem.
Got it fixed now and now I understand...hope this helps somebody else out too! :)
Carl72
Thanks to everyone for getting to the bottom of it!