View Full Version : Problem due to no design view support of mde DBs


fugifox
02-16-2009, 07:02 AM
I have a DB in .mde where I want to anagrammatically open some Reports in Design view
to change the ControlSource property of some Controls in the Report.
The problem is that opening in Design View is not supported for .mde databases,
so I am looking for suggestions on how to change the ControlSource property
without having to open the Report in Design view.

RuralGuy
02-16-2009, 07:09 AM
You will probably need to create different reports for each condition. Either that or create the query with the data you need in the fields you need them in.

fugifox
02-16-2009, 07:48 AM
You will probably need to create different reports for each condition. Either that or create the query with the data you need in the fields you need them in.

That is exactly what I wished to avoid!
Basically, I have a few Reports with some Controls each.
I want user to be able to set criteria for each of the Controls.
If I implement this with different queries I'll need one query/report
for every combination of the criteria!
That's why I'm stack with this way which unfortunately doesn't work on mde.
Any other suggestions?

RuralGuy
02-16-2009, 07:53 AM
Only the suggestions I've already posted. Sorry.

gemma-the-husky
02-16-2009, 09:41 AM
can you not change the reports record source with code even in a mde. Offhand I believe I do this,

in a report

me.recordsource = "whatever"

Rabbie
02-16-2009, 10:47 AM
Can you actually change VBA in an mde. Isn't it already pre-compiled?

boblarson
02-16-2009, 11:10 AM
You can change the recordsource, but you may not be able to change a control's CONTROL SOURCE, which may be their problem.

pbaldy
02-16-2009, 11:14 AM
You can change a report control's control source in the report's open event. I do it all the time for dynamic crosstab reports.

fugifox
02-16-2009, 10:38 PM
You can change a report control's control source in the report's open event. I do it all the time for dynamic crosstab reports.

Thank you pbaldy!
you save me from many hours of work!

gemma-the-husky
02-17-2009, 01:13 AM
thinking about it again - of course you can do it in vba, (although you cant open the design directly in an mde)

if you have code that does it in vba, it will still compile into an mde.

-------
there are probably some things you cant do in code, where you HAVE to edit the design, but I suspect you can change permanently a lot of things in an mde through code, that you owuld normally do in design mode

Rabbie
02-17-2009, 01:17 AM
thinking about it again - of course you can do it in vba, (although you cant open the design directly in an mde)

if you have code that does it in vba, it will still compile into an mde.
Reading the original post it is not clear that the original poster actually has the .mdb so unless he has this I fail to see how he can modify the VBA directly in the .mde. Perhaps I am missing something.

If he has the .mdb then there is no problem in amending the design and compiling a new .mde but if he hasn't how does he amend the VBA:confused:

pbaldy
02-17-2009, 06:25 AM
Thank you pbaldy!
you save me from many hours of work!

No problem; glad it helped.