cancel
Showing results for 
Search instead for 
Did you mean: 

Grid cleaned when mode changes

Former Member
0 Kudos

Hi!

When my form mode changes the grid is cleared..How can i prevent this?

Accepted Solutions (1)

Accepted Solutions (1)

former_member687054
Participant
0 Kudos

Hi Toni,

I had almost the same problem. In my case I had the problem when I switch between Find mode and add mode.

I worked around by setting the bubbleevent to false in menuevent for this two mode change. And I also set manually the form mode.

Ex:

Private Sub oApplication_MenuEvent(...

If pVal.BeforeAction = True Then

If pVal.MenuUID = "1281" Or pVal.MenuUID = "1282" Then

If pVal.MenuUID = "1281" Then

oIEForm.Mode = BoFormMode.fm_FIND_MODE

End If 'If pVal.MenuUID = "1281" Then

If pVal.MenuUID = "1282" Then

oIEForm.Mode = BoFormMode.fm_ADD_MODE

End If 'If pVal.MenuUID = "1282" Then

End If 'If pVal.MenuUID = "1281" Or...

End If 'If pVal.BeforeAction = True Then

End Sub

I hope this will help you

Former Member
0 Kudos

Hey Joderick,

Just a word of warning when doing this. If you have not programmed your application to only allow the active form to receive the menu events you may block the add and find menu clicks for other Business One forms. If your custom form is running it may block the menu event from bubbling to the other forms.

Answers (0)