Hi,

I am using VS 2008 express edition. I want to use asp.net configuration tool .But when i execute the tool it is not working. It display this message in browser 'An error was encountered. Please return to the previous page and try again. '. even though i refresh the page it is not working. Please help me to solve this problem.

Recommended Answers

All 4 Replies

Do you want to add users,or roles ???because there is an alternative way to go about it using the User/Role Managemnt API..If you need help with this just post any further questions,For intstance the code below shows you all the users ,similiar to the users you would see on the asp.net configuration Tool.

if (!Page.IsPostBack)
       {
          GridView1.DataSource = Membership.GetAllUsers();
          GridView1.DataBind();
              
       }

Thank you Samacoba. I tried your code but it throws an exception ' Roles are not enabled'. Actually i want to execute the configuration tool anyhow .

chances are, on your web.Config the Roles are not Enabled ,Add the Following lines on the Web Config.These lines go under the System.Web tag on the web Config.
Adminitrator and Role One are examples of possible roles.

To be honest the error you have has never occured for me.

<roleManager enabled="true"/>
		<authentication mode="Forms"/>
		<authorization>
			<allow roles="Administrator"/>
			<allow roles="Role One"/>
			<allow users="?"/>
		</authorization>

Just reinstall visual studio 2008 because when you install your disk may leave these files.this is installation problem.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.