Click or drag to resize

ITpsViewLaunchServicesLaunchView Method (FpStandardView, Object, Boolean, Object)

Launches a View in the FlexPendant.

Namespace:  ABB.Robotics.Tps.Taf
Assembly:  ABB.Robotics.Tps.Taf (in ABB.Robotics.Tps.Taf.dll) Version: 6.5.129.0
Syntax
C#
bool LaunchView(
	FpStandardView view,
	Object initData,
	bool createNewInstance,
	out Object cookie
)

Parameters

view
Type: ABB.Robotics.Tps.TafFpStandardView
A predefined FpStandardView value that represents the type of view to launch.
initData
Type: SystemObject
Data used to initialize the new view.
createNewInstance
Type: SystemBoolean
true to create a new instance of the view; false to give focus to an already open view.
cookie
Type: SystemObject
returns an object that can be used to close the view.

Return Value

Type: Boolean
true if the view was created correctly; otherwise false.
Remarks
If createNewInstance is set to false and the requested view is not already started, a new instance is created. The program editor and the program data views are allowed to have multiple instances, the other views can only have one instance. If the launch is not successful the return value is false and the cookie is null.
Examples
This example launches the different applications that are supported.
// Launch a new instance of the program editor with no init data
if (_iTpsSite.LaunchView(FpStandardView.RapidEditor, null, true, out _cookie) != true)
{
    // take care of the error
}

// Launch a new instance of the program editor at task T_ROB1, module MainModule, row 7.
RapidEditorInitData initData = new RapidEditorInitData("T_ROB1", "MainModule", 7);
if (_iTpsSite.LaunchView(FpStandardView.RapidEditor, initData, true, out _cookieE) != true) 
{
    // take care of the error
}

// Launch an existing instance of the program editor at a specified routine.
RapidEditorInitData initData = new RapidEditorInitData("T_ROB1", "MainModule", _myRout.TextRange.Begin.Row);
if (_iTpsSite.LaunchView(FpStandardView.RapidEditor, initData, false, out _cookieE) != true) 
{
    // take care of the error
}

// Launch the Backup and Restore view
if (_iTpsSite.LaunchView(FpStandardView.BackUpRestore, null, false, out _cookieB) != true)
{
    // take care of the error
}

// Launch the Jogging view
if (_iTpsSite.LaunchView(FpStandardView.Jogging, null, false, out _cookieJ) != true)
{
    // take care of the error
}

// Launch a new instance of the program data view
if (_iTpsSite.LaunchView(FpStandardView.RapidData, null, true, out _cookieD) != true)
{
    // take care of the error
}
// Launch the Logoff dialog
if (_iTpsSite.LaunchView(FpStandardView.LogOff, null, false, out _cookieL) != true)
{
    // take care of the error
}
See Also