did not work ! I turned both form and layout view to No and datasheet to yes. Still does not workJust turn off Allow Form View? It's what I do when a form doesn't open as specified by the default property setting. I've always just assumed it had something to do with having saved a form while it was in some other view, thus 'remembering' that view from then on. Oddly enough, I didn't try saving it in the desired view, I just set the one I didn't want to No.
When you say in another form in Design mode, what do you mean?you must open it from another form in design mode.
such code may have been written.
Code:Private Sub Form_Open(Cancel As Integer) Me.Form.DefaultView = 2 End Sub
Then I suspect you have Load or Open event code on that form, or code that opens the form which overrides the property settings. Perhaps you should post those events or a zipped copy of the database.did not work ! I turned both form and layout view to No and datasheet to yes. Still does not work
I am using a split form and the FE file is enclosed. I am not at liberty to share the BE file. I hope this will help in analysing the problemThen I suspect you have Load or Open event code on that form, or code that opens the form which overrides the property settings. Perhaps you should post those events or a zipped copy of the database.
Private Sub cmdSingleForm_Click()
DoCmd.OpenForm "Form2", acDesign, , , , acHidden
Forms!Form2.DefaultView = 0
DoCmd.Close acForm, "Form2", acSaveYes
DoCmd.OpenForm "Form2"
End Sub
Private Sub cmdContinuousForm_Click()
DoCmd.OpenForm "Form2", acDesign, , , , acHidden
Forms!Form2.DefaultView = 1
DoCmd.Close acForm, "Form2", acSaveYes
DoCmd.OpenForm "Form2"
End Sub
Private Sub cmdDataSheetForm_Click()
DoCmd.OpenForm "Form2", acDesign, , , , acHidden
Forms!Form2.DefaultView = 2
DoCmd.Close acForm, "Form2", acSaveYes
'Pay Attention Here!
DoCmd.OpenForm "Form2", acFormDS
End Sub