The easiest way is to change the defaultView property in the property sheet.
From code you can use DoCmd.RunCommand acCmdSubformDatasheetView *after* you
setfocus to the subform control. Here's some sample code that goes in a
button click event for a button on the main form:
Private Sub Command16_Click()
Static fdatasheet As Boolean
Me.order_subform.SetFocus
If fdatasheet Then
DoCmd.RunCommand acCmdSubformDatasheetView
Else
DoCmd.RunCommand acCmdSubformFormView
End If
fdatasheet = Not fdatasheet
End Sub