jr_bautista
asked on
Profile object does not return value (Personalization in ASP.Net)
I have this on my web.config file
<profile enabled="true">
<properties>
<add name="firstname" />
</properties>
</profile>
and in my C# code to store value:
Profile.firstname = firstname.Text;
and it does not returning value with this, the intellisense recognize the profile properties
Response.Write(Profile.fir stname)
What's the problem?
<profile enabled="true">
<properties>
<add name="firstname" />
</properties>
</profile>
and in my C# code to store value:
Profile.firstname = firstname.Text;
and it does not returning value with this, the intellisense recognize the profile properties
Response.Write(Profile.fir
What's the problem?
SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
ASKER
It hangs when getting the profile. I think it's not saving to the database, I have the folder app_data and nothing is there. How can I specify to which table and MS SQL server it should save?
SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
ASKER
still no value...
this is my connectionString
<connectionStrings>
<add name="MyConnectionString" connectionString="Data Source=SQLxxx; Initial Catalog=MyDB;Persist Security Info=True;User ID=iisuser;Password=12345x xx" providerName="System.Data. SqlClient" />
</connectionStrings>
In your code I substituted "YourConnectionStringName" to "MyConnectionString"
this is my connectionString
<connectionStrings>
<add name="MyConnectionString" connectionString="Data Source=SQLxxx; Initial Catalog=MyDB;Persist Security Info=True;User ID=iisuser;Password=12345x
</connectionStrings>
In your code I substituted "YourConnectionStringName"
SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
ASKER CERTIFIED SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
ASKER