Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Private Sub imgSplitter_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
With imgSplitter
picSplitter.Move .Left, .Top, .Width \ 2, .Height - 20
End With
picSplitter.Visible = True
mbMoving = True
End Sub
Private Sub imgSplitter_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Dim sglPos As Single
If mbMoving Then
sglPos = X + imgSplitter.Left
If sglPos < sglSplitLimit Then
picSplitter.Left = sglSplitLimit
ElseIf sglPos > Me.Width - sglSplitLimit Then
picSplitter.Left = Me.Width - sglSplitLimit
Else
picSplitter.Left = sglPos
End If
End If
End Sub
Private Sub imgSplitter_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
SizeControls picSplitter.Left
picSplitter.Visible = False
mbMoving = False
End Sub
Private Sub Form_Resize()
On Error Resume Next
If Me.Width < 3000 Then Me.Width = 3000
SizeControls imgSplitter.Left
End Sub
Sub SizeControls(X As Single)
On Error Resume Next
'set the width
If X < 1500 Then X = 1500
If X > (Me.Width - 1500) Then X = Me.Width - 1500
tvTreeView.Width = X
imgSplitter.Left = X
lvListView.Left = X + 40
lvListView.Width = Me.Width - (tvTreeView.Width + 140)
lblTitle(0).Width = tvTreeView.Width
lblTitle(1).Left = lvListView.Left + 20
lblTitle(1).Width = lvListView.Width - 40
'set the top
If tbToolBar.Visible Then
tvTreeView.Top = tbToolBar.Height + picTitles.Height
Else
tvTreeView.Top = picTitles.Height
End If
lvListView.Top = tvTreeView.Top
'set the height
If sbStatusBar.Visible Then
tvTreeView.Height = Me.ScaleHeight - (picTitles.Top + picTitles.Height + sbStatusBar.Height)
Else
tvTreeView.Height = Me.ScaleHeight - (picTitles.Top + picTitles.Height)
End If
lvListView.Height = tvTreeView.Height
imgSplitter.Top = tvTreeView.Top
imgSplitter.Height = tvTreeView.Height
End Sub
Private Sub Form_Load()
Dim i As Integer
'set the child controls for the horizontal splitter
[b]Set HSplitter.LeftOrTopCtl = VSplitter
Set HSplitter.RightOrBottomCtl = lstDebug[/b]
'set the child controls for the vertical splitter
[b]Set VSplitter.LeftOrTopCtl = List1
Set VSplitter.RightOrBottomCtl = Text1[/b]
'add some items to the list on the left panel
For i = 0 To 100
List1.AddItem "The index of this item is " & i
Next
List1.ListIndex = 0
End Sub
Private Sub Form_Load()
Dim i As Integer
Set Splitter1.LeftOrTopCtl = Picture1
Set Splitter1.RightOrBottomCtl = Picture2
End Sub
Private Sub Form_Resize()
Dim lSplitHeight As Long
Dim lSplitWidth As Long
If Me.WindowState = vbMinimized Then Exit Sub
'set the position/size of the splitter
lSplitHeight = Me.ScaleHeight
lSplitWidth = Me.ScaleWidth
Splitter1.Height = IIf(lSplitHeight < 0, 0, lSplitHeight)
Splitter1.Width = IIf(lSplitWidth < 0, 0, lSplitWidth)
End Sub