These are the steps I follow when I want to debug through the remote data portal.
Steps to configure debugging:
1. In VS open your Solution.
2. Right click on the Solution in the Solution Explorer and choose:
Add
Existing Web Site…
(Check out the solution)
3. In the dialog box click Local IIS on the left side and then click the virtual Directory named DP in the center.
Click Open button.
4. A new project is added to the solution under named: http://localhost/DP/
5. Delete all of the files in the bin folder.
6. Right click the bin folder and Add Reference…
Click the Project Tab
Choose you BO .dll file.
7. Now when you Build the solution, the Remote DataPortal bin folder is updated with the most recent copies of the .dll files.
8. Now you should be able to set breakpoints on both sides of the Data Portal and step through the code.
e.g.
In a Shared method:
Return DataPortal.Fetch(Of Acct)(New Criteria(acctcode))
And then in the DataPortal_Fetch you can set another breakpoint.
You should be able to step through the Csla framework too.
9. Note: since the code is the exact same thing when you do not use remoting, the “bug” you are looking for is most likely NOT in the code itself – if it was you could run without a remote DataPortal, step through it normally and fix it. You only need this technique if the bug is somewhere else (like the configuration file.)
Joe
Copyright (c) Marimer LLC