1. Anthony Scruse
  2. PowerBuilder
  3. Thursday, 31 March 2022 18:17 PM UTC

We have both Appeon PowerBuilder 2019 and 2021 installed.  I created an executable from 2021 and the .exe file required admin rights to run.  Appeon 2019 does not work this way.  Is there a setting on 2021 I should set or unset to stop this behavior?

Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Thursday, 31 March 2022 20:03 PM UTC
  2. PowerBuilder
  3. # 1

Hi Anthony;

   There are no differences between PB 2019R3 compiled Apps and PB2021 compiled Apps execution wise. The only thing that I can think of is that in your PB2021 project that creates the App EXE, that you selected in the "Security" tab under the "Execution Level" property a value other than "As Invoker".

Regards ... Chris

Comment
There are no comments made yet.
Anthony Scruse Accepted Answer Pending Moderation
  1. Thursday, 31 March 2022 20:12 PM UTC
  2. PowerBuilder
  3. # 2

Thanks for the reply.  I checked all settings between 2019 and 2021 and both groups are the same including the one mentioned in your reply.  Both has execution level set to 'As Invoker'.  This is really strange as this is the first version (2021) of PowerBuilder where the .exe is created in such a way that the execution requires admin rights.  This 100% prevents us from deploying to production for the 10,000 clients we serve.

Comment
  1. Chris Pollach @Appeon
  2. Thursday, 31 March 2022 20:45 PM UTC
Hi Anthony ... BTW: Are you using the latest maintenance release of PB2021 ... build 1506?
  1. Helpful
  1. Anthony Scruse
  2. Friday, 1 April 2022 12:44 PM UTC
Yes, we are using the latest build 1506...
  1. Helpful
There are no comments made yet.
Armeen Mazda @Appeon Accepted Answer Pending Moderation
  1. Thursday, 31 March 2022 21:04 PM UTC
  2. PowerBuilder
  3. # 3

There were no changes made to client/server projects per the new features guide: https://docs.appeon.com/pb2021/whats_new/New_Features_2021.html

Please open a support ticket we try to help you troubleshoot, but I really think the issue is your environment/config.

Comment
  1. Anthony Scruse
  2. Friday, 1 April 2022 12:57 PM UTC
Thanks. I will open up a support ticket, however the environment and configuration are the same for both Appeon 2019 and 2021. Both are installed on the same computer and all default settings were used for each installation.
  1. Helpful
  1. Armeen Mazda @Appeon
  2. Friday, 1 April 2022 14:45 PM UTC
I understand, but in the product we made no such changes either. Also, you can see in the Q&A of Appeon Community that there is no such widespread issue with PB 2021.
  1. Helpful 1
  1. Anthony Scruse
  2. Friday, 1 April 2022 14:57 PM UTC
Thanks
  1. Helpful
There are no comments made yet.
mike S Accepted Answer Pending Moderation
  1. Friday, 1 April 2022 14:51 PM UTC
  2. PowerBuilder
  3. # 4

did you sign your exe

Comment
  1. Chris Pollach @Appeon
  2. Friday, 1 April 2022 17:29 PM UTC
FYI guys ,,, Signing or not signing the App EXE doe not determine that it always would try to run in Admin Mode.
  1. Helpful
  1. Armeen Mazda @Appeon
  2. Friday, 1 April 2022 18:53 PM UTC
UAC can potentially block unverified publisher and require admin-credentials. If you are already an admin or UAC is disabled then no such issue. If you spend some time Googling you'll see lots of complaints about this. Here is just one example: https://docs.microsoft.com/en-us/answers/questions/656593/how-to-stop-34do-you-want-to-allow-this-app-from-a.html
  1. Helpful
  1. Chris Pollach @Appeon
  2. Friday, 1 April 2022 19:42 PM UTC
True but, that's not Anthony's issue. Exe's compiled from R3 run in normal mode. Exe's compiled from 2021 always want to run "as admin". Both IDE's are on the same developer's machine. I've never had this issue on my W10 or W11 PC's, unless I change the "invoker" level in the compile project. So admin being required makes no sense regardless of signing.
  1. Helpful
