1. sachidhanantham ramalingam
  2. PowerBuilder
  3. Monday, 5 September 2022 07:30 AM UTC

 Hi,

          Our application is in PB2019 R3, we need to show .PNG image (size: 50 X 26 pixels) on one of the Grid Datawindow column using Bitmap expression, we would like to know exact Height and Width need to set for showing the image clearly since we have tried PixelsToUnits() function also but we couldn’t see the image clearly on the column.

Please refer the attachment for actual images,

Kindly suggest, do we need to reduce the image size to fit in datawindow column width and height OR any other suggestions?

 

Thanks,
--Sachi...

Attachments (1)
René Ullrich Accepted Answer Pending Moderation
  1. Monday, 5 September 2022 11:39 AM UTC
  2. PowerBuilder
  3. # 1

You could simply scale the width and hight.

Your icon is 229 x 104 PBU. If you want a height of 60 PBU the width should be width = 229 * 60 / 104 = 132 PBU.

Looks good in my test datawindow.

Comment
There are no comments made yet.
sachidhanantham ramalingam Accepted Answer Pending Moderation
  1. Monday, 5 September 2022 11:12 AM UTC
  2. PowerBuilder
  3. # 2

Hi René Ullrich,

Thanks for your quick reply, 

We have fixed length of Height = 60 (PBU) for datawindow rows to show more rows in viewable area however can alter Width, so could you please suggest what would be the best way to handle this problem.

Thanks,
--Sachi...

Comment
There are no comments made yet.
René Ullrich Accepted Answer Pending Moderation
  1. Monday, 5 September 2022 09:07 AM UTC
  2. PowerBuilder
  3. # 3

Hi Sachi...,

You could change the units in datawindow General tab from "PowerBuilder (0)" to "Pixels (1)" to specify the correct pixel site you want.

I tested one of your icons with width 50 pixels and height 26 pixels and it look ok for me.

BTW: If you change back the units to "PowerBuilder (0)" it converts the values to PBUs (in my case 104 x 229, what are exactly the same values that I also get with PixelsToUnits).

HTH,

René

Comment
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.
We use cookies which are necessary for the proper functioning of our websites. We also use cookies to analyze our traffic, improve your experience and provide social media features. If you continue to use this site, you consent to our use of cookies.