Skip to main content
InSource Solutions

TN - 1124 Using a WPF Control in an ArchestrA Graphic

Description  

In another tech note,  we embedded a WPF user control in an Element Host control which allowed us to use it in a Win Forms application. In this tech note we will import our complied control into our Galaxy for use in an ArchestrA Graphic or Industrial Graphic.

  • Author: Mario Meza
  • Published: 3/19/2021
  • Applies to: ArchestrA graphic / Industrial Graphic

 

In the previous article we left off with our control complied in release mode. Take note of the path to your .dll

 clipboard_e1d1940f5fcc18cc2305c58a2f801ffdd.png

 

From the IDE select Galaxy > Import > Client Control.

clipboard_e937615577136ab375d51e5407957b7f4.png

 

Navigate to the complied .dll and select Open.

clipboard_eaa4e4cbd88e89626da8545edd160d60e.png

 

Keep the defaults hit OK.

clipboard_ef6d79c03e8a6073a99131eeeb723ffe4.png

 

Once completed 

clipboard_ef827bbe9aeb6fbff7bb2e8d690d015bf.png

 

Create a new Symbol to embed the custom control and give it a name.

clipboard_e44041369532d6ef53b61539e91ce6d01.png

 

Create a new Graphic Toolset.

clipboard_e7059b515c11e0c52c21b841dd718dde2.png

 

Move the imported control and symbol you just created to the new toolset. Open the symbol for editing.

clipboard_ea6b3bfee468f87dac1964133697c0732.png

 

Select the Embed Graphic Icon.

clipboard_e7dae44028090f6e0a8334ba4cf770ad8.png

 

Navigate to the imported control and select OK.

clipboard_e690f41feda29bebb31619c532cb03300.png

 

Place the control, save and exit.

clipboard_eea2876f3c7e9923f466a522f91c729ce.png

 

Check In the symbol.

clipboard_ef0329c6822936766942be86584249360.png

 

Open an InTouch application.

clipboard_e97be8253741bec3a9d0d8bbf01bf013a.png

 

Select the Embed Industrial Graphic Icon.

clipboard_ecdc895fa211321a33593237e1bc86df1.png

 

Select the Control and click OK.

clipboard_ef6ff1f8ed6ccac15f031b76d88f9f8fc.png

 

Place the graphic and put the application in Runtime

clipboard_e1d9f14b4f80cc4fc982d6db25c748d98.png

 

Success!

clipboard_ea920f89d15a195a0ebd9afd8811ea9bd.png

 

From here you can export the Graphic toolbox as an .aapkg and import it into a Standalone InTouch application.

clipboard_e74f2f9f9e4f4f4049012099eb3a5b9bf.png

  • Was this article helpful?