Good day all!
Ugh.. I'm going insane trying to figure this out.
All I need to do is open a second form where the user right clicks in a base form.
By base form looks like this (Warning: Still in development):
The second form really is nothing more than a button at this point, but this is what happens when I right click on the treeview:
Argh! This darn thing will not open in the correct area! What am I doing wrong?
This is the code I'm using to open the second form (New Record button) from the treeview in the base form:
Here is the code to position the second form:
Could someone offer some help? I'm about to snap! lol
Thanks in advance!
________________________________________
Buddha. Dharma. Sangha.
Ugh.. I'm going insane trying to figure this out.
All I need to do is open a second form where the user right clicks in a base form.
By base form looks like this (Warning: Still in development):

The second form really is nothing more than a button at this point, but this is what happens when I right click on the treeview:

Argh! This darn thing will not open in the correct area! What am I doing wrong?
This is the code I'm using to open the second form (New Record button) from the treeview in the base form:
Code:
Private Sub TreeView1_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal x As Long, ByVal y As Long)
If Button = vbKeyRButton Then
DoCmd.OpenForm "rightMenu", acNormal, , , , , x & "|" & y
End If
End Sub
Here is the code to position the second form:
Code:
Private Sub Form_Open(Cancel As Integer)
Dim intPos As Integer 'Position of the Pipe
Dim screenXPosition As Long
Dim screenYPosition As Long
intPos = InStr(Me.OpenArgs, "|")
If intPos > 0 Then
screenXPosition = Left$(Me.OpenArgs, intPos - 1)
screenYPosition = Mid$(Me.OpenArgs, intPos + 1)
End If
Me.Move screenXPosition, screenYPosition
End Sub
Could someone offer some help? I'm about to snap! lol
Thanks in advance!
________________________________________
