Click here to show toolbars of the Web Online Help System: show toolbars |
MIL_ID ContextAppId, | //in |
MIL_INT64 ControlType, | //in |
MIL_INT ControlValue | //in |
This function controls the settings of a MIL application environment. These settings include printing error messages to the screen, parameter checking, logging trace information, as well as on-board memory and processing compensation modes. This function can also clear current and/or global errors.
In multi-thread environments, an MappControl() call applies to all application threads running MIL, unless specifically limited to the calling thread by adding M_THREAD_CURRENT to the ControlType parameter. When you override settings for a specific thread, a subsequent call to change those settings from any other thread will not change the settings. For example, if you enable trace printing for a particular thread, that thread will ignore calls from other threads that try to change trace printing setting. Note that any thread created by the current thread will automatically inherit all the current thread's settings, but it will not inherit this exclusivity.
Specifies the identifier of the application context to use.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description | ||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the current application context. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the application context identifier. |
Specifies the type of application environment setting to control.
See the Parameter associations section for possible values that can be specified.
Specifies the setting's new value.
See the Parameter associations section for possible values that can be specified.
The tables below list possible values for the ControlType and ControlValue parameters.
The following ControlType and corresponding ControlValue parameter settings are used to manage error functionality in the application.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description | ||||||||||||||||||||||||||||||||||||||
ControlValue | |||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Clears current and/or global errors. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to clear both current and global errors. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to clear only current errors. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to clear only global errors. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets whether the printing of error messages to screen is enabled. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies not to print error messages. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to print error messages. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that when an error occurs, a .NET exception will be thrown instead of a message box being displayed. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets whether an error event type (specified using MappHookFunction() set to M_ERROR_CURRENT, M_ERROR_GLOBAL, or M_ERROR_FATAL) will trigger the user-defined function specified using MappHookFunction(). INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to not trigger the user-defined function when an error event type occurs, as specified in MappHookFunction(). |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to trigger the user-defined function when an error event type occurs, as specified in MappHookFunction(). |
The following ControlType and corresponding ControlValue parameter settings are used to control the application environment.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description | ||||||||||||||||||||||||||||||||||||||
ControlValue | |||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the Distributed MIL monitoring configuration global permission level. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that Distributed MIL monitoring configuration is disabled in the current application. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that MIL objects in the current application can be accessed with either read only or read/write permission, depending on how that MIL object was specified with MobjControl(). |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that MIL objects in the current application can be accessed only with read only permission, regardless of how that MIL object was specified with MobjControl(). |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the listening port for a publishing application in the Distributed MIL monitoring configuration. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the listening port (an integer between 0 and 65535) that the current application will use to listen for connections from a monitoring application. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets whether on-board memory compensation on the Host is enabled. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that on-board memory compensation is disabled. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that on-board memory compensation is enabled. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets whether the checking of parameters is enabled. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that checking of parameters is disabled. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that checking of parameters is enabled. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets whether the Host should compensate for processes that cannot be performed on-board due to board-specific limitations. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that on-board processing compensation is disabled. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies that on-board processing compensation is enabled. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Sets the trace setting, which controls when a trace log is generated. INQ |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the default trace setting, which either enables or disables generating a trace log, based on whether Matrox Profiler (or Matrox Interactive log) was used to start generating the log. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the log disable setting, which stops generating the trace log. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies the log enable setting, which starts generating the trace log. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Transfers all gathered trace data from the temporary circular trace log buffer to an . |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Specifies to use the default path and default file name. |
||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Casts the address of the string identifying the specified path and/or file name, from a MIL_CONST_TEXT_PTR to a MIL_INT. |
||||||||||||||||||||||||||||||||||||||
Parameters | |||||||||||||||||||||||||||||||||||||||
This parameter specifies the string whose address to cast. |
|||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||||||||||||||||||||||||||
|
1 If you are passing the value in a variable, don't enclose it in MIL_TEXT().
You can add the following value to the above-mentioned values to set whether the control should be limited to the current thread.
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Description | ||||||||||||||||||||||||||||||||||||||
![]() ![]() |
Limits the effect of the control type setting to the current thread. |
Header | Include mil.h. |
Library | Use mil.lib. |
DLL | Requires mil.dll. |