There are no comments made yet.
Ronnie Po Accepted Answer Pending Moderation
  1. Friday, 1 April 2022 17:10 PM UTC
  2. PowerBuilder
  3. # 5

Does your app try to write anything to the directory where it's installed? As a quick test, can you move the entire app folder into the user's documents folder to see if it will run there?

Comment
  1. Anthony Scruse
  2. Friday, 1 April 2022 19:20 PM UTC
No, the application does not write to the installation directory. I also copied the application folder to the user's documents folder and the exe still required admin rights to run.
  1. Helpful
There are no comments made yet.
mike S Accepted Answer Pending Moderation
  1. Friday, 1 April 2022 20:01 PM UTC
  2. PowerBuilder
  3. # 6

when you run the pb 2021  app what exactly happens?  does it pop up and ask for admin rights, does it disappear, does it blow up?

 

when you say the 2019 exe run, is this an exe that you building right now? or was this a build that was done a while ago? 

 

 

Comment
  1. Anthony Scruse
  2. Friday, 1 April 2022 20:15 PM UTC
In reference to the 2021 app, the exe askes for admin rights and when granted the app runs.



As far as the 2019 it is a new app I built right before the 2021 app.
  1. Helpful
There are no comments made yet.
John Fauss Accepted Answer Pending Moderation
  1. Friday, 1 April 2022 21:29 PM UTC
  2. PowerBuilder
  3. # 7

How do start execution of the PB 2021 app? Via a desktop shortcut?

If so, just for chuckles, right-click the shortcut, go to Properties, click the Advanced... button on the Shortcut tab. Is "Run as administrator" checked?

What if you navigate to the folder where the PB 2021 app resides in Windows Explorer, right-click on the exe and select Properties, select the Compatibility tab, is "Run this program as an administrator" checked?

How was the PB 2021 app compiled/deployed? With the new PBAutoBuild feature? Using a build script using Jenkins or similar and the pbc210.exe stand-alone compiler? Manually via the PB Project painter? Any difference in the way the PB 2019 app was compiled?

Comment
  1. Anthony Scruse
  2. Saturday, 2 April 2022 15:02 PM UTC
Question: How do start execution of the PB 2021 app? Via a desktop shortcut?

Answer: By clicking the .exe from the folder where the application is stored.



Question: If so, just for chuckles, right-click the shortcut, go to Properties, click the Advanced... button on the Shortcut tab. Is "Run as administrator" checked?

Answer: Shortcut is not used.



Question: What if you navigate to the folder where the PB 2021 app resides in Windows Explorer, right-click on the exe and select Properties, select the Compatibility tab, is "Run this program as an administrator" checked?

Answer: Navigating to the folder is how I run the application. I followed your suggestion and checked the run as administrator, and it had no affect.



Question: How was the PB 2021 app compiled/deployed?

Answer: The app was compiled from a project in PowerBuilder 2021. I then add the runtime and app .dlls to the folder and run the application. Keep in mind this is a pure development environment, so no deployment/installation software is used.

Question: With the new PBAutoBuild feature?

Answer: No

Question: Using a build script using Jenkins or similar and the pbc210.exe stand-alone compiler?

Answer: No

Question: Manually via the PB Project painter?

Answer: Yes

Question: Any difference in the way the PB 2019 app was compiled?

Answer: I only use one way.



Answer:
  1. Helpful
  1. John Fauss
  2. Monday, 4 April 2022 15:45 PM UTC
I'm glad to hear you have solved the problem Anthony! I asked my son (he's a Windows Server Administrator) this past weekend if he had any clues what could be the cause, and he was as stumped as the rest of us.

Would you please take a moment and mark this issue as resolved? Thank you!
  1. Helpful
There are no comments made yet.
Anthony Scruse Accepted Answer Pending Moderation
  1. Monday, 4 April 2022 15:01 PM UTC
  2. PowerBuilder
  3. # 8

All,

The issue turned out to be a corrupted project object that builds the exe in the target application.  
Once I deleted and recreated the project object that builds the exe the issue was solved.

Thanks for all the responses.

Antohny
Comment
  1. Chris Pollach @Appeon
  2. Monday, 4 April 2022 15:05 PM UTC
That is awesome news Anthony ... thanks for sharing the solution! :-)
  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.