Copy Multiple Lines of Text from our Query (1 Viewer)

access2010

Registered User.
Local time
Yesterday, 16:17
Joined
Dec 26, 2009
Messages
522
Can I please have a suggestion on how we can copy Multiple Lines of Text which are in our Query to the clipboard and then print the grouping?

Group all of the same records in the query by = Symbol Code =
Copy the grouped records = lines of text = to the clipboard

Your suggestions will be appreciated.

Nicole
 

Attachments

June7

AWF VIP
Local time
Yesterday, 15:17
Joined
Mar 9, 2014
Messages
3,135
Print a filtered report.

Records of table or query or form can be selected and copied to clipboard but then they have to be pasted somewhere, such as in an Excel spreadsheet or an email. I don't know any way to print directly from clipboard.
 

arnelgp

error reading drive A:
Local time
Today, 07:17
Joined
May 7, 2009
Messages
9,629
the report I made is for all Symbol_Stock (grouped).
if you need to print a specific Symbol_Stock, ie. CSCO, you can print a filtered report.
Code:
Docmd.OpenReport ReportName:="rptInvestments_Purchases_Sales_Q",View:=acViewPreview, WhereCondition:="[Symbol_Stock]=" & Chr(34) & "CSCO" & Chr(34)
 

access2010

Registered User.
Local time
Yesterday, 16:17
Joined
Dec 26, 2009
Messages
522
arnelgp
Thank you for your assistance and we are at 99% complete.
How can we programmatically print your report for the = Symbol_Stock = which is currently on the page?
Each time the form opens up there will be a different = Symbol_Stock =

Thank you Crystal
 

access2010

Registered User.
Local time
Yesterday, 16:17
Joined
Dec 26, 2009
Messages
522
June7
Thank you for your note.
There are no programmers in our volunteer office and the best Idea we had was to use the Query on our form to group the records that we wanted to print by their = Symbol Code = and then manually copy the data from the = grouped Symbol Code query = to a Word document and then print the records.

Crystal
 

arnelgp

error reading drive A:
Local time
Today, 07:17
Joined
May 7, 2009
Messages
9,629
create a button on the form.
on its Click event add this code:
Code:
Private sub buttonName_Click()
Docmd.OpenReport ReportName:="rptInvestments_Purchases_Sales_Q",View:=acViewPreview, WhereCondition:="symbol_stock=" chr(34) & me![symbol_stock] & chr(34)
End Sub
 

access2010

Registered User.
Local time
Yesterday, 16:17
Joined
Dec 26, 2009
Messages
522
arnelgp
Thank you for your suggestion which I have tried as noted below, without success.
Error messages
Compile Error and Syntax Error
=

Private Sub arnelgp_Click()
' your code was = Private Sub buttonName_Click()
'Button name = arnelgp
Docmd.OpenReport ReportName:="rptInvestments_Purchases_Sales_Q",View:=acViewPreview, WhereCondition:="symbol_stock=" chr(34) & me![symbol_stock] & chr(34)
' report name = rptInvestments_Purchases_Sales_Q
End Sub
=
Can you please advise me as to what I have done wrong?
Thank you.
Nicole
 

Gasman

Enthusiastic Amateur
Local time
Today, 00:17
Joined
Sep 21, 2011
Messages
6,037
Code:
 WhereCondition:="symbol_stock=" [COLOR="Red"]&[/COLOR] chr(34) & me![symbol_stock] & chr(34)
 

access2010

Registered User.
Local time
Yesterday, 16:17
Joined
Dec 26, 2009
Messages
522
Gasman
Thank you for your suggestion, but we are still receiving A Compile Error and A Syntax Error.
Could you please give us an other suggestion?
I have renamed the uploaded data base to = Investments_Purchases_Sales_R.mdb
Thank you,
Crystal
 

Attachments

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Top Bottom