I have this code on frmA
With frmB
.PreviousLotExists = Not AtStart
.NextLotExists = Not AtEnd
.ShowDialog()
End With
When frmB loads I click the cross to close the form and on that form I have a check to say are you sure (if user has typed into frmB) - this code runs twice.
When I click the cross on frmB how do I get the code to just fire once so that the event cancels - it runs the frmB_closing event twice even when I set Cancel = true