????????? ???????? ????? (DeskTop parameters)

<< Click to Display Table of Contents >>

Navigation:  Forum >

????????? ???????? ????? (DeskTop parameters)

Forum link

 


 

12-14-2019, 11:18 AM:

 

??? ???? ????? ???? ?????? ????????? ? ?????? ?????????. ??????????, ???????? ??? ?????????? ????????. ?????? ?? ???? ????????? ????? ???? ?????? ??????. ? ????? ?? ? ??????????? ?? ??????? ?????? ?? ??????? ???????????? ???? ???????? ??? ??????????????. (????????? ????????? ???????????? ????????? ?? ?????? ??? ?????????? ? ??? ???????????). ??? ????? ??? ??? ??????? ????? ???????? ????????? ?????? ?? ??????? ???????????? ?????????? ?????????. ? ?????? ??????? ?????????? ?????? ? ?????? ?????? (???????? ?????).

 

??? ??? ????????

 

My site can be opened by a browser from different devices. Computer, tablet or mobile phone. Each of these devices has its own screen size. I would like depending on the size of the screen on which the site is displayed to change its formatting. (apply different arrangement of elements on the screen for smartphones and for computers). To do this, I need to get the parameters of the screen on which the information is displayed by the browser at startup. Primarily interested in the height and width of the screen (desktop).

 

How to do it?

 


 

12-14-2019, 01:59 PM:

 

Look in the demos, there is a demo which shows this.

 

The page dimensions are available in:

 

WebApplication.FormWidth

 

WebApplication.Formheight

 


 

12-14-2019, 05:44 PM:

 

? ????????? ?? ???? ????? ??????? ? ????.

 

WebApplication.FormWitdh - ? ????????. ????????? ?????? ????????? ?????. ? ??? ???????? ??????? ??????

 

? ???? ??????? ???? ????? fmTail. ? DesignTime ? ???? ?????????? ?? ???????, ?? ? ?? ???? ??? ?????????? ??????? ??????????. ??????? ????????? :

 

fmTail.Width := 1000 ;

 

?????? ??????

 

[dcc32 Error] unTail.pas(1132): E2003 Undeclared identifier: 'fmTail'

 

455 / 10000

 

??????????

 

????????? ?GoogleBing

 

Unfortunately I can not find examples in the demo.

 

Web Application.Form With - I read. The next question is this. And how to change the size of the form?

 

There is an fmTail form in my project. In DesignTime, I can set its dimensions, But I don't know how to set the dimensions programmatically. Variant writing :

 

fm Tail.Width: = 1000 ;

 

throws an error

 

[[dcc32 Error] until.pos(1132): E2003 Undeclared identifier: 'fmTail'

 

How to access this parameter correctly ?

 

??? ????????? ?????????? ? ????? ????????? ?

 


 

12-15-2019, 05:18 PM:

 

fmTail is the name of your form? If so you need to add it to your uses clause of the unit you want to use it from. This is standard Delphi stuff.

 

Regarding setting the size. I dont think the browser lets you do that except with a new window.