cancel
Showing results for 
Search instead for 
Did you mean: 

Window Size in percentage

aayush_dubey3
Explorer
0 Kudos

Hello All,

I have created a new pop-up window. The size of this window should be about <b>25% of the normal window</b>. How can this be achieved. I need to do this as different machines may have different resolutions.

Regards,

Aayush

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Aayush,

Try using the following method before opening the popup.

window.setWindowSize();

Regards, Anilkumar

aayush_dubey3
Explorer
0 Kudos

Hello Anilkumar,

I used the same method as

window.setWindowSize(600,400);

but it needs pixels as integers (600 & 400). I am afraid that there would be resolution problem.

Can we set the window size as:

window.setWindowSize(0.25 *Parent_Window_Width,0.25 *Parent_Window_Height);

Regards,

Aayush