View Full Version : تغییر اندازه فرم متناسب با رزولیشن
سنبله کار
چهارشنبه 05 مهر 1385, 08:09 صبح
همونطور که می دونید در ویندوز انواع رزولیشن پیش بینی شده که هر کسی بنا بر سلیقه و نیازش یکی از اونها رو انتخاب می کنه .
هنگامی که ما برنامه ای رو برای کاربران نامشخصی تهیه می کنیم نمی دونیم که اونها از چه رزولیشنی استفاده می کنن تا اندازه فرمهامونو متناسب با اون طراحی کنیم .
از طرفی اگر بخواهیم موقع اجرای برنامه رزولیشن صفحه نمایش کاربر رو به رزولیشنی مناسب برنامه خودمون تغییر بدیم عملا خلاف قاعده userfriend کار کردیم و به مرور خودمون باعث کاهش محبوبیت برنامه می شیم .
این مقدمه برای این بود که از دوستان بخوام بهترین روشی که برای تغییر اندازه فرمها و کنترلهای داخلشون سراغ دارن اعلام کنن به طوری که به صورت داینامیک حتی با اضافه شدن یا کم شدن کنترلها باز هم فرم بدون ارور تغییر اندازه بده .
ممنون
moustafa
جمعه 07 مهر 1385, 09:43 صبح
خود من با این مسئله در محل کار مواجه شدم دو برنامه یکی با اکسس و دیگری با دلفی که روی رزولوشن خاصی تنظیم شده هر کاربری که می خواهد کار کنه هی باید رزولوشن سیستم رو بنا به برنامه خودش تنظیم کنه
سنبله کار
دوشنبه 10 مهر 1385, 07:46 صبح
یک تابعی نوشتم که بر اساس رزولیشن ضریبی به سایز تمام کنترلهای فرم می ده البته کامل آزمایش نکردم ولی فکر می کنم با کمی اصلاحات چیز خوبی بشه .
Public Function resiz(frm)
On Error GoTo Err_Command
Dim i, z
Call Get_System_Metrics
Select Case dblXRes
Case 800
z = 1.25
Case 1024
z = 1.6
Case 1152
z = 1.8
Case 1280
z = 2
Case 1600
z = 2.5
Case 1792
z = 2.8
Case 1800
z = 2.8125
Case 1856
z = 2.9
Case 1920
z = 3
Case Else
z = 1
End Select
Forms(frm).InsideHeight = Forms(frm).InsideHeight * z
Forms(frm).InsideWidth = Forms(frm).InsideWidth * z
Forms(frm).Detail.Height = Forms(frm).Detail.Height * z
For i = 0 To Forms(frm).Controls.Count
Forms(frm).Controls(i).left = Forms(frm).Controls(i).left * z
Forms(frm).Controls(i).top = Forms(frm).Controls(i).top * z
Forms(frm).Controls(i).Width = Forms(frm).Controls(i).Width * z
Forms(frm).Controls(i).Height = Forms(frm).Controls(i).Height * z
Forms(frm).Controls(i).FontSize = Forms(frm).Controls(i).FontSize * (z / 1.3)
Next
Exit_Command:
Exit Function
Err_Command:
MsgBox Err.Description, , Err.Number
Resume Exit_Command
End Function
برای بدست آوردن رزولیشن هم از اینجا (http://barnamenevis.org/forum/showthread.php?t=52690)استفاده کنید.
برای استفاده از این تابع کافیه در لود فرم این کد نوشته بشه
resiz (Me.name)
ROGHANI
یک شنبه 16 مهر 1385, 07:25 صبح
با سلام
در یکی از پرسشها راه حل تنظیم خودکار ابعاد فرم آمده بود. به این صورت که برنامه دستور تغییر SCREEN RESOLUTION را هنگام باز شدن صادر و پس از خروج نیز تغییرات را به حالت قبل در می آورد. اما مشکل اینجاست که هنگام ورود به برنامه MONITOR SETTING روی 60HERTZ تنظیم میشود که موجب چشمک زدن مانیتور می شود. آیا برای حل این مشکل راحی وجود دارد.
amirsadeghi
یک شنبه 16 مهر 1385, 08:50 صبح
بهتره که ابعاد ملنیتور رو کم و زیاد نکنی ابعاد فرمها تو کم و زیاد کن
محل قرار گیری کنترل ها رو به صورت در حال اجرای برنامه بده
مانیتور رو چک کن با استفاده از تنظیمات مانیتور ابعاد فرمها تو تنظیم کن
ROGHANI
یک شنبه 16 مهر 1385, 09:27 صبح
وقتیکه برنامه روی چند کامپیوتر با مانیتورهای متفاوت کار می کنه باید چکار کرد
amirsadeghi
یک شنبه 16 مهر 1385, 09:34 صبح
تو کافیه یک بار توی کامپیوتر خودت با رزولوشن های مختلف امتحان کنی ابعاد فرم و جای کنترل ها رو توی form_activate بدی بعد هر جا اجرا بشه درسته
ROGHANI
یک شنبه 16 مهر 1385, 13:00 عصر
درصورتی درست کار میکنه که رزولیشن همه مانیتورها یکسان باشه.
آیا در غیر اینصورت جواب میدهد؟؟؟؟
HAMRAHSOFT.IR
یک شنبه 16 مهر 1385, 13:05 عصر
شما متونی همشه فرمهات را بصورت سایز مشخص طراحی کنی که هچکاه نیاز به اینکه مانیتور رانتظیم کنی نباشه
ROGHANI
یک شنبه 16 مهر 1385, 13:52 عصر
یعنی هنگام اجرا مطابق ابعاد تعریف شده در بیاید.
اگر اینطوری باشد روی صفحه مانیتور بزرگ قسمتی از صفحه خالی خواهد بود مگر اینکه رزولیشن یکسان باشد.
HAMRAHSOFT.IR
یک شنبه 16 مهر 1385, 21:10 عصر
دوست خوب شما می خوای هنگام اجرا تمام صفحه باشه یا بصورت اندازه خاصی باشه
amirsadeghi
دوشنبه 17 مهر 1385, 05:44 صبح
نگاه کن
تو وقتی اندازه مانیتورت مثلا 800*600 باشه اندازه فرم رو میدی 800*600 و وقتی اندازه مانیتور 1024*768 باشه اندازه فرمت رو می دی 1024*768 البته خودت باید بررسی کنی ببینی الان رزولوشن چنده بع ابعاد فرم رو تغییر بدی
همه این کارها توی رویداد activate اتفاق می افته
متوجه شدی چی شد؟
ROGHANI
دوشنبه 17 مهر 1385, 07:47 صبح
دوستان
1- miz9000
تمام صفحه
2- amirsadeghi
هر مانیتوری ممکنه روی یک ابعادی مثلا 800*600 یا 1024*768 تنظیم باشه .ما نمیتوانیم اپراتورها را مجبور کنیم مثلا کامپیوترشان را روی 800*600 تنظیم کنند. یک برنامه صحیح آنست که ابعادش متناسب با رزولیشن مانیتورها ابعادش متغیر و به اندازه تمام صفحه مانیتور درآید.
amirsadeghi
دوشنبه 17 مهر 1385, 08:50 صبح
خوب من هم همینو میگم
میگم وقتی فرم می خواد لود بشه بررسی کن ببین سیستمی که برنامه داره روش اجرا میشه رزولوشنش چنده
خواب وقتی فهمیدی حالا ابعاد فرمتو تنظیم کن
sub form_activate()
form.width = screen.width
form.heigh = screen.height
end sub
حالا کم و زیادشو بعد خودت انجام بده
حالا روال کار رو فهمیدی یا بازم برات توضیح بدم
HAMRAHSOFT.IR
دوشنبه 17 مهر 1385, 09:51 صبح
دوست خوب من اگه امکان داره یک نمونه بزار تامن متوجه منظور شما بشوم
راستی ایدی من MRZ9000 می باشد نه MIZ9000
سنبله کار
دوشنبه 17 مهر 1385, 11:30 صبح
در گفتگوی برنامه های کاربردی یکی از دوستان چنین چیزی رو قرار داده بود که بدرستی هم کار می کرد . اگه پیداش کنم آدرسشو قرار می دم .
mohammadgij
دوشنبه 17 مهر 1385, 16:27 عصر
یعنی اینجوری شما می خوای اندازه تمام آبجکت ها و اندازه فونت اونا رو تغییر بدی؟ خب من فکر کنم یه چند سالی از انتخاب Shortcut برنامت تا اجرای فرم مورد نظر طول میکشه مگه نه؟
یک برنامه صحیح آنست که ابعادش متناسب با رزولیشن مانیتورها ابعادش متغیر و به اندازه تمام صفحه مانیتور درآید.
این جمله از کی هست؟؟؟؟ من البته نسبت به تجربه محدودی که دارم توی سیستم هایی که دیدم نرم افزار توی محیط 800*600 طراحی میشه و با تغییر رزولوشن مانیتور تنها اتفاقی که میفته اینه که نرم افزار مربوطه در Center مانیتور قرار میگیره و مابقی فضا رو صفحه سفید رنگ یا حالا به انتخاب کاربر پر می کنه
سنبله کار
سه شنبه 18 مهر 1385, 07:49 صبح
من هم بعضی جاها همینی شما می گی قرار دادم اما می دونم که کاربرام علاقمندن فرمها انعطاف بیشتری داشته باشن .
شاپرک
سه شنبه 18 مهر 1385, 10:13 صبح
من یه برنامه پیدا کردم که این کار رو انجام میده یعنی با تغییر سایز رزولوشن سایز تمام Object ها تغییر میکنه .... اما :
یک error داره که نمیتونم اصلاحش کنم .
سنبله کار
سه شنبه 18 مهر 1385, 10:21 صبح
کافیه در لود هر فرم بنویسید ReSizeForm Me
اینم ماژولش
'---------------------------------------------------------------------------------------
' Module : modResizeForm
' Author : Jamie Czernik BSc {jamie@jamiessoftware.tk}
' Purpose : Resizes Microsoft Access forms to fit the current screen resolution.
' Use : Work on a back-up copy of your application first.
' Change the constant DESIGN_HORZRES to the horizontal screen resolution
' used when forms were designed. Change the constant DESIGN_VERTRES to the
' vertical screen resolution used when forms were designed.
' Change DESIGN_PIXELS to the DPI used if required.
' Call ResizeForm Me on the onLoad event for each form (even sub forms).
' Bugs: : Tab controls and Option Groups are very difficult to handle - see comments
' throughout code for more information. Scaling forms up works much better
' than trying to scale forms down. Scaling down will probably distrot fronts.
' FIX:- Redesign forms to fit lowest resoltion and scale up instead.
' Send bug reports to: jamie@jamiessoftware.tk for future fixes.
' (No immediate support is provided. *Please* check online help, message board
' and latest version at http://www.jamiessoftware.tk before sending bug reports)
' Test: Test your application at each possible screen resolution after installing.
' Please : Consider donating $5 or $10 if you find this code useful by visiting:-
' http://jamiessoftware.tk/resizeform/rf_download.html
' Credits : This modResizeForm module was created by Jamie Czernik
' Contains improvement suggestions/updates from: Dr. Martin Dumskyj,
' Nathan Carroll & Wilfrid Underwood.
' Contains enhancements which fixed some problems in combo boxes, list
' boxes, and tab controls from: Myke Myers.
' Updated : July 2004.
'---------------------------------------------------------------------------------------
Option Compare Database
Option Explicit
'-----------------------------MODULE CONSTANTS & VARIABLES------------------------------
Private Const DESIGN_HORZRES As Long = 640 '<- CHANGE THIS VALUE TO THE RESOLUTION
'YOU DESIGNED YOUR FORMS IN.
'(e.g. 800 X 600 -> 800)
Private Const DESIGN_VERTRES As Long = 480 '<- CHANGE THIS VALUE TO THE RESOLUTION
'YOU DESIGNED YOUR FORMS IN.
'(e.g. 800 X 600 -> 600)
Private Const DESIGN_PIXELS As Long = 96 '<- CHANGE THIS VALUE TO THE DPI
'SETTING YOU DESIGNED YOUR FORMS IN.
'(If in doubt do not alter the
'DESIGN_PIXELS setting as most
'systems use 96 dpi.)
Public Const WM_HORZRES As Long = 8
Private Const WM_VERTRES As Long = 10
Private Const WM_LOGPIXELSX As Long = 88
Private Const TITLEBAR_PIXELS As Long = 18
Private Const COMMANDBAR_PIXELS As Long = 26
Private Const COMMANDBAR_LEFT As Long = 0
Private Const COMMANDBAR_TOP As Long = 1
Private OrigWindow As tWindow 'Module level variable holds the
'original window dimensions before
'resize.
Private Type tRect
left As Long
Top As Long
right As Long
bottom As Long
End Type
Private Type tDisplay
Height As Long
Width As Long
DPI As Long
End Type
Private Type tWindow
Height As Long
Width As Long
End Type
Private Type tControl
Name As String
Height As Long
Width As Long
Top As Long
left As Long
End Type
'-------------------------- END MODULE CONSTANTS & VARIABLES----------------------------
'------------------------------------API DECLARATIONS-----------------------------------
Public Declare Function WM_apiGetDeviceCaps Lib "gdi32" Alias "GetDeviceCaps" _
(ByVal hdc As Long, ByVal nIndex As Long) As Long
Private Declare Function WM_apiGetDesktopWindow Lib "user32" Alias "GetDesktopWindow" _
() As Long
Public Declare Function WM_apiGetDC Lib "user32" Alias "GetDC" _
(ByVal hwnd As Long) As Long
Private Declare Function WM_apiReleaseDC Lib "user32" Alias "ReleaseDC" _
(ByVal hwnd As Long, ByVal hdc As Long) As Long
Private Declare Function WM_apiGetWindowRect Lib "user32.dll" Alias "GetWindowRect" _
(ByVal hwnd As Long, lpRect As tRect) As Long
Private Declare Function WM_apiMoveWindow Lib "user32.dll" Alias "MoveWindow" _
(ByVal hwnd As Long, ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, _
ByVal nHeight As Long, ByVal bRepaint As Long) As Long
Private Declare Function WM_apiIsZoomed Lib "user32.dll" Alias "IsZoomed" _
(ByVal hwnd As Long) As Long
'--------------------------------- END API DECLARATIONS----------------------------------
'---------------------------------------------------------------------------------------
' Procedure : getScreenResolution
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Function returns the current height, width and dpi.
'---------------------------------------------------------------------------------------
Private Function getScreenResolution() As tDisplay
Dim hDCcaps As Long
Dim lngRtn As Long
On Error Resume Next
'API call get current resolution:-
hDCcaps = WM_apiGetDC(0) 'Get display context for desktop (hwnd = 0).
With getScreenResolution
.Height = WM_apiGetDeviceCaps(hDCcaps, WM_VERTRES)
.Width = WM_apiGetDeviceCaps(hDCcaps, WM_HORZRES)
.DPI = WM_apiGetDeviceCaps(hDCcaps, WM_LOGPIXELSX)
End With
lngRtn = WM_apiReleaseDC(0, hDCcaps) 'Release display context.
End Function
'---------------------------------------------------------------------------------------
' Procedure : getFactor
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Function returns the value that the form's/control's height, width, top &
' left should be multiplied by to fit the current screen resolution.
'---------------------------------------------------------------------------------------
Private Function getFactor(blnVert As Boolean) As Single
Dim sngFactorP As Single
On Error Resume Next
If getScreenResolution.DPI <> 0 Then
sngFactorP = DESIGN_PIXELS / getScreenResolution.DPI
Else
sngFactorP = 1 'Error with dpi reported so assume 96 dpi.
End If
If blnVert Then 'return vertical resolution.
getFactor = (getScreenResolution.Height / DESIGN_VERTRES) * sngFactorP
Else 'return horizontal resolution.
getFactor = (getScreenResolution.Width / DESIGN_HORZRES) * sngFactorP
End If
End Function
'---------------------------------------------------------------------------------------
' Procedure : ReSizeForm
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Routine should be called on a form's onOpen or onLoad event.
'---------------------------------------------------------------------------------------
Public Sub ReSizeForm(ByVal frm As Access.Form)
Dim rectWindow As tRect
Dim lngWidth As Long
Dim lngHeight As Long
Dim sngVertFactor As Single
Dim sngHorzFactor As Single
On Error Resume Next
sngVertFactor = getFactor(True) 'Local function returns vertical size change.
sngHorzFactor = getFactor(False) 'Local function returns horizontal size change.
Resize sngVertFactor, sngHorzFactor, frm 'Local procedure to resize form sections & controls.
If WM_apiIsZoomed(frm.hwnd) = 0 Then 'Don't change window settings for max'd form.
Access.DoCmd.RunCommand acCmdAppMaximize 'Maximize the Access Window.
'Store for dimensions in rectWindow:-
Call WM_apiGetWindowRect(frm.hwnd, rectWindow)
'Calculate and store form height and width in local variables:-
With rectWindow
lngWidth = .right - .left
lngHeight = .bottom - .Top
End With
'Resize the form window as required (don't resize this for sub forms):-
If frm.Parent.Name = VBA.vbNullString Then
Call WM_apiMoveWindow(frm.hwnd, ((getScreenResolution.Width - _
(sngHorzFactor * lngWidth)) / 2) - getLeftOffset, _
((getScreenResolution.Height - (sngVertFactor * lngHeight)) / 2) - _
getTopOffset, lngWidth * sngHorzFactor, lngHeight * sngVertFactor, 1)
End If
End If
Set frm = Nothing 'Free up resources.
End Sub
'---------------------------------------------------------------------------------------
' Procedure : Resize
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Routine re-scales the form sections and controls.
'---------------------------------------------------------------------------------------
Private Sub Resize(sngVertFactor As Single, sngHorzFactor As Single, ByVal frm As Access.Form)
Dim ctl As Access.Control 'Form control variable.
Dim arrCtls() As tControl 'Array of Tab and Option Group control properties.
Dim lngI As Long 'Loop counter.
Dim lngJ As Long 'Loop counter.
Dim lngWidth As Long 'Stores form's new width.
Dim lngHeaderHeight As Long 'Stores header's new height.
Dim lngDetailHeight As Long 'Stores detail's new height.
Dim lngFooterHeight As Long 'Stores footer's new height.
Dim blnHeaderVisible As Boolean 'True if form header visible before resize.
Dim blnDetailVisible As Boolean 'True if form detail visible before resize.
Dim blnFooterVisible As Boolean 'True if form footer visible before resize.
Const FORM_MAX As Long = 31680 'Maximum possible form width & section height.
On Error Resume Next
With frm
.Painting = False 'Turn off form painting.
'Calculate form's new with and section heights and store in local variables
'for later use:-
lngWidth = .Width * sngHorzFactor
lngHeaderHeight = .Section(Access.acHeader).Height * sngVertFactor
lngDetailHeight = .Section(Access.acDetail).Height * sngVertFactor
lngFooterHeight = .Section(Access.acFooter).Height * sngVertFactor
'Now maximize the form's width and height while controls are being resized:-
.Width = FORM_MAX
.Section(Access.acHeader).Height = FORM_MAX
.Section(Access.acDetail).Height = FORM_MAX
.Section(Access.acFooter).Height = FORM_MAX
'Hiding form sections during resize prevents invalid page fault after
'resizing column widths for list boxes on forms with a header/footer:-
blnHeaderVisible = .Section(Access.acHeader).Visible
blnDetailVisible = .Section(Access.acDetail).Visible
blnFooterVisible = .Section(Access.acFooter).Visible
.Section(Access.acHeader).Visible = False
.Section(Access.acDetail).Visible = False
.Section(Access.acFooter).Visible = False
End With
'Resize array to hold 1 element:-
ReDim arrCtls(0)
'Gather properties for Tabs and Option Groups to recify height/width problems:-
For Each ctl In frm.Controls
If ((ctl.ControlType = Access.acTabCtl) Or _
(ctl.ControlType = Access.acOptionGroup)) Then
With arrCtls(lngI)
.Name = ctl.Name
.Height = ctl.Height
.Width = ctl.Width
.Top = ctl.Top
.left = ctl.left
End With
lngI = lngI + 1
ReDim Preserve arrCtls(lngI) 'Increase the size of the array.
End If
Next ctl
'Resize and locate each control:-
For Each ctl In frm.Controls
If ctl.ControlType <> Access.acPage Then 'Ignore pages in Tab controls.
With ctl
.Height = .Height * sngVertFactor
.left = .left * sngHorzFactor
.Top = .Top * sngVertFactor
.Width = .Width * sngHorzFactor
.FontSize = .FontSize * sngVertFactor
'Enhancement by Myke Myers --------------------------------------->
'Fix certain Combo Box, List Box and Tab control properties:-
Select Case .ControlType
Case Access.acListBox
.ColumnWidths = adjustColumnWidths(.ColumnWidths, sngHorzFactor)
Case Access.acComboBox
.ColumnWidths = adjustColumnWidths(.ColumnWidths, sngHorzFactor)
.ListWidth = .ListWidth * sngHorzFactor
Case Access.acTabCtl
.TabFixedWidth = .TabFixedWidth * sngHorzFactor
.TabFixedHeight = .TabFixedHeight * sngVertFactor
End Select
'------------------------------------> End enhancement by Myke Myers.
End With
End If
Next ctl
'************************************************* *******
'* Note if scaling form up: If Tab controls or Option *
'* Groups are too near the bottom or right side of the *
'* form they WILL distort due to the way that Access *
'* keeps the child controls within the control frame. *
'* Try moving these controls left or up if possible. *
'* The opposite is true for scaling down so in this *
'* case try moving these controls right or down. *
'************************************************* *******
'Now try to rectify Tabs and Option Groups height/widths:-
For lngJ = 0 To lngI
With frm.Controls.Item(arrCtls(lngJ).Name)
.left = arrCtls(lngJ).left * sngHorzFactor
.Top = arrCtls(lngJ).Top * sngVertFactor
.Height = arrCtls(lngJ).Height * sngVertFactor
.Width = arrCtls(lngJ).Width * sngHorzFactor
End With
Next lngJ
'Now resize height for each section and form width using stored values:-
With frm
.Width = lngWidth
.Section(Access.acHeader).Height = lngHeaderHeight
.Section(Access.acDetail).Height = lngDetailHeight
.Section(Access.acFooter).Height = lngFooterHeight
'Now unhide form sections:-
.Section(Access.acHeader).Visible = blnHeaderVisible
.Section(Access.acDetail).Visible = blnDetailVisible
.Section(Access.acFooter).Visible = blnFooterVisible
.Painting = True 'Turn form painting on.
End With
Erase arrCtls 'Destory array.
Set ctl = Nothing 'Free up resources.
End Sub
'---------------------------------------------------------------------------------------
' Procedure : getTopOffset
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Function returns the total size in pixels of menu/toolbars at the top of
' the Access window allowing the form to be positioned in the centre of the
' screen.
'---------------------------------------------------------------------------------------
Private Function getTopOffset() As Long
Dim cmdBar As Object
Dim lngI As Long
On Error GoTo err
For Each cmdBar In Application.CommandBars
If ((cmdBar.Visible = True) And (cmdBar.Position = COMMANDBAR_TOP)) Then
lngI = lngI + 1
End If
Next cmdBar
getTopOffset = (TITLEBAR_PIXELS + (lngI * COMMANDBAR_PIXELS))
exit_fun:
Exit Function
err:
'Assume only 1 visible command bar plus the title bar:
getTopOffset = TITLEBAR_PIXELS + COMMANDBAR_PIXELS
Resume exit_fun
End Function
'---------------------------------------------------------------------------------------
' Procedure : getLeftOffset
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Function returns the total size in pixels of menu/toolbars at the left of
' the Access window allowing the form to be positioned in the centre of the
' screen.
'---------------------------------------------------------------------------------------
Private Function getLeftOffset() As Long
Dim cmdBar As Object
Dim lngI As Long
On Error GoTo err
For Each cmdBar In Application.CommandBars
If ((cmdBar.Visible = True) And (cmdBar.Position = COMMANDBAR_LEFT)) Then
lngI = lngI + 1
End If
Next cmdBar
getLeftOffset = (lngI * COMMANDBAR_PIXELS)
exit_fun:
Exit Function
err:
'Assume no visible command bars:-
getLeftOffset = 0
Resume exit_fun
End Function
'---------------------------------------------------------------------------------------
' Procedure : adjustColumnWidths
' DateTime : 27/01/2003
' Author : Myke Myers [Split() replacement for Access 97 by Jamie Czernik]
' Purpose : Adjusts column widths for list boxes and combo boxes.
'---------------------------------------------------------------------------------------
Private Function adjustColumnWidths(strColumnWidths As String, sngFactor As Single) _
As String
Dim astrColumnWidths() As String
Dim strTemp As String
Dim lngI As Long
Dim lngJ As Long
'Get the column widths:-
'THIS CODE BY JAMIE CZERNIK------------------------------------------->
'Replace the Split() function as not available in Access 97:
ReDim astrColumnWidths(0)
For lngI = 1 To VBA.Len(strColumnWidths)
Select Case VBA.Mid(strColumnWidths, lngI, 1)
Case Is <> ";"
astrColumnWidths(lngJ) = astrColumnWidths(lngJ) & VBA.Mid( _
strColumnWidths, lngI, 1)
Case ";"
lngJ = lngJ + 1
ReDim Preserve astrColumnWidths(lngJ) 'Resize the array.
End Select
Next lngI
lngI = 0
'--------------------------------------------> END CODE BY JAMIE CZERNIK.
'Access 2000/2002 users can uncomment the line below and remove the split()
'replacement above.
'astrColumnWidths = Split(strColumnWidths, ";")'Available in Access 2000/2002 only
Do Until lngI > UBound(astrColumnWidths) 'Loop through all divisions
strTemp = strTemp & CSng(astrColumnWidths(lngI)) * sngFactor & ";"
lngI = lngI + 1
Loop
adjustColumnWidths = strTemp
Erase astrColumnWidths 'Destroy array.
End Function
'---------------------------------------------------------------------------------------
' Procedure : getOrigWindow
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Routine stores the original window dimensions before resizing call it
' when form loads. (before calling ResizeForm Me!).
' Call it: Form_Load()
' [More info in "Important Points" - point 5 - in help file.]
'---------------------------------------------------------------------------------------
Public Sub getOrigWindow(frm As Access.Form)
On Error Resume Next
OrigWindow.Height = frm.WindowHeight
OrigWindow.Width = frm.WindowWidth
End Sub
'---------------------------------------------------------------------------------------
' Procedure : RestoreWindow
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Routine restores the original window dimensions call it when form closes.
' Call it: Form_Close()
' [More info in "Important Points" - point 5 - in help file.]
'---------------------------------------------------------------------------------------
Public Sub RestoreWindow()
On Error Resume Next
Access.DoCmd.MoveSize , , OrigWindow.Width, OrigWindow.Height
Access.DoCmd.Save
End Sub
از یکی از برنامه های دوستان برداشتم ولی یادم نیست .
شاپرک
سه شنبه 18 مهر 1385, 11:16 صبح
این ماژول چیکار میکنه ؟ من که هیچ تغییری ندیدم !!!!!
میشه یک نمونه بذارید ؟
سنبله کار
سه شنبه 18 مهر 1385, 11:57 صبح
با تغییر رزولیشن ابعاد فرم و کنترلهای درون اون تغییر خواهد کرد .
artdesign
شنبه 27 آبان 1385, 19:37 عصر
من یه فایل exeمی خوام که resolution رو تغییر بده البته source خود فایل exeرو میخوام
سنبله کار
یک شنبه 28 آبان 1385, 13:56 عصر
تو بخش vb جستجو کنید
samaneh_h
دوشنبه 29 آبان 1385, 11:45 صبح
چه جوری میشه تعیین کرد که فرم دقیقان سمت راست صفحه بیفته؟؟(فکر کنم رزولوشن هم یکی از فاکتورهای این تعیین هست.برای همین اینجا سوالم رو مطرح کردم)
hassan9027
جمعه 28 تیر 1392, 02:56 صبح
سلام به همه ممنون میشم بگین این متن ماژول رو چجوری باید به پروژم اضافه کنم؟کجاش؟چجوری فراخوانیش کنم
morteza.m
جمعه 10 آبان 1392, 14:36 عصر
وقت اجرا به Call Get_System_Metrics گیر می ده. این چیه؟!
morteza.m
جمعه 10 آبان 1392, 15:45 عصر
کافیه در لود هر فرم بنویسید ReSizeForm Me
اینم ماژولش
'---------------------------------------------------------------------------------------
' Module : modResizeForm
' Author : Jamie Czernik BSc {jamie@jamiessoftware.tk}
' Purpose : Resizes Microsoft Access forms to fit the current screen resolution.
' Use : Work on a back-up copy of your application first.
' Change the constant DESIGN_HORZRES to the horizontal screen resolution
' used when forms were designed. Change the constant DESIGN_VERTRES to the
' vertical screen resolution used when forms were designed.
' Change DESIGN_PIXELS to the DPI used if required.
' Call ResizeForm Me on the onLoad event for each form (even sub forms).
' Bugs: : Tab controls and Option Groups are very difficult to handle - see comments
' throughout code for more information. Scaling forms up works much better
' than trying to scale forms down. Scaling down will probably distrot fronts.
' FIX:- Redesign forms to fit lowest resoltion and scale up instead.
' Send bug reports to: jamie@jamiessoftware.tk for future fixes.
' (No immediate support is provided. *Please* check online help, message board
' and latest version at http://www.jamiessoftware.tk before sending bug reports)
' Test: Test your application at each possible screen resolution after installing.
' Please : Consider donating $5 or $10 if you find this code useful by visiting:-
' http://jamiessoftware.tk/resizeform/rf_download.html
' Credits : This modResizeForm module was created by Jamie Czernik
' Contains improvement suggestions/updates from: Dr. Martin Dumskyj,
' Nathan Carroll & Wilfrid Underwood.
' Contains enhancements which fixed some problems in combo boxes, list
' boxes, and tab controls from: Myke Myers.
' Updated : July 2004.
'---------------------------------------------------------------------------------------
Option Compare Database
Option Explicit
'-----------------------------MODULE CONSTANTS & VARIABLES------------------------------
Private Const DESIGN_HORZRES As Long = 640 '<- CHANGE THIS VALUE TO THE RESOLUTION
'YOU DESIGNED YOUR FORMS IN.
'(e.g. 800 X 600 -> 800)
Private Const DESIGN_VERTRES As Long = 480 '<- CHANGE THIS VALUE TO THE RESOLUTION
'YOU DESIGNED YOUR FORMS IN.
'(e.g. 800 X 600 -> 600)
Private Const DESIGN_PIXELS As Long = 96 '<- CHANGE THIS VALUE TO THE DPI
'SETTING YOU DESIGNED YOUR FORMS IN.
'(If in doubt do not alter the
'DESIGN_PIXELS setting as most
'systems use 96 dpi.)
Public Const WM_HORZRES As Long = 8
Private Const WM_VERTRES As Long = 10
Private Const WM_LOGPIXELSX As Long = 88
Private Const TITLEBAR_PIXELS As Long = 18
Private Const COMMANDBAR_PIXELS As Long = 26
Private Const COMMANDBAR_LEFT As Long = 0
Private Const COMMANDBAR_TOP As Long = 1
Private OrigWindow As tWindow 'Module level variable holds the
'original window dimensions before
'resize.
Private Type tRect
left As Long
Top As Long
right As Long
bottom As Long
End Type
Private Type tDisplay
Height As Long
Width As Long
DPI As Long
End Type
Private Type tWindow
Height As Long
Width As Long
End Type
Private Type tControl
Name As String
Height As Long
Width As Long
Top As Long
left As Long
End Type
'-------------------------- END MODULE CONSTANTS & VARIABLES----------------------------
'------------------------------------API DECLARATIONS-----------------------------------
Public Declare Function WM_apiGetDeviceCaps Lib "gdi32" Alias "GetDeviceCaps" _
(ByVal hdc As Long, ByVal nIndex As Long) As Long
Private Declare Function WM_apiGetDesktopWindow Lib "user32" Alias "GetDesktopWindow" _
() As Long
Public Declare Function WM_apiGetDC Lib "user32" Alias "GetDC" _
(ByVal hwnd As Long) As Long
Private Declare Function WM_apiReleaseDC Lib "user32" Alias "ReleaseDC" _
(ByVal hwnd As Long, ByVal hdc As Long) As Long
Private Declare Function WM_apiGetWindowRect Lib "user32.dll" Alias "GetWindowRect" _
(ByVal hwnd As Long, lpRect As tRect) As Long
Private Declare Function WM_apiMoveWindow Lib "user32.dll" Alias "MoveWindow" _
(ByVal hwnd As Long, ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, _
ByVal nHeight As Long, ByVal bRepaint As Long) As Long
Private Declare Function WM_apiIsZoomed Lib "user32.dll" Alias "IsZoomed" _
(ByVal hwnd As Long) As Long
'--------------------------------- END API DECLARATIONS----------------------------------
'---------------------------------------------------------------------------------------
' Procedure : getScreenResolution
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Function returns the current height, width and dpi.
'---------------------------------------------------------------------------------------
Private Function getScreenResolution() As tDisplay
Dim hDCcaps As Long
Dim lngRtn As Long
On Error Resume Next
'API call get current resolution:-
hDCcaps = WM_apiGetDC(0) 'Get display context for desktop (hwnd = 0).
With getScreenResolution
.Height = WM_apiGetDeviceCaps(hDCcaps, WM_VERTRES)
.Width = WM_apiGetDeviceCaps(hDCcaps, WM_HORZRES)
.DPI = WM_apiGetDeviceCaps(hDCcaps, WM_LOGPIXELSX)
End With
lngRtn = WM_apiReleaseDC(0, hDCcaps) 'Release display context.
End Function
'---------------------------------------------------------------------------------------
' Procedure : getFactor
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Function returns the value that the form's/control's height, width, top &
' left should be multiplied by to fit the current screen resolution.
'---------------------------------------------------------------------------------------
Private Function getFactor(blnVert As Boolean) As Single
Dim sngFactorP As Single
On Error Resume Next
If getScreenResolution.DPI <> 0 Then
sngFactorP = DESIGN_PIXELS / getScreenResolution.DPI
Else
sngFactorP = 1 'Error with dpi reported so assume 96 dpi.
End If
If blnVert Then 'return vertical resolution.
getFactor = (getScreenResolution.Height / DESIGN_VERTRES) * sngFactorP
Else 'return horizontal resolution.
getFactor = (getScreenResolution.Width / DESIGN_HORZRES) * sngFactorP
End If
End Function
'---------------------------------------------------------------------------------------
' Procedure : ReSizeForm
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Routine should be called on a form's onOpen or onLoad event.
'---------------------------------------------------------------------------------------
Public Sub ReSizeForm(ByVal frm As Access.Form)
Dim rectWindow As tRect
Dim lngWidth As Long
Dim lngHeight As Long
Dim sngVertFactor As Single
Dim sngHorzFactor As Single
On Error Resume Next
sngVertFactor = getFactor(True) 'Local function returns vertical size change.
sngHorzFactor = getFactor(False) 'Local function returns horizontal size change.
Resize sngVertFactor, sngHorzFactor, frm 'Local procedure to resize form sections & controls.
If WM_apiIsZoomed(frm.hwnd) = 0 Then 'Don't change window settings for max'd form.
Access.DoCmd.RunCommand acCmdAppMaximize 'Maximize the Access Window.
'Store for dimensions in rectWindow:-
Call WM_apiGetWindowRect(frm.hwnd, rectWindow)
'Calculate and store form height and width in local variables:-
With rectWindow
lngWidth = .right - .left
lngHeight = .bottom - .Top
End With
'Resize the form window as required (don't resize this for sub forms):-
If frm.Parent.Name = VBA.vbNullString Then
Call WM_apiMoveWindow(frm.hwnd, ((getScreenResolution.Width - _
(sngHorzFactor * lngWidth)) / 2) - getLeftOffset, _
((getScreenResolution.Height - (sngVertFactor * lngHeight)) / 2) - _
getTopOffset, lngWidth * sngHorzFactor, lngHeight * sngVertFactor, 1)
End If
End If
Set frm = Nothing 'Free up resources.
End Sub
'---------------------------------------------------------------------------------------
' Procedure : Resize
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Routine re-scales the form sections and controls.
'---------------------------------------------------------------------------------------
Private Sub Resize(sngVertFactor As Single, sngHorzFactor As Single, ByVal frm As Access.Form)
Dim ctl As Access.Control 'Form control variable.
Dim arrCtls() As tControl 'Array of Tab and Option Group control properties.
Dim lngI As Long 'Loop counter.
Dim lngJ As Long 'Loop counter.
Dim lngWidth As Long 'Stores form's new width.
Dim lngHeaderHeight As Long 'Stores header's new height.
Dim lngDetailHeight As Long 'Stores detail's new height.
Dim lngFooterHeight As Long 'Stores footer's new height.
Dim blnHeaderVisible As Boolean 'True if form header visible before resize.
Dim blnDetailVisible As Boolean 'True if form detail visible before resize.
Dim blnFooterVisible As Boolean 'True if form footer visible before resize.
Const FORM_MAX As Long = 31680 'Maximum possible form width & section height.
On Error Resume Next
With frm
.Painting = False 'Turn off form painting.
'Calculate form's new with and section heights and store in local variables
'for later use:-
lngWidth = .Width * sngHorzFactor
lngHeaderHeight = .Section(Access.acHeader).Height * sngVertFactor
lngDetailHeight = .Section(Access.acDetail).Height * sngVertFactor
lngFooterHeight = .Section(Access.acFooter).Height * sngVertFactor
'Now maximize the form's width and height while controls are being resized:-
.Width = FORM_MAX
.Section(Access.acHeader).Height = FORM_MAX
.Section(Access.acDetail).Height = FORM_MAX
.Section(Access.acFooter).Height = FORM_MAX
'Hiding form sections during resize prevents invalid page fault after
'resizing column widths for list boxes on forms with a header/footer:-
blnHeaderVisible = .Section(Access.acHeader).Visible
blnDetailVisible = .Section(Access.acDetail).Visible
blnFooterVisible = .Section(Access.acFooter).Visible
.Section(Access.acHeader).Visible = False
.Section(Access.acDetail).Visible = False
.Section(Access.acFooter).Visible = False
End With
'Resize array to hold 1 element:-
ReDim arrCtls(0)
'Gather properties for Tabs and Option Groups to recify height/width problems:-
For Each ctl In frm.Controls
If ((ctl.ControlType = Access.acTabCtl) Or _
(ctl.ControlType = Access.acOptionGroup)) Then
With arrCtls(lngI)
.Name = ctl.Name
.Height = ctl.Height
.Width = ctl.Width
.Top = ctl.Top
.left = ctl.left
End With
lngI = lngI + 1
ReDim Preserve arrCtls(lngI) 'Increase the size of the array.
End If
Next ctl
'Resize and locate each control:-
For Each ctl In frm.Controls
If ctl.ControlType <> Access.acPage Then 'Ignore pages in Tab controls.
With ctl
.Height = .Height * sngVertFactor
.left = .left * sngHorzFactor
.Top = .Top * sngVertFactor
.Width = .Width * sngHorzFactor
.FontSize = .FontSize * sngVertFactor
'Enhancement by Myke Myers --------------------------------------->
'Fix certain Combo Box, List Box and Tab control properties:-
Select Case .ControlType
Case Access.acListBox
.ColumnWidths = adjustColumnWidths(.ColumnWidths, sngHorzFactor)
Case Access.acComboBox
.ColumnWidths = adjustColumnWidths(.ColumnWidths, sngHorzFactor)
.ListWidth = .ListWidth * sngHorzFactor
Case Access.acTabCtl
.TabFixedWidth = .TabFixedWidth * sngHorzFactor
.TabFixedHeight = .TabFixedHeight * sngVertFactor
End Select
'------------------------------------> End enhancement by Myke Myers.
End With
End If
Next ctl
'************************************************* *******
'* Note if scaling form up: If Tab controls or Option *
'* Groups are too near the bottom or right side of the *
'* form they WILL distort due to the way that Access *
'* keeps the child controls within the control frame. *
'* Try moving these controls left or up if possible. *
'* The opposite is true for scaling down so in this *
'* case try moving these controls right or down. *
'************************************************* *******
'Now try to rectify Tabs and Option Groups height/widths:-
For lngJ = 0 To lngI
With frm.Controls.Item(arrCtls(lngJ).Name)
.left = arrCtls(lngJ).left * sngHorzFactor
.Top = arrCtls(lngJ).Top * sngVertFactor
.Height = arrCtls(lngJ).Height * sngVertFactor
.Width = arrCtls(lngJ).Width * sngHorzFactor
End With
Next lngJ
'Now resize height for each section and form width using stored values:-
With frm
.Width = lngWidth
.Section(Access.acHeader).Height = lngHeaderHeight
.Section(Access.acDetail).Height = lngDetailHeight
.Section(Access.acFooter).Height = lngFooterHeight
'Now unhide form sections:-
.Section(Access.acHeader).Visible = blnHeaderVisible
.Section(Access.acDetail).Visible = blnDetailVisible
.Section(Access.acFooter).Visible = blnFooterVisible
.Painting = True 'Turn form painting on.
End With
Erase arrCtls 'Destory array.
Set ctl = Nothing 'Free up resources.
End Sub
'---------------------------------------------------------------------------------------
' Procedure : getTopOffset
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Function returns the total size in pixels of menu/toolbars at the top of
' the Access window allowing the form to be positioned in the centre of the
' screen.
'---------------------------------------------------------------------------------------
Private Function getTopOffset() As Long
Dim cmdBar As Object
Dim lngI As Long
On Error GoTo err
For Each cmdBar In Application.CommandBars
If ((cmdBar.Visible = True) And (cmdBar.Position = COMMANDBAR_TOP)) Then
lngI = lngI + 1
End If
Next cmdBar
getTopOffset = (TITLEBAR_PIXELS + (lngI * COMMANDBAR_PIXELS))
exit_fun:
Exit Function
err:
'Assume only 1 visible command bar plus the title bar:
getTopOffset = TITLEBAR_PIXELS + COMMANDBAR_PIXELS
Resume exit_fun
End Function
'---------------------------------------------------------------------------------------
' Procedure : getLeftOffset
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Function returns the total size in pixels of menu/toolbars at the left of
' the Access window allowing the form to be positioned in the centre of the
' screen.
'---------------------------------------------------------------------------------------
Private Function getLeftOffset() As Long
Dim cmdBar As Object
Dim lngI As Long
On Error GoTo err
For Each cmdBar In Application.CommandBars
If ((cmdBar.Visible = True) And (cmdBar.Position = COMMANDBAR_LEFT)) Then
lngI = lngI + 1
End If
Next cmdBar
getLeftOffset = (lngI * COMMANDBAR_PIXELS)
exit_fun:
Exit Function
err:
'Assume no visible command bars:-
getLeftOffset = 0
Resume exit_fun
End Function
'---------------------------------------------------------------------------------------
' Procedure : adjustColumnWidths
' DateTime : 27/01/2003
' Author : Myke Myers [Split() replacement for Access 97 by Jamie Czernik]
' Purpose : Adjusts column widths for list boxes and combo boxes.
'---------------------------------------------------------------------------------------
Private Function adjustColumnWidths(strColumnWidths As String, sngFactor As Single) _
As String
Dim astrColumnWidths() As String
Dim strTemp As String
Dim lngI As Long
Dim lngJ As Long
'Get the column widths:-
'THIS CODE BY JAMIE CZERNIK------------------------------------------->
'Replace the Split() function as not available in Access 97:
ReDim astrColumnWidths(0)
For lngI = 1 To VBA.Len(strColumnWidths)
Select Case VBA.Mid(strColumnWidths, lngI, 1)
Case Is <> ";"
astrColumnWidths(lngJ) = astrColumnWidths(lngJ) & VBA.Mid( _
strColumnWidths, lngI, 1)
Case ";"
lngJ = lngJ + 1
ReDim Preserve astrColumnWidths(lngJ) 'Resize the array.
End Select
Next lngI
lngI = 0
'--------------------------------------------> END CODE BY JAMIE CZERNIK.
'Access 2000/2002 users can uncomment the line below and remove the split()
'replacement above.
'astrColumnWidths = Split(strColumnWidths, ";")'Available in Access 2000/2002 only
Do Until lngI > UBound(astrColumnWidths) 'Loop through all divisions
strTemp = strTemp & CSng(astrColumnWidths(lngI)) * sngFactor & ";"
lngI = lngI + 1
Loop
adjustColumnWidths = strTemp
Erase astrColumnWidths 'Destroy array.
End Function
'---------------------------------------------------------------------------------------
' Procedure : getOrigWindow
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Routine stores the original window dimensions before resizing call it
' when form loads. (before calling ResizeForm Me!).
' Call it: Form_Load()
' [More info in "Important Points" - point 5 - in help file.]
'---------------------------------------------------------------------------------------
Public Sub getOrigWindow(frm As Access.Form)
On Error Resume Next
OrigWindow.Height = frm.WindowHeight
OrigWindow.Width = frm.WindowWidth
End Sub
'---------------------------------------------------------------------------------------
' Procedure : RestoreWindow
' DateTime : 27/01/2003
' Author : Jamie Czernik
' Purpose : Routine restores the original window dimensions call it when form closes.
' Call it: Form_Close()
' [More info in "Important Points" - point 5 - in help file.]
'---------------------------------------------------------------------------------------
Public Sub RestoreWindow()
On Error Resume Next
Access.DoCmd.MoveSize , , OrigWindow.Width, OrigWindow.Height
Access.DoCmd.Save
End Sub
از یکی از برنامه های دوستان برداشتم ولی یادم نیست .
تو خط 263 بجای عبارت
.FontSize = .FontSize * sngVertFactor
که فونت ها رو به هم میریزه، کد زیر را بنویسید:
.FontSize = .FontSize * IIf(sngVertFactor > sngHorzFactor, sngHorzFactor, sngVertFactor)
نتیجه بهتری میگیرید.
ضمنا وقتی میتونید تغییر رو مشاهده کنید که تو خط 31 و 34 رزولوشنی که برنامه توش طراحی انجام شده رو بنویسید (رزولوشن فعلی سیستم) و بعد برای تست برنامه، رزولوشن سیستم خودتون رو عوض کنید. خوب کار میکنه :)
گوزن ها
دوشنبه 21 اردیبهشت 1394, 11:15 صبح
[چطور میشه با تغییر اندازه فرم به همون میزان کنترل های فرم هم تغییر کنند؟
naderbahri
سه شنبه 28 فروردین 1397, 21:34 عصر
بهترین راه کار برای داشتن نرم افزار تحت اکسس که فرمها آبجکتها و فونتها و... متناسب با رزولیشن تغییر میکنن
https://goo.gl/6ucaKv
parsa70
یک شنبه 22 تیر 1399, 20:11 عصر
با تغییر رزولیشن ابعاد فرم و کنترلهای درون اون تغییر خواهد کرد .
سلام من تو برنامه ام استفاده کردم متاسفانه خیلی بزرگ نشون میده اصلا متناسب عوض نمیشه اندازه ها و باید scorll کرد.
راهه دیگه ای هم هست؟؟
alirezam3233@gmail.com
یک شنبه 10 بهمن 1400, 16:25 عصر
دوستان من مانیتورم مشکل سخت افزاری پیدا کرده کسی هست آشنا داشته باشه منو راهنمایی کنه ؟
mani74
دوشنبه 11 بهمن 1400, 12:04 عصر
شما می توانی با مراجعه به سایت https://monitor-service.ir/ مشکل خودتان را حل کنید.
mohammadsaleh
چهارشنبه 13 بهمن 1400, 10:26 صبح
سلام. به نظرم خودتون رو درگیر این کار نکنید که با توجه به رزولوشن ابعاد و ابجکتهای شما تغییر اندازه بدهند. تجربه ای که من دارم اینکه که عرض بزرگترین فرمم بیشتر از 20.5 سانتی متر و ارتفاعش (مجموع ارتفاع هدر و فوتر و دیتیل) بیشتر از 17 نشود.
mazoolagh
دوشنبه 18 بهمن 1400, 15:36 عصر
سلام. به نظرم خودتون رو درگیر این کار نکنید که با توجه به رزولوشن ابعاد و ابجکتهای شما تغییر اندازه بدهند. تجربه ای که من دارم اینکه که عرض بزرگترین فرمم بیشتر از 20.5 سانتی متر و ارتفاعش (مجموع ارتفاع هدر و فوتر و دیتیل) بیشتر از 17 نشود.
بهترین و مفیدترین پاسخ در کل تاپیک
dastgerdi
پنج شنبه 21 بهمن 1400, 11:18 صبح
با سلام و خداقوت
برای تغییر ابعاد آبجکت های مختلف در فرم های خودتون متناسب با رزولیشن و تغییر فرم ها از آیتم Anchoring استفاده کنید.
برای راهنمایی فیلم موجود در لینک زیر را مشاهده کنید.
تغییرات فرم ها در سایز ها و رزولیشن های متنوع در نرم افزار محبوب اکسس
(https://www.aparat.com/v/gb7mD/%D8%AA%D8%BA%DB%8C%DB%8C%D8%B1%D8%A7%D8%AA_%D9%81% D8%B1%D9%85_%D9%87%D8%A7_%D8%AF%D8%B1_%D8%B3%D8%A7 %DB%8C%D8%B2%D9%87%D8%A7_%D9%88_%D8%B1%D8%B2%D9%88 %D9%84%DB%8C%D8%B4%D9%86_%D9%87%D8%A7%DB%8C_%D9%85 %D8%AA%D9%86%D9%88%D8%B9_%D8%AF%D8%B1)
vBulletin® v4.2.5, Copyright ©2000-1404, Jelsoft Enterprises Ltd.