Problem with debugging a Web Part

liunx

Guest
Hi all,

I have a problem with debugging a webpart. My webpart is written in Csharp. Its function is to execute a query on LDAP and return the groups that the user using the webpart belongs to.

Inside the RenderWebPart function, I have a function called showGroups that takes no argument. I use the Break mode and I see that before this function is executed, everything is OK.

But when this function is execute the webpart page displays the error:

"Web Parts Maintenance Page: If you have permission, you can use this page to temporarily disable Web Parts or remove personal settings. For more information, contact your site administrator. "

The amazing thing is the error displays before no statement in the function showGroups is executed. I placed a breakpoint at the first statement in the function showGroups but it is never executed.

I think that I have enough permission for this web part page:
* I'm in the Debugger User group
* I modified the web.config file

When I comment out the function showGroups and replace it by

output.Write("Hello World");

The webpart display the text "Hello World". That means it works fine.

If you have any experience in debugging webpart, pls tell me.

Many thanks,

Toan.
 
Back
Top