1. Shawn Davis
  2. PowerBuilder
  3. Thursday, 8 July 2021 00:00 AM UTC

Hi All,

I'm thinking of buying some 3rd party controls for calendaring (WAG, MAG, etc.) & document processing. Should I get the Activex versions of these controls (32 or 64?) or can I somehow use another type like Winforms? Seems like I heard about wrapping control in VS to make them like Activex/COM controls, but can't find where I saw that.

Looking at Text Control & Telerik (though Telerik seems to not have any Activex controls anymore).

Thoughts?

Thanks!

Accepted Answer
Armeen Mazda @Appeon Accepted Answer Pending Moderation
  1. Thursday, 8 July 2021 00:58 AM UTC
  2. PowerBuilder
  3. # Permalink

Hi Shawn,

Bruce has done extensive tech articles on our community site about wrapping .NET controls with COM wrappers.  It definitely works, but the deployment of .NET controls is a bit of a pain.

My suggestion would be to do either ActiveX or another option would be HTML/JS controls that you embed in the new Chromium WebBrowser control.  In PB 2019 R3 and newer, this control supports JavaScript functions so you will be able to integrate with HTML/JS controls contained inside this object.  We have an example on GitHub where we embedded JS chart control.

If you do go the ActiveX route, make sure the bitness of the ActiveX matches how your app is compiled.  For example, if you compile your app as 32-bit app you need 32-bit ActiveX.  My suggestion would be to go with 32-bit ActiveX because the PB IDE is 32-bit and also trying to converting existing 32-bit code to 64-bit requires some substantial work and testing.

Best regards,
Armeen

Comment
  1. Miguel Leeuwe
  2. Monday, 19 July 2021 11:18 AM UTC
Okay, today I've got it working! This is huge for us, because our Crystal Reports Viewer was the only restriction for being able to build a 64 bit pb executable.

Armeen is right: You use a 32 bit visual ActiveX control on your window. And install a 64 bit compiled version with the 64 bit executable. I figured out which registry entries I have to use by taking a registry snapshot, then run regasm /codebase (the one in the Framework64 folder, C:\\Windows\\Microsoft.NET\\Framework64\\v4.0.30319). Then take the second snapshot and export the differences (only the relevant ones). Then I still ran regasm with the "/regfile:" option and combined the results of both registries. It works. Most probably I can still re-use my 32 bit Wixtool msi installer by simply replacing the paths of the registry and folders, but that's something I still have to work out.

regards.

  1. Helpful
  1. Armeen Mazda @Appeon
  2. Monday, 19 July 2021 16:47 PM UTC
Hi Miguel, Thanks for spending the time to test and confirming 64-bit ActiveX controls can be used during runtime!
  1. Helpful
  1. John Fauss
  2. Monday, 19 July 2021 18:03 PM UTC
That's great news, Miguel! Congratulations and thanks for sharing your findings with the Community!
  1. Helpful
There are no comments made yet.
Shawn Davis Accepted Answer Pending Moderation
  1. Thursday, 8 July 2021 13:48 PM UTC
  2. PowerBuilder
  3. # 1

Thanks Armeen! Just the info I needed. I like the idea of HTML/JS controls.

Anyone have any experience with Syncfusion? Or, any other HTML/JS libraries recommended?

Comment
  1. Shawn Davis
  2. Friday, 9 July 2021 17:52 PM UTC
What about ASP.net Core Controls? Would they work inside the browser control? And, I could also choose to wrap them into a Activex/COM control? But, deployment would be complicated?
  1. Helpful
  1. Armeen Mazda @Appeon
  2. Friday, 9 July 2021 18:15 PM UTC
Anything that can display in Web browser AND can be manipulated with JavaScript calls should work. We haven't actually gone through the process to implement these so I cannot tell you exactly what is involved or what needs to be deployed. If you do want to go the embedded Web browser route, then I recommend first start by looking at the JS Chart example to get the gist of this technique. https://github.com/Appeon/PowerBuilder-Graph-Example
  1. Helpful
  1. Miguel Leeuwe
  2. Sunday, 11 July 2021 05:06 AM UTC
Good advice to stay away from GNU licenses!

Syncfusion is a great (not very cheap) product, but we use it only to have a single DLL that we use for some PDF file operations. (that one is free).

The problem with it, is that you have to download a huge amount of their "Suite" just to get a singe file, which isn't very ideal the way I see it.

regards
  1. Helpful
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.