View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Bob Bob is offline
external usenet poster
 
Posts: 972
Default Excel macro ~ open form ~ new record

Inventory spreadsheet, bulk raw material in, record date when used, but it's
got to be goof proof, so existing records don't get overwritten.

I have tried:
Sub Macro1()
ActiveSheet.ShowDataForm
End Sub
but this doesn't jump to new record

Sub EnterNewRecord()
DoCmd.OpenForm "RollForm", acNormal
DoCmd.GoToRecord acNewRec
End Sub
I created "RollForm" by: Insert-Name-Define, range a2:I2
But this creates "run-time error 424", Object required.

So, is DoCmd for Access only? Has named form been created incorrectly or
saved wrong?
Any solutions to associating an "Enter button" with macro to open data form
to new record?