RE: Printing selected Record
- From: Amanda <Amanda@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 24 Jun 2008 13:49:01 -0700
Thank you very much for the help. I will try this too. Thank you!
"Richard" wrote:
I just tried that link, you may have to paste it directly into the address.
bar sorry I didn't test that.
"Richard" wrote:
Hi Amanda,
Heres one I have used for a while now.
http://allenbrowne.com/casu-15.html it wont ask which record you like to
print but it will print the record(s) you looking at, plus check to see if
is saved.
Richard
"Amanda" wrote:
Thank you I will try this. Have a great weekend!
"Klatuu" wrote:
Okay.
Dim txtRecordNbr As txt
txtRecordNbr = InputBox("Enter Record # To Print")
If txtRecordNbr <> vbNullString Then
Docmd.OpenReport "CustomerReport", , , "[Record #] = " &
Clng(txtRecordNbr)
End If
--
Dave Hargis, Microsoft Access MVP
"Amanda" wrote:
We use record # for the primary key field. Sorry
"Klatuu" wrote:
What do you mean by record number? There are no record numbers in Access.
If you mean the number you see in the box between the navigation buttons on
a form, those numbers just represent the ordinal position of the record
within the form's current recordset. They cannot be depended on. Any time
you filter a form, add a record, delete a record, or change the form's order,
the number will change. Normally, you would want to use some unique field in
the form's recordset to indentify a record. Then you can use the Where
argument of the OpenReport method to filter the report to that one record.
For example, say you have a customer form and the customer table has a
CustomerID primary key field, it would be:
Docmd.OpenReport "CustomerReport", , , "[CustomerID] = " &
Me.txtCustomerID
--
Dave Hargis, Microsoft Access MVP
"Amanda" wrote:
I'm new to access. I would like to put a command button to print a selected
record buy it asking me what record # do you want to print. I can't seem to
get this to work. Thank you in advance.
- References:
- Printing selected Record
- From: Amanda
- RE: Printing selected Record
- From: Klatuu
- RE: Printing selected Record
- From: Amanda
- RE: Printing selected Record
- From: Richard
- RE: Printing selected Record
- From: Richard
- Printing selected Record
- Prev by Date: Re: Still Struggling...
- Next by Date: what is wrong with this update query?
- Previous by thread: RE: Printing selected Record
- Next by thread: RE: 6 cases from a textbox control that needs to be validated.
- Index(es):