Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Modal form error in MDE compiled version

Status
Not open for further replies.

martync

Programmer
Mar 4, 2002
7
AU
Can anyone help???
When I attempt to run a date form with the database in MDB format this works fine but when I try to run this in a MDE format file I get the the error:
The expression OnClick you entered as the event property setting produced the following error: That command isn't available in an MDE database.

*****Opening code
sub getADate
DoCmd.OpenForm "fmGDatePicker", acNormal, , , acFormEdit, acDialog, varItems
Forms!fmGTextStore!txt4 = Format(GV_dtRV, "Long Date")
end sub

*****below used to close the form
Private Sub btnCloseForm_Click()
GV_dtRV = Me.calDate.Value
DoCmd.Close acForm, "fmGDatePicker"
End Sub

Thanks
Martyn
 
Martyn,
It looks like this form is for passing the date to something else. My guess is that Access thinks you want to be able to edit the fmGDatePicker form in some way (which you can do as an MDB but not as an MDE). You may want to try removing acFormEdit and configuring the form with the AllowEdits, AllowDeletions, AllowAdditions, and DataEntry properties. Also, try setting this form to MODAL. Hope this helps.
 
Martyn,
Sorry about the last line. I just re-read your subject line and went 'Doh!' Either way, there has to be a setting within the form itself that is set to allow editing of the form, which is why the MDE is balking.
 
Thanks, your email flagged the problem - it was actually my trying to edit a report I open based on the user returned information. Trying to edit a report is a no,no in an MDE.
Once again thanks for your help, I have taken on your suggestions regarding the form settings.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top