This callback is invoked by the Target API when the model is about to load.

Namespace:  Quanser.Targets
Assembly:  Quanser.Targets (in Quanser.Targets.dll)

Syntax

Visual Basic (Declaration)
Function ModelLoading ( _
	target As Target, _
	model_output As Target..::.ModelOutput, _
	context As Object, _
	model As String _
) As Integer
C#
int ModelLoading(
	Target target,
	Target..::.ModelOutput model_output,
	Object context,
	string model
)
Visual C++
int ModelLoading(
	Target^ target, 
	Target..::.ModelOutput^ model_output, 
	Object^ context, 
	String^ model
)
JavaScript
function modelLoading(target, model_output, context, model);

Parameters

target
Type: Quanser.Targets..::.Target
The target instance.
model_output
Type: Quanser.Targets..::.Target..::.ModelOutput
The instance referring to the standard output of the model.
context
Type: System..::.Object
The context passed to the GetModelOutput(IModelOutput, Object) method.
model
Type: System..::.String
The name of the model.

Return Value

Return zero if successful. Otherwise return a negative error code.

Remarks

This callback is invoked when the model is about to load. It is not called if the model is already loaded at the time the GetModelOutput(IModelOutput, Object) method is invoked. However, it will be called if the model is terminated and then reloaded.

This method should return zero. Returning a negative error code will cause the GetModelOutput(IModelOutput, Object) method to return with that error code.

See Also