Form Add() -> DeterminedByBusinessObject Parent/Child record add()


Author
Message
Fabian R Silva, -
Fabian R Silva, -
StrataFrame User (261 reputation)StrataFrame User (261 reputation)StrataFrame User (261 reputation)StrataFrame User (261 reputation)StrataFrame User (261 reputation)StrataFrame User (261 reputation)StrataFrame User (261 reputation)StrataFrame User (261 reputation)StrataFrame User (261 reputation)
Group: StrataFrame Users
Posts: 153, Visits: 1.2K
Hello, 

I attemp to automate some generic stuff on a Strataframe inherited form...



I have a form that use that inherited form, this form have 2 BOs (boParent, boChild), one depend from another and the relationship are 1-1

I like to call the form Add() method and this call the Add on each BO (both of them have a vakye if true on "IncludeInFormAdd" and form's IncludeInFormAddType =DeterminedByBusinessObject)



The problem is that boChild Add  is called first and this try to get the pk from the boParent and this still doen't have a record. (current row is null)

I see that the method GetListOfAddBOs not order the BOs with initpriority order or at least 1st the BOs that not have relationship or are parent...

I tried to overrides the Add() method on my inherited form (replicating SF Source Code all I can), but FormEditingStateChanged not have a "OnFormEditingStateChanged" method to be called (I use c#, it doen't have a RaiseEvent), SetFocusToControl is private.... it's becoming complicated.



What is best approach to not to "hardcode"/override the add functionality of both BOs by calling only a method and it do all the work?

the last stuff that works was to put on the "AfterAddNew" event of the form (with IncludeInFormAddType=PrimaryBusinessObject) an hardcoded "childBO.add()", I trying to not have to make it on each form that I create.

thanks!
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search