Fix Scaling Factor calculation

This commit is contained in:
Jonathan Jenne 2021-04-21 14:35:33 +02:00
parent efc5ca8962
commit 114e459577

View File

@ -1540,6 +1540,7 @@ Public Class frmIndex
ShowErrorMessage(ex, "Form Open")
End Try
End Sub
Sub Load_String()
Try
Me.VWDDINDEX_MANTableAdapter.Connection.ConnectionString = MyConnectionString
@ -1718,11 +1719,15 @@ Public Class frmIndex
Private Sub LoadIndexe_Man()
Try
Dim oDpiscale = DigitalData.Modules.Windows.Screen.GetScalingFactor()
Dim oScreen As New DigitalData.Modules.Windows.Screen()
Dim oDpiscale = oScreen.GetScreenScaling(Me)
Dim oControlCount As Integer = 1
Dim oLabelPosition As Integer = 11 * oDpiscale
Dim oControlPosition As Integer = 33 * oDpiscale
_Logger.Info("Loading Indicies for Screen Scaling Factor [{0}]", oDpiscale)
Dim oControls As New ControlCreator(LOGCONFIG, pnlIndex, Me) With {
.OnControlChanged = AddressOf PrepareDependingControl,
.OnLookupData = AddressOf GetLookupData