STK ObjectsSend comments on this topic.
EndUpdate Method (IAgStkObjectRoot)
See Also
Windows





Windows & Linux

Description

Signals the object that the batch update is complete. This should only be called when manipulating graphical properties of objects that already exist. Never create or destroy objects or call Avtr methods inside Begin/End update blocks.

Syntax

[Visual Basic .NET]
Public Sub EndUpdate()
[C#]
public void EndUpdate();
[Managed C++]
public: void EndUpdate();
[Unmanaged C++]
public: HRESULT EndUpdate();
[Java]
public void endUpdate();
[Python - STK API ]
def EndUpdate(self) -> None:

Remarks

Best Practice: Only insert Begin/End update blocks after verifying intended behavior and use sparingly to mitigate performance bottlenecks.

See Also

Example

Delay graphics updates while manipulating properties of an object
[C#]
IAgSatellite satellite = root.CurrentScenario.Children["Satellite1"] as IAgSatellite;
IAgVODataDisplayElement voElt = satellite.VO.DataDisplay[0];

root.BeginUpdate(); // Suspend updates

// Put modifications here
voElt.IsVisible = true;
voElt.UseBackground = true;
voElt.BgColor = Color.Green;
voElt.UseBackground = false;

root.EndUpdate(); // Resume updates now
Delay graphics updates while manipulating properties of an object
[Visual Basic .NET]
Dim satellite As IAgSatellite = TryCast(root.CurrentScenario.Children("Satellite1"), IAgSatellite)
Dim voElt As IAgVODataDisplayElement = satellite.VO.DataDisplay(0)

root.BeginUpdate()
' Suspend updates
' Put modifications here
voElt.IsVisible = True
voElt.UseBackground = True
voElt.BgColor = Color.Green
voElt.UseBackground = False

root.EndUpdate()
' Resume updates now
© 2024 Analytical Graphics, Inc. All Rights Reserved.