StrataFrame Forum

New ListView functionality and ChildForm Params

http://forum.strataframe.net/Topic18249.aspx

By Guillermo Vilas - 7/31/2008

Hi,

When using the new functionality of the listview in the beta release where is the best place to add the parameters to pass to the constructor of the ChildForm Dialog called?



I´m guessing that it would be the BeforeChildFormExecuted event but an example would be great Smile



Thanks for your help guys
By Trent L. Taylor - 8/1/2008

Well, actually these parms are not exposed at the moment.  In fact, I have not yet run into a situation where this was needed...so, well, it isn't there Smile  I will add this to the list for the next update.  Thanks.
By Edhy Rijo - 3/20/2010

Hi Trent,



Will this enhancement make it in the next release? Hehe



I use a lot of listviews with the childform dialog and have the need to pass parameters to the childform defined in the ListView.



Besides waiting for this enhancement, is there a work around other than not using the ListView functionality and calling the childForm.ShowDialog(Params) myself?
By Trent L. Taylor - 3/23/2010

You've always been able to call this yourself. You can manually call the ChildFormDialog.ShowDialog(...) and pass the parms. So that would be the workaround at the moment. However, we have exposed this in the next update. Here is the enhancement that has been added:



A new event argument parameter in the OnBeforeChildFormExecuted event called ChildFormParameters. By adding parms to this collection they will be passed on to the calling of the ChildFormDialog like this: ChildForm.ShowDialog(ChildFormParameters.ToArray()). This gives the developer the ultimate control in automation of a child form call through a ListView.

By Edhy Rijo - 3/23/2010

Thanks Trent!