newFormMethod using pointer
Posted: Tue Nov 23, 2010 2:32 pm
Hi,
I would like to know if the following is realistic for a future release.
Using the SolutionModel you can create methods on forms. For example like this:
I want to copy some methods on form A to form B (in the example all methods are copied). This is only a small part of the coding I use.
Using 'extendsForm' is not a solution in my case. And creating all global methods isn't either.
The above works correctly.
The problem is that when I debug, that the method on form B is executed, but you can't step through it using the debugger.
What I would like to have, is that I can use a pointer to a method, like this:
And since this is a pointer, the debugger can step into this coding, because it points to coding that was made on designtime.
Could this be an option for a future release?
Martin
I would like to know if the following is realistic for a future release.
Using the SolutionModel you can create methods on forms. For example like this:
- Code: Select all
var frmA = solutionModel.getForm('myFormA')
var frmB = solutionModel.getForm('myFormB')
var _all_methods = frmA.getFormMethods()
var _methodName, _methodA, _methodB
for (var m = 0; m < _all_methods.length; m++)
{
_methodName = _all_methods[m].getName()
_methodA = _all_methods[m];
if (! frmB.getFormMethod(_methodName)) // Check if method exists
{
// Method doesn't exists on form B, so add it now
_methodB = frmB.newFormMethod(_methodA.code)
}
}
I want to copy some methods on form A to form B (in the example all methods are copied). This is only a small part of the coding I use.
Using 'extendsForm' is not a solution in my case. And creating all global methods isn't either.
The above works correctly.
The problem is that when I debug, that the method on form B is executed, but you can't step through it using the debugger.
What I would like to have, is that I can use a pointer to a method, like this:
- Code: Select all
_methodB = frmB.newFormMethod(_methodA) // _methodA is a JSMethod object
And since this is a pointer, the debugger can step into this coding, because it points to coding that was made on designtime.
Could this be an option for a future release?
Martin