STK X - Frequently Asked Questions

  1. My browser warns me that my Active X control may be unsafe. What should I do?
  2. When I have two projects opened and try run my application STK X fails to find a license. Why?
  3. In a PowerPoint presentation using Globe or Map controls, why do the Page Up and Down keys sometimes stop working?
  4. Are the STK X components and controls thread-safe?
  5. How can I avoid problems using the Application property of the Globe and Map controls in Microsoft Excel?
  6. How can I make sure that a previous version of STK X in a Microsoft Office document works with the new version of STK X?
  7. How can I ensure the best performance of my STK X application?
  8. Can I load a different scenario in each of several Globe and/or Map controls?
  9. Can I use both the STK X and the STK Viewer controls in the same process or application?
  10. Can I mix STK X controls from different versions in the same application?
  11. How do I set the VendorID property properly?
  1. Question:
  2. When I use the STK X controls on an HTML page, my browser pops up the following warning:
    What does it mean? What can I do about it?

    Answer:

    Your browser is warning you that the HTML page uses some ActiveX controls that are not marked as safe for scripting/initialization. The STK X controls are not marked as safe because they can write files (STK scenario files) on the user's computer; thus AGI cannot mark them as safe for scripting under the definition set forth by Microsoft.

    There are two courses of action you can pursue to avoid this warning:

  3. Question:
  4. I have two projects opened in two instances of my development tool IDE with the STK X controls opened in the designer. When I run my application STK X fails to find a license. Why?

    Answer:

    STK licensing limits you to running simultaneously two instances of STK X. A license is checked out each time an STK X control is used in a designer. Thus, for example, you will not be able to obtain a new license if:

    To make certain STK X finds a license when you run the application, it is suggested that you close the designers to free the license.

  5. Question:
  6. My PowerPoint presentation uses STK X globe and/or map controls. After I use the mouse to manipulate the control the Page Up and Page Down keys can no longer be used to navigate to the previous or next slide. Why?

    Answer:

    The STK X control has the focus and receives all keyboard input. You need to switch the focus back to the PowerPoint slide. Click once on the slide background and then use the keyboard.

  7. Question:
  8. Are the STK X components and controls thread-safe?

    Answer:

    The STK Engine components and controls use the apartment threaded model. Therefore, the STK X application object, the STK Object model root, and the map/globe controls all need to be instantiated in the same thread. For example, if the controls are used in the UI thread, everything needs to be instantiated in the UI thread.

  9. Question:
  10. I sometimes encounter problems using the Application property of the Globe and Map controls in Microsoft Excel? Why? How can I avoid these problems?

    Answer:

    Excel automatically adds some pre-defined properties to all Active X controls. One of these properties is named Application and hides the STK X Application property. To access the STK X property. use:

    Dim stkxApp As AgSTKXApplication
    Set stkxApp = Me.AgUiAxVOCntrl1.Object.Application
  11. Question:
  12. I used a previous version of STK X in a Microsoft Office document (Word, Excel, PowerPoint, etc.). That document does not work now that I have upgraded to the new version of STK X. How can I fix this?

    Answer:

    When a control is inserted into a document, Microsoft Office creates a cache of the type library containing the control. If this cache is out of date, some new or changed properties or methods may not be accessible. You need to delete the cached type library.

    For PowerPoint the file is called STKXLib.exd and is located under [%TEMP%\PPT10.0]. See Microsoft Knowledge Base Articles 158875, 185473 and 290537 for other office applications.

  13. Question:
  14. What should I be aware of to ensure the best performance of my STK X application?

    Answer:

    There are several ways you can significantly improve performance, including these:

  15. Question:
  16. I would like to use several Globe and/or Map controls in my application and load a different scenario in each control. Is that possible?

    Answer:

    No, only one STK X engine can be embedded in one process. Therefore only one scenario can be loaded at a given time in one application. Each control acts as a view of the common scenario.

  17. Question:
  18. Can I use both the STK X controls and the STK Viewer control in the same process or application?

    Answer:

    No, that is not supported.

  19. Question:
  20. Can I mix STK X controls from different versions in the same application?

    Answer:

    No. Only one version can be used in one process (because they share the same DLLs).

  21. Question:
  22. How do I set the VendorID property properly?

    Answer:

    This property must be set when using a STK Engine deployment license.

    When using a deployment license with a VendorID specified, the VendorID value must be set as early as possible and before performing any work with the engine. It can be set once at runtime using the AgSTKXApplication object on a STK Engine application startup. This is the recommended method. Alternatively, it can also be set at design time through the property exposed on the various engine controls. If you are setting it on the controls at design time, it is required that this property be set on all controls.

STK Programming Interface 11.0.1