How do I click a button to pull up a single file within a form

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I'd like to create a form so I can access a single file from another form by
typing in the file number
 
Not quite sure what you mean by accessing a file from another form. Are you
talking about a physical file that's outside of your database, or do you
mean a data row that's displayed on the other form (which means that it's in
a table in your database)?

If the former, you can invoke the standard Windows File Open dialog using
the code from http://www.mvps.org/access/api/api0001.htm at "The Access
Web".

If the latter, you'll need to give a better explanation of what you're
trying to do.
 
I have created forms for entering client info, employee info and work order
info. In the work oder info there will be many files.

I'd like to create a page where the user can type in a file number from the
work order and print that file only omitting 2 fields

Is that as clear as mud??

and can I export that file to Microsoft word?

Thanks
 
Yeah, clear as mud <g>.

What are these files: plain text, or something else?

I'm not sure how feasible it's going to be to "print that file only omitting
2 fields" from within Access.

As to exporting the file to Word, you'll probably be best off writing a
module that Automates Word, and import it into Word through that module.
 
I'll start from the beginning.

I've created 3 forms. One for entering employee data, one for entering
client data and one for entering order information. All 3 are databases in
Access.

The user will enter the oder information for the employee's job. Once the
order is inputed, the user needs to be able to look up the order and send
this order (would not like to have the client information shown to the
employee) to the employee.

I've created the order form with tabs. Will that make things more
difficult? or can I print certain tabs?

Thanks
 
Forms aren't intended for printing: that's what Reports are for.

I'm not sure what you mean by "send this order". Are you talking about an
e-mail? Is there any reason why the employee can't look in the Access
database and see the details that are intended for him/her?
 
The employees don't have access to the database. Employees are scattered
throughout Ontario and are sent the jobs they need. Can I create a report
from a single "order" instead of printing them all. I need to be able to
send a single file to the employee
 
I can access a single file from another form

Use of the term file in above is VERY confusing. The term "file" usually
means a file on your hard disk. You can see that the responder what thrown
complete off track by the user of the above term...

I suspect, and have to "guess" that you really meat you need to retrieve ONE
record, or perhaps a group of records that represents one customer, or one
of
something.
I have created forms for entering client info, employee info and work order
info. In the work oder info there will be many files.
I'd like to create a page where the user can type in a file number

Gee, now, we gone from the miss use of the term "file", and now are
interchanging the term "page" with that of a "form". The term page generally
has
a particular meaning in ms-access. IN fact, if you look closely at a form,
there is a "page" control, and this control is not to be confused with a
tab control. Again, you *really* make things difficult by half way through
your post do a "switchero" on the terms you use. This again really makes
things confusing.. By page, did you perhaps mean a form? (or, are you
*really* using the page control? -- or, perhaps data access pages (again,
data access pages have a particular meaning). For all purposes, I going to
have
to guess that you did not mean "page", but actually meant to use the timer
form.
I've created 3 forms. One for entering employee data, one for entering
client data and one for entering order information. All 3 are databases in
Access.

Gee, now we are talking about forms, but you also now are talking bout 3
databases? Are we really dealing with 3 databases now? When did this MAJOR
detail finally come to light? Or, perhaps by databases, you actually meant
that you have 3 tables? again, this is just so confusing and again you seem
to be switching terms halfway through a paragraph, and then again causing
more
confusing. Did you *really* mean 3 different databases? Are you trying to
tie
3 different databases together...or did you actually mean just 3 tables
(again, a grand canyon difference here).
Is that as clear as mud??

Actually, you done a very amazing job here confuse. You can't see anything
though mud, and your miss-use of terms is making this post VERY difficult to
follow.

Further, when did your name change from Rachelle to Eddie? (again is
another attempt to create even MORE confusing and make this thread
even harder to follow? Am I dealing with two differnt people here, and
this question is now split between two people who are on differnt
trains of throught????)>

Yes...this is clear a mud...you can't see though mud!!!

I going to have to make a "guess" that by 3 databases, you meant 3 tables
I going to have to make a "guess" that by "page", you actually meant forms
I going to have to make a "guess" that by the term "file", you did not mean
a windows computer file, but a general term, such as "customer file". Again,
in this case, I going to have to make a guess that by file, you actually
meant a record....

So,

1st Problem:

I need to be able to enter a customer number, and bring up the customer
record. (as mentioned, in non computer terms, we can call this a customer
file..but to do so in the context of computer question is VERY confusing,
since then how can I know you are talking about a computer file, or
customer file? We get a TON of questions here about how to open a word
file, or pdf file, or any type computer file here from ms-access. I don't
think you are talking about a computer file here, but if you are, then you
will have to correct me, and I likely just wasted yours and my time by
assuming you mean customer file).

For the above, you have several choices. A reasonable approach is to use
the
combo box wizard. Simply place the combo box in the forms header. When the
wizard launches, choose the 3rd option called:

Find a record based on the value I selected in my combo box

The above will thus build you a combo box that you can either

a) enter in the customer number, and the form will move to that record
b) simply choose a value from the combo box, and the form will move to
that record

