1. Daniel Agudelo
  2. PowerBuilder
  3. Tuesday, 25 February 2020 21:09 PM UTC

Hi Guys,

again me haha, someone has the knowledge how i can to change the style of a button?

i would like to change the background color and the border style but i don't know how can to do it, i don't know if will can to do that the button looks with a circle border or similar, there is some module, example or dll with i'll can to do this.

thanks and regards... and, again, excuse me for my english, i'm feeling that's worst each time :(

PD: currently i'm using the "flat" style with everyone buttons, but i would like to do something better

Accepted Answer
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Tuesday, 25 February 2020 21:36 PM UTC
  2. PowerBuilder
  3. # Permalink

Hi Daniel;

   The CB's style & colour is currently controlled by the O/S - the way the PBVM works today. However in PB 2019 R2, you will be able to control this by using the new Theme feature.

   TIP: If you only need to control the background colours of the CB, use a Picture Button instead. Then use a solid colour only image that utilizes the colour you need. You can also change the picture name dyunamically at run-time to point to another colourized image when you need to indicate another "State" of your application in it's business transaction processing cycle.

HTH

Regards ... Chris

Comment
  1. Daniel Agudelo
  2. Wednesday, 26 February 2020 14:45 PM UTC
Thanks, i think that i'll go to use that
  1. Helpful
There are no comments made yet.
Eduardo G. Accepted Answer Pending Moderation
  1. Wednesday, 26 February 2020 08:57 AM UTC
  2. PowerBuilder
  3. # 1

That's how I got it:
- Create an inherent uov_button from userobject
- Insert a datawindow into the uov_button
In the datawindow:
- Create a rounded rectangle with the size and color gradient you want. Apply your imagination :-)
- Create a rounded rectangle of equal size and transparent so that when you pass the cursor over it, it indicates that it has the focus.
- Add a computed field so you can code the tooltip
- Add a text object so you can code the text
In the uov_button
- Codes that when the cursor passes over the dw, the transparent rectangle is activated and when it exits, it is deactivated
- Encode to add the tooltip and text of the button

... the rest is up to you :-D

 

Here is my implementation, just as I described it to you but with images in the dw, as you see the cursor is on the second button.

Comment
  1. Michael Kramer
  2. Wednesday, 26 February 2020 09:14 AM UTC
The DataWindow truly is an amazing technology. Loved it from first time I saw it.
  1. Helpful
  1. Chris Pollach @Appeon
  2. Wednesday, 26 February 2020 20:12 PM UTC
Awesome Edwardo ... "Have you hugged your DataWindow(s) today?" LOL!
  1. Helpful
  1. Eduardo G.
  2. Thursday, 27 February 2020 12:29 PM UTC
What can I say ... the Datawindow is the best there is. XDDDDDD
  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.