I have a form that opens when user clicks a feature point.On the second tab a listbox populates with the related features to the main point.when the user changes the selection in the list box the form chages the recordthis works fine.I now want to popup a message box with a value in one of the textboxes on the form when the user changes the selection in the listbox.This also works fine....UNTILL I close the form...I click on another point and the form reopens...and then everytime I change the selection in the listbox the messagebox that pops up keeps giving me the last one selected before the form was closed the first time.Its drivign me nuts....this runs "OnSelChange" from the listboxI tried to set the vaiable to "" at the beginning and end of the sub...nothing changes.I tried to clear the listbox on "OnValdate" and "form close"I cant figure this out....Anyone have any thoughts or suggestions?
Dim objRS, objSelLayer, objEFPageOneControls4, objEditForm4, objEFPageOneControls2, objEditForm2
Set objSelLayer = Map.SelectionLayer
Set objRS = objSelLayer.Records
objRS.Bookmark = Map.SelectionBookmark
Set objEditForm4 = application.map.layers("Supports").forms("EDITFORM")
Set objEFPageOneControls4 = objEditForm4.Pages("page2").Controls
Dim varMUTCD_Code
varMUTCD_Code = ""
varMUTCD_Code = objEFPageOneControls4("mutcd_code").Value
msgbox "MUTCD CODE: " & varMUTCD_Code
varMUTCD_Code = ""