Re: Open External Database Form



lyle wrote:
On Oct 15, 7:02 am, Ian <ian.sex...@xxxxxxxxxxxx> wrote:
lyle fairfield wrote:
Ian <ian.sex...@xxxxxxxxxxxx> wrote in
news:3IvQi.11785$0z6.2664@xxxxxxxxxxxxxxxxxxxx:
Basically I cant my Dymo 400 label printer to remember my label size
on a report, each time I close the report it forgets the size. If I
keep the database as an MDB it remembers the size, when I convert to
an MDE it forgets it. After much research it seems there is no
realistic way to get Access 97 and 2000 to remember page sizes using
an MDE
I tried to post this in Google but I think the post failed. I apologize
if this appears twice.
1. You could have the mdb application open the report automatically via
an autoexec macro or | You could follow a hyperlink to the report in the
mdb application (see help-follow hyperlink). Assuming the report needs
information you could set the value of the text box to a public function
which reads the value from wherever, perhaps a text file written by your
mde application or by command line parameters included in your call to
open the mdb file.
2. You could scrap the label wizard and design your own label report
using the default paper size in you printer. (I think the label wizard
sucks big time).
3. You could design a MS-Word label document that used your JET tables to
fill its fields.
4. You could set a reference to your mdb file from your mde and open the
report (or form that opens the report) from a standard module in the
referenced mdb.
5. You could look up the programming language for your printer and write
your own documents with printer codes and send it off to the printer.
6. If you're using Access 2003 you could put the report into an adp, open
an ADODB recordset and set the report's recordset to that.
7. If you're using Access 2003 you could put the report into an adp, and
completely program the report to show what you want dynamically.
Yes, I've done all of these except #4 at one time or another, but the
solutions are peculiar to each individual situation.
Of course, you could do what I would do: forget the MDE thing and just
deliver an MDB. Yes, I know people might mess with my code, even borrow
it and call it their own. So what? I'll write something better tomorrow,
or maybe tonight, if I can't sleep.
Lyle

Thanks for all your help, I cant imagine a more comprehensive answer.

I shall have to give it some more thought, wouldn't it be nice if MS
would just let the MDE remember the page sizes?

I think #6 and #7 are out because I know the users have to use Access 97
and Access 2000.

#1 sounds good, I have used text files to read data back into other DB's
in the past, all sorts of problems when 2 users make the same file at
the same time etc.

#2 will be problematic if the user changes his printer and moves away
from Dymo.

#3 I considered using word templates and filling in the fields using
word bookmarks, this has worked in the past for different purposes, I
guess a new word template would have to be created if the user changed
the printer.

I think I shall have a go at #4 which ironically is the one you say you
have never used. As the forms/report would be stored in the backend, I
suppose I could just make a temporary table from the front end to store
the ID that I need for the report, then read it in from the temp table,
it might work. I wanted it to use a separate DB for the report, each PC
would have this DB in the same folder as the front end, this would allow
each PC to use a different make of printer without a problem, if I put
it on the back end there can only be one make of printer.

Thanks again for all your help.

I have done #4 but not by opening the report with a command in a
standard module in the referenced mdb, which I believe is the usual
practice. I have tried to expose the report, that is to make it behave
just like a report in the currentdb.

To do so in the referenced mdb I have made sure the report had a code
module, even if the code did nothing, saved the report as text with
Application.SaveAsText (before referencing the mdb).
Then I have changed the line
Attribute VB_Exposed = False
to
Attribute VB_Exposed = True
in the text file.
Then I have reloaded an image of the report with
Application.LoadFromText but using a different name for the report so
as not to munget the original.

In Access 97 this used to make the report (the new one with the
modified name) just like a report in the current db, and fully usable.
Does it still do that in later versions? I'm not sure. Perhaps it's
worth a shot.

(The Attribute Lines seem to vary from VB version to VB version; I am
using Access 2002 right now.)

With an exposed object, I have found that it's worthwhile to check
where its data is coming from: the currentdb or the codedb.


Lyle

I have used the Application.SaveAsText, my text file does not contain the words Attribute, Exposed or False using Access 97?
.



Relevant Pages

  • Re: Cant update a Report fiels
    ... The logic works in the *.mde version, but not in the *.mdb version. ... I'm able to return the filter string back to the ... >> announce to the report readers that the report is filtered. ...
    (microsoft.public.access.formscoding)
  • Re: Can one open a report in another mdb? (by RLi)
    ... Check out the TransferDatabase method or action. ... you name the report in the source location (the mdb) ... and the target location (your mde). ...
    (microsoft.public.access.formscoding)
  • Re: Design not working for reports
    ... Nowhere is this post does it say I'm trying to edit the report in the mde. ... its an mdb test file. ...
    (comp.databases.ms-access)
  • Re: Page setup being changed
    ... I installed the mdb source plus the backend database ... but the report continues to preview as ... > And, as such, have the page setup properties ...
    (microsoft.public.access.reports)
  • Re: Open External Database Form
    ... on a report, each time I close the report it forgets the size. ... an MDE it forgets it. ... You could have the mdb application open the report automatically via an autoexec macro or | You could follow a hyperlink to the report in the mdb application. ... You could set a reference to your mdb file from your mde and open the report (or form that opens the report) from a standard module in the referenced mdb. ...
    (comp.databases.ms-access)