Hello all: Using VBA to format a report in Access97. Putting the results of the formatting into 2 variables named str1 and str2 . How are these variables then printed on the report. I have tried textboxes and named the control source(s) =str1 and =str2. When I run the report, inputboxes ask for str1 and str2. How can I get by this dilemma? TIA.
![]() |
Patch reliability is unclear, but widespread attacks make patching prudent. Go ahead and patch, but watch out for potential problems. |
SIGN IN | Not a member? | REGISTER | PLUS MEMBERSHIP |
-
Printing
Home » Forums » AskWoody support » Productivity software by function » MS Access and database help » Printing
- This topic has 4 replies, 4 voices, and was last updated 24 years, 2 months ago.
AuthorTopicWSBCKessinger
AskWoody LoungerMarch 7, 2001 at 6:35 pm #353630Viewing 3 reply threadsAuthorReplies-
WSDeborah
AskWoody LoungerMarch 7, 2001 at 7:39 pm #517766 -
WScharlotte
AskWoody LoungerMarch 8, 2001 at 3:55 am #517840You can’t use variables in the control source of reports or forms because variables are only usable in code. What you can do is either as Deborah suggests, or you can populate the textbox from code based on the value of the variable. In other words, in some event procedure you set Me.Textbox1=str1, substituting the actual name of your control for Textbox1.
-
WSBart
AskWoody LoungerMarch 8, 2001 at 6:56 am #517856Just define a public function in any module you want.
It should look like this:Public Function fnFillTest() As String
fnFillTest = “Nice output!”
End FunctionCall the function in the Control Source property of the control you want the value to be displayed:
=fnFillTest()That will do the job for you.
-
WSBCKessinger
AskWoody Lounger
Viewing 3 reply threads -

Plus Membership
Donations from Plus members keep this site going. You can identify the people who support AskWoody by the Plus badge on their avatars.
AskWoody Plus members not only get access to all of the contents of this site -- including Susan Bradley's frequently updated Patch Watch listing -- they also receive weekly AskWoody Plus Newsletters (formerly Windows Secrets Newsletter) and AskWoody Plus Alerts, emails when there are important breaking developments.
Get Plus!
Welcome to our unique respite from the madness.
It's easy to post questions about Windows 11, Windows 10, Win8.1, Win7, Surface, Office, or browse through our Forums. Post anonymously or register for greater privileges. Keep it civil, please: Decorous Lounge rules strictly enforced. Questions? Contact Customer Support.
Search Newsletters
Search Forums
View the Forum
Search for Topics
Recent Topics
-
Add serial device in Windows 11
by
Theodore Dawson
6 hours, 13 minutes ago -
Windows 11 users reportedly losing data due forced BitLocker encryption
by
Alex5723
7 hours, 13 minutes ago -
Cached credentials is not a new bug
by
Susan Bradley
10 hours, 47 minutes ago -
Win11 24H4 Slow!
by
Bob Bible
10 hours, 58 minutes ago -
Microsoft hiking XBox prices starting today due to Trump’s tariffs
by
Alex5723
8 hours, 9 minutes ago -
Asus adds “movement sensor” to their Graphics cards
by
n0ads
13 hours, 8 minutes ago -
‘Minority Report’ coming to NYC
by
Alex5723
9 hours, 28 minutes ago -
Apple notifies new victims of spyware attacks across the world
by
Alex5723
21 hours, 50 minutes ago -
Tracking content block list GONE in Firefox 138
by
Bob99
21 hours, 14 minutes ago -
How do I migrate Password Managers
by
Rush2112
5 hours, 4 minutes ago -
Orb : how fast is my Internet connection
by
Alex5723
6 hours, 53 minutes ago -
Solid color background slows Windows 7 login
by
Alex5723
1 day, 9 hours ago -
Windows 11, version 24H2 might not download via Windows Server Updates Services
by
Alex5723
1 day, 8 hours ago -
Security fixes for Firefox
by
Susan Bradley
8 hours, 28 minutes ago -
Notice on termination of services of LG Mobile Phone Software Updates
by
Alex5723
1 day, 20 hours ago -
Update your Apple Devices Wormable Zero-Click Remote Code Execution in AirPlay..
by
Alex5723
2 days, 5 hours ago -
Amazon denies it had plans to be clear about consumer tariff costs
by
Alex5723
1 day, 20 hours ago -
Return of the brain dead FF sidebar
by
EricB
1 day, 7 hours ago -
Windows Settings Managed by your Organization
by
WSDavidO61
10 hours, 32 minutes ago -
Securing Laptop for Trustee Administrattor
by
PeachesP
6 hours, 57 minutes ago -
The local account tax
by
Susan Bradley
1 day, 8 hours ago -
Recall is back with KB5055627(OS Build 26100.3915) Preview
by
Alex5723
2 days, 18 hours ago -
Digital TV Antenna Recommendation
by
Win7and10
2 days, 10 hours ago -
Server 2019 Domain Controllers broken by updates
by
MP Support
3 days, 6 hours ago -
Google won’t remove 3rd party cookies in Chrome as promised
by
Alex5723
3 days, 7 hours ago -
Microsoft Manager Says macOS Is Better Than Windows 11
by
Alex5723
3 days, 11 hours ago -
Outlook (NEW) Getting really Pushy
by
RetiredGeek
2 days, 13 hours ago -
Steps to take before updating to 24H2
by
Susan Bradley
11 hours, 24 minutes ago -
Which Web browser is the most secure for 2025?
by
B. Livingston
2 days, 17 hours ago -
Replacing Skype
by
Peter Deegan
2 days, 6 hours ago
Recent blog posts
Key Links
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
1 | 2 | 3 | ||||
4 | 5 | 6 | 7 | 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 | 22 | 23 | 24 |
25 | 26 | 27 | 28 | 29 | 30 | 31 |
Want to Advertise in the free newsletter? How about a gift subscription in honor of a birthday? Send an email to sb@askwoody.com to ask how.
Mastodon profile for DefConPatch
Mastodon profile for AskWoody
Home • About • FAQ • Posts & Privacy • Forums • My Account
Register • Free Newsletter • Plus Membership • Gift Certificates • MS-DEFCON Alerts
Copyright ©2004-2025 by AskWoody Tech LLC. All Rights Reserved.