This repository has been archived by the owner on Sep 11, 2023. It is now read-only.
/
Form1.vb
56 lines (45 loc) · 1.97 KB
/
Form1.vb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
Imports Microsoft.VisualBasic
Imports System
Imports System.Collections.Generic
Imports System.ComponentModel
Imports System.Data
Imports System.Drawing
Imports System.Linq
Imports System.Text
Imports System.Windows.Forms
Imports DevExpress.XtraEditors
Namespace WindowsFormsApplication10
Partial Public Class Form1
Inherits Form
Public Sub New()
InitializeComponent()
End Sub
Private Sub Form1_Paint(ByVal sender As Object, ByVal e As PaintEventArgs) Handles MyBase.Paint
End Sub
Private Sub simpleButton1_Click(ByVal sender As Object, ByVal e As EventArgs)
For i As Int64 = 0 To Int64.MaxValue - 1
BackColor = Color.FromArgb(BackColor.R, BackColor.R, Convert.ToByte(i Mod 255))
Refresh()
Application.DoEvents()
Next i
End Sub
Private Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs) Handles MyBase.Load
popupContainerEdit1.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.Standard
AddHandler popupContainerEdit1.Properties.Popup, AddressOf Properties_Popup
AddHandler popupContainerEdit1.Properties.CloseUp, AddressOf Properties_CloseUp
End Sub
Private Sub Properties_CloseUp(ByVal sender As Object, ByVal e As DevExpress.XtraEditors.Controls.CloseUpEventArgs)
TryCast(sender, TextEdit).SelectionStart = 0
TryCast(sender, TextEdit).SelectionLength = (TryCast(sender, TextEdit)).Text.Length
End Sub
Private Sub Properties_Popup(ByVal sender As Object, ByVal e As EventArgs)
memoEdit1.SelectAll()
End Sub
Private Sub popupContainerEdit1_Properties_QueryPopUp(ByVal sender As Object, ByVal e As CancelEventArgs) Handles popupContainerEdit1.Properties.QueryPopUp
memoEdit1.Text = (TryCast(sender, TextEdit)).Text
End Sub
Private Sub popupContainerEdit1_Properties_QueryResultValue(ByVal sender As Object, ByVal e As DevExpress.XtraEditors.Controls.QueryResultValueEventArgs) Handles popupContainerEdit1.Properties.QueryResultValue
e.Value = memoEdit1.Text
End Sub
End Class
End Namespace