So, you can either type in he number into the combo box, or "drop down" the
combo box with your mouse, and choose a existing number

So, the above should answer your first question.

2nd Problem:
user can type in a file number from the
work order and print that file

As mentioned, I don't think you trying to print a word file, or excel file
here. So, the solution is to build a nice report. Do NOT try and use a form
to print the record, use a report.

The code behind the button to print the ONE record to a report is

Me.Refresh ' force data to be written to disk, so report can see data

docmd.OpenReport "MyReprotName",acViewPreview,,"id = " & me!id

The above does assume your table has a primary key of id (this is the
default for autonumber field name). You could perhaps also consider using
the customer number you use, but using the built-in "id" field is preferred
if you have such.
and can I export that file to Microsoft word?

Again, I suspect you mean the report that is being display. You can send it
to word, but much of reports formatting will be lost. You can also send it
to a pdf file, or consider perhaps building word template? If it is boiler
plate type letter that you just need to fill in some fields, then using my
word merge library here is what you really need:

http://www.members.shaw.ca/AlbertKallal/msaccess/msaccess.html

So, do take to heart that there is a LOT of new terms, and a LOT of new
things when you learning ms-access. I can attest that this stuff can be very
confusing, and it will take awhile. We all been there. Hence, my comments
about how you confused us is not a big deal, but just something I wanted you
to realize that this stuff takes time to learn, and what seems perfectly
clear to you will not be to someone reading this stuff....

Good luck!!
 
Thank you very much. Sorry for the confusion. I've been fighting with the
terms used here and the terms my husband uses for his work (this is what I'm
doing it for).

I was on his computer earlier hence "Eddie"

I'll try this tomorrow and hopefully it'll work...rather I can get it to work

Thanks again
 
Thank you very much. Sorry for the confusion. I've been fighting with
the
terms used here and the terms my husband uses for his work (this is what
I'm
doing it for).

I was on his computer earlier hence "Eddie"

Fair enough. And, no problem!!

Like I said, I might have come across a bit harsh, and I do apologize for
this.

However:
Is that as clear as mud??

I can certainly see you being frustrated (and, rightfully so..this stuff can
be hard). However, it was *very* important for me to point out that people
here are giving their free time, and we are MOST happy to help you. The
above comment gave me the idea that you thought we are not listening to you,
or are ignoring your, or not wanting to help.

Nothing could be further from the truth. I suspect that you *honestly*
thought that what you were saying was perfectly clear, and thus where
becoming frustrated with people here.

I just wanted to point out that your post was somewhat confusing. So, don't
be taken sideways because some poster (like me!!) was unable to understand a
few things!!

Keep pressing on..and I can assure you we will eventually work towards a
solution!!

So, I just wanted to re-assure you that everything is ok here!!
 
I was sincere when I said thank you. I am grateful for the help. I know how
to create basic forms but I'm trying to learn more so I can create a database
for a Private Investigation company and they expect a little more than I can
give them at the moment so I'm reading as much as I can. I'm not sure I can
give them what they want because some of the stuff will have to be done in
VBA and I don't know the language.

Anyway, thanks again

Rachelle
 
Back
Top