This commit is contained in:
2024-03-12 14:32:11 +01:00
4 changed files with 27 additions and 6 deletions

View File

@@ -71,6 +71,10 @@ Public Class usrCntlKundenuebersicht
Catch ex As Exception Catch ex As Exception
End Try End Try
Me.DoubleBuffered = True
SetStyle(ControlStyles.OptimizedDoubleBuffer Or ControlStyles.UserPaint Or ControlStyles.AllPaintingInWmPaint Or ControlStyles.ResizeRedraw, True)
UpdateStyles()
End Sub End Sub
@@ -83,6 +87,9 @@ Public Class usrCntlKundenuebersicht
End Try End Try
Me.DoubleBuffered = True
SetStyle(ControlStyles.OptimizedDoubleBuffer Or ControlStyles.UserPaint Or ControlStyles.AllPaintingInWmPaint Or ControlStyles.ResizeRedraw, True)
UpdateStyles()
End Sub End Sub
Private Sub initCboKd() Private Sub initCboKd()

View File

@@ -26,6 +26,10 @@ Public Class usrcntlKundeBearbeitenFull
' Dieser Aufruf ist für den Designer erforderlich. ' Dieser Aufruf ist für den Designer erforderlich.
InitializeComponent() InitializeComponent()
loadControls() loadControls()
Me.DoubleBuffered = True
SetStyle(ControlStyles.OptimizedDoubleBuffer Or ControlStyles.UserPaint Or ControlStyles.AllPaintingInWmPaint Or ControlStyles.ResizeRedraw, True)
UpdateStyles()
End Sub End Sub
Sub New(kdnr) Sub New(kdnr)
InitializeComponent() InitializeComponent()
@@ -34,6 +38,10 @@ Public Class usrcntlKundeBearbeitenFull
'If kdnr > 0 Then 'If kdnr > 0 Then
' init(kdnr) ' init(kdnr)
'End If 'End If
Me.DoubleBuffered = True
SetStyle(ControlStyles.OptimizedDoubleBuffer Or ControlStyles.UserPaint Or ControlStyles.AllPaintingInWmPaint Or ControlStyles.ResizeRedraw, True)
UpdateStyles()
End Sub End Sub

View File

@@ -31,14 +31,10 @@ Public Class frmMessenger
Me.DoubleBuffered = True Me.DoubleBuffered = True
SetStyle(ControlStyles.OptimizedDoubleBuffer Or ControlStyles.UserPaint Or ControlStyles.AllPaintingInWmPaint Or ControlStyles.ResizeRedraw, True) SetStyle(ControlStyles.OptimizedDoubleBuffer Or ControlStyles.UserPaint Or ControlStyles.AllPaintingInWmPaint Or ControlStyles.ResizeRedraw, True)
UpdateStyles() UpdateStyles()
VERAG_PROG_ALLGEMEIN.cProgramFunctions.SetDoubleBuffered(MyFlowLayoutPanel1)
End Sub End Sub
Public Sub SetDoubleBuffered([Control] As Control)
[Control].GetType().InvokeMember("DoubleBuffered", BindingFlags.SetProperty Or
BindingFlags.Instance Or BindingFlags.NonPublic, Nothing, [Control], New Object() {True})
End Sub
Sub initEMOJI_PATH() Sub initEMOJI_PATH()
@@ -90,7 +86,7 @@ BindingFlags.Instance Or BindingFlags.NonPublic, Nothing, [Control], New Object(
Private Sub frmMessenger_Load(sender As Object, e As EventArgs) Handles Me.Load Private Sub frmMessenger_Load(sender As Object, e As EventArgs) Handles Me.Load
initEMOJI_PATH() initEMOJI_PATH()
SetDoubleBuffered(MyFlowLayoutPanel1) VERAG_PROG_ALLGEMEIN.cProgramFunctions.SetDoubleBuffered(MyFlowLayoutPanel1)
rtbChatMessage.AllowDrop = True rtbChatMessage.AllowDrop = True
MSG_LISTENDER.START() MSG_LISTENDER.START()
TimerNEW_MESSAGE.Enabled = True TimerNEW_MESSAGE.Enabled = True
@@ -461,6 +457,8 @@ BindingFlags.Instance Or BindingFlags.NonPublic, Nothing, [Control], New Object(
Try Try
lblChatName.Text = "-" lblChatName.Text = "-"
' Dim scrollMax = (MyFlowLayoutPanel1.VerticalScroll.Value = MyFlowLayoutPanel1.VerticalScroll.Maximum) ' Dim scrollMax = (MyFlowLayoutPanel1.VerticalScroll.Value = MyFlowLayoutPanel1.VerticalScroll.Maximum)
MyFlowLayoutPanel1.SuspendLayout()
MyFlowLayoutPanel1.Visible = False
MyFlowLayoutPanel1.Controls.Clear() MyFlowLayoutPanel1.Controls.Clear()
If CHAT IsNot Nothing Then If CHAT IsNot Nothing Then
CHAT.READ_ALL_MESSAGES() CHAT.READ_ALL_MESSAGES()
@@ -472,8 +470,11 @@ BindingFlags.Instance Or BindingFlags.NonPublic, Nothing, [Control], New Object(
'MyFlowLayoutPanel1.AutoScrollPosition = New Point(MyFlowLayoutPanel1.Width, MyFlowLayoutPanel1.Height) 'MyFlowLayoutPanel1.AutoScrollPosition = New Point(MyFlowLayoutPanel1.Width, MyFlowLayoutPanel1.Height)
' If MyFlowLayoutPanel1.Controls.Count > 0 Then MyFlowLayoutPanel1.ScrollControlIntoView(MyFlowLayoutPanel1.Controls(MyFlowLayoutPanel1.Controls.Count - 1)) ' If MyFlowLayoutPanel1.Controls.Count > 0 Then MyFlowLayoutPanel1.ScrollControlIntoView(MyFlowLayoutPanel1.Controls(MyFlowLayoutPanel1.Controls.Count - 1))
MyFlowLayoutPanel1.ResumeLayout()
' If scrollMax Then ' If scrollMax Then
MyFlowLayoutPanel1.Visible = True
MyFlowLayoutPanel1.VerticalScroll.Value = MyFlowLayoutPanel1.VerticalScroll.Maximum MyFlowLayoutPanel1.VerticalScroll.Value = MyFlowLayoutPanel1.VerticalScroll.Maximum
MyFlowLayoutPanel1.Refresh()
If CHAT.chat_name <> "" Then 'GRUPPENCHAT If CHAT.chat_name <> "" Then 'GRUPPENCHAT
lblChatName.Text = CHAT.chat_name lblChatName.Text = CHAT.chat_name

View File

@@ -1,6 +1,7 @@
Imports System.Drawing Imports System.Drawing
Imports System.IO Imports System.IO
Imports System.Net.Mail Imports System.Net.Mail
Imports System.Reflection
Imports System.Text Imports System.Text
Imports System.Windows.Forms Imports System.Windows.Forms
Imports ClosedXML.Excel Imports ClosedXML.Excel
@@ -94,7 +95,11 @@ Public Class cProgramFunctions
End Function End Function
Public Shared Sub SetDoubleBuffered([Control] As Control)
[Control].GetType().InvokeMember("DoubleBuffered", BindingFlags.SetProperty Or
BindingFlags.Instance Or BindingFlags.NonPublic, Nothing, [Control], New Object() {True})
End Sub
Public Shared Function fktEuroKurs(varVonWährung As Object, Rechnungsdatum As Date) As Object 'Funktioniert nciht mit datum!!!!!!!!!!!!!!!!!!! Public Shared Function fktEuroKurs(varVonWährung As Object, Rechnungsdatum As Date) As Object 'Funktioniert nciht mit datum!!!!!!!!!!!!!!!!!!!
'(FixeTaxe, "ATS", RECHNUNG.Währungscode) '(FixeTaxe, "ATS", RECHNUNG.Währungscode)
'Dim varVonWährung As Object 'Dim varVonWährung As Object