Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Walk though MM code
Message
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Divers
Thread ID:
00913952
Message ID:
00914278
Vues:
11
>I added a mmButtonNew to one of my pages. I click the button and nothing happens, I want to debug this myself, how do I walk thought the code. I didn't place any code on the button, is this wrong, from what I have read it is self binding.

That's right, you don't have to add any code to the form to get this button to work. However, you may need to set the button's BindingSource property.

If you have registered a primary business object with the form (using the forms's RegisterPrimaryBizObj method) and you want the button to be associated with this business object, you don't have to specify anything in the button's BindingSource property. However, if you want to associate the button with a business object that is NOT the form's primary business object, you can set the button's BindingSource property to that business object.

>So if I have no code on the click event how do I step though the code on the click event.

You need to open the mmButtonNew source code file in VS .NET (assuming your project is already open) and set a breakpoint in the mmButtonNew_Click event handler method.

If you still don't hit the breakpoint, and you've already followed the instructions in the MM .NET Dev Guide topic "Stepping through MM .NET code in the Debugger", try adding the MM .NET project to your solution. You can specify that the MM .NET project is not built by doing the following (this is due to an "isssue" in VS .NET):

1. Right-click on the Solution and select "Properties" from the shortcut menu

2. In the left pane, select the "Configuration Properties" node

3. In the right pane, uncheck the Build checkbox for the MM .NET project

>If I add a call to the new Row method it will bypass the initial click event code won't it?

If you create an event handler for the new button's Click method at the form level, both your code and the code at the Framework level will fire.

Regards,
Kevin McNeish
Eight-Time .NET MVP
VFP and iOS Author, Speaker & Trainer
Oak Leaf Enterprises, Inc.
Chief Architect, MM Framework
http://www.oakleafsd.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform