.NET Methods (Magic xpa 3.x)
As you start typing, Magic xpa activates the auto-complete mechanism allowing you to choose the method. In the auto-complete box, you are presented with both properties and methods. Some of the methods, such as Hide() and Show(), are available in Magic xpa as properties. You can use these methods, but remember that during runtime, if there is a contradiction between the control's properties and Magic xpa properties, the Magic xpa properties will be used.
It is good practice to select methods and properties that do not contradict with the internal Magic xpa mechanism. This will ensure smooth use of the control. This includes properties and methods that affect the size and placement of the control.
As an example, if you used the SetCalendarDimensions(6, 2) method to show the full year in two rows, Magic xpa will try to display the control within the confines of the form. In your current program you will probably see both horizontal and vertical scrollbars. If you try to increase the form, Magic xpa will recalculate the dimensions of the control. You will probably not get the desired effect.
It is not recommended to run a method where it will be evaluated often, such as in the property of a control. This will affect performance.
Note:
|
Tooltips – Overloaded Methods
When a method is chosen and a left parenthesis “(“ is entered, then a tooltip showing the functions arguments will be shown.
If the current method has several signatures available, Magic xpa lets you navigate between them by pressing the Up and Down keys or by clicking the tooltip arrows in a box similar to this:
To select a specific signature and you do not want to let Magic xpa decide, use the DNCast() function to implicitly specify the required .NET type. For example: C.Append(DNCast(Trim(D)&': ',DotNet.System.String))
|
How Do I Execute a .NET Method?