1. Jonas Blomgren
  2. PowerBuilder
  3. Thursday, 12 September 2019 16:33 PM UTC

Hello
I am trying to change the toolbar backcolor in a menu from script.
I inherited the frame menu to a new name and changed the toolbar color,
and when using changemenu in the MDI window the original color is still there,
the menu itself changed ( have different menu text on 1 item)
But if i open a sheet and close it, the new toolbar color is showed...
Changing toolbar color in the sheet i can not figure out how to do.
Is this a bug or am i missing something ?
Attached a PB19 example to show my point.

Thanks

/Jonas

 

Attachments (1)
Accepted Answer
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Friday, 13 September 2019 13:16 PM UTC
  2. PowerBuilder
  3. # Permalink

Hi Jonas;

  Yes, the MDI Frame seems to be the issue. I redid my test using my framework's OrderEntry demo App, as follows:

Before Change Menu...

After Change Menu...

After OpenSheet...

  Looks like the MDI Frame is definitely interfering with the Menu's Toolbar!

I would like to suggest that you open a Support Ticket for this issue.

Regards ... Chris

Comment
  1. Jonas Blomgren
  2. Friday, 13 September 2019 14:49 PM UTC
Thank you Chris for confirming, i will report this on monday, have a nice weekend

/Jonas
  1. Helpful
There are no comments made yet.
Jonas Blomgren Accepted Answer Pending Moderation
  1. Friday, 13 September 2019 08:22 AM UTC
  2. PowerBuilder
  3. # 1

This is how it behaving in a MDI application

The problem is Toolbar Color, Menu Color seems to work.

also in a SDI application toolbar Color is working fine after a ChangeMenu()

 

Comment
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Thursday, 12 September 2019 20:23 PM UTC
  2. PowerBuilder
  3. # 2

Hi Jonas;

    Test ...

Original

ChangeMenu

Works OK for me!

Regards ... Chris

Comment
  1. Jonas Blomgren
  2. Thursday, 12 September 2019 20:31 PM UTC
Chris,

Are you using a mdi in your screen shot?
  1. Helpful
  1. Chris Pollach @Appeon
  2. Thursday, 12 September 2019 20:44 PM UTC
No .. that is a MAIN window type.
  1. Helpful
  1. Jonas Blomgren
  2. Thursday, 12 September 2019 20:48 PM UTC
my problem occurs in a mdi app, can't get it work as showed in the attached pb19 example app...
  1. Helpful
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Thursday, 12 September 2019 17:35 PM UTC
  2. PowerBuilder
  3. # 3

Hi Jonas;

   You cannot do that in any PB version as the background colour property in the menu object is "write protected". I have no idea why Sybase never addressed this PowerSoft restriction. 

:-(

Regards ... Chris

Comment
  1. Jonas Blomgren
  2. Thursday, 12 September 2019 18:11 PM UTC
Hello Chris

ChangeMenu() does not work, atleast not toolbar color...

  1. Helpful
  1. Chris Pollach @Appeon
  2. Thursday, 12 September 2019 18:46 PM UTC
You can set the Toolbar Colour in the Menu Painter. Thus a ChangeMenu() on a new Menu Object class would work. Note: You need to change both the MenuBackColor and ToolBarBackColor properties to be consistent (colour wise).
  1. Helpful
  1. Jonas Blomgren
  2. Thursday, 12 September 2019 20:04 PM UTC
That was exactly what i did, don't work...
  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.