Pat,
I use a naming convention for all my objects. tbl, frm, qry, rpt, etc....
All I wanted to do was capture ALL the reports within the db in a combo box to pick from.
BTW...below is code I've been working on (tinkering with...I'm not the best with VB...self taught and a lot of help from you pro's out there....but if you guys could take a look at it and tell me if there is a better way...it would be greatly appreciated......
What I'm trying to accomplish is SAVE the FORM as a REPORT.
But the form must be closed in order to do so.
Me.txtFormName = Me.cboForms.Column(0)
Me.txtRenameForm = Me.cboForms.Column(0)
strOldFrmName = Me.cboForms.Column(0)
strOldFrmName = Me.txtFormName
strReportName = "rpt" & Mid(strOldFrmName, 4)
strNewFormName = Me.txtRenameForm
strFormName = "frm" & Mid(strNewFormName, 4)
DoCmd.Rename strReportName, acForm, strOldFrmName
DoCmd.SelectObject acForm, strReportName, True
SendKeys "%fa{home}+^{right 2}-{end}", True
DoCmd.Rename strNewFormName, acForm, strReportName
Mucked up as it is...I pick the form from a combo box...rename the form to a (and yes using the naming convention)"report name". Using the SEND KEYS, SAVE AS, then rename the form back to it's original name.
If there is a better way....I'd love to see it.
Thanks....