Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Microsoft Office > Access and Access VBA > Access VBA
|
Access VBA Discuss using VBA for Access programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access VBA section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old November 14th, 2004, 06:42 PM
Registered User
 
Join Date: Nov 2004
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Populating report or form textboxes

Hi,

I designed an Access 2000 report with textboxes. This report is a form that needs to be populated from module variables. There are 80 of them but they all need a seperate piece of data.

How do I get a piece of data into a textbox on a report? (I've also created the same design on a form so if textboxes on a form would be easier to populate, I'll take this option.)

Thanks,

Mike
StayGold1@aol.com

 
Old November 15th, 2004, 12:34 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 1,151
Thanks: 2
Thanked 14 Times in 14 Posts
Send a message via ICQ to SerranoG Send a message via AIM to SerranoG
Default

You could write a query that brings the 80 pieces of data together and base the report on the query.

Greg Serrano
Michigan Dept. of Environmental Quality, Air Quality Division
 
Old November 15th, 2004, 02:29 PM
Registered User
 
Join Date: Nov 2004
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

HI. Thanks for the response.

I'll give it a shot.


Thanks,

Mike

 
Old November 15th, 2004, 03:53 PM
Friend of Wrox
 
Join Date: Mar 2004
Posts: 3,069
Thanks: 0
Thanked 10 Times in 10 Posts
Default

Hi,

   Do you mean that you have declared the variables in a module, and then you want to refer to one or some variable(s) to populate the text box?

   If that is the case, then you could make a table with the variable names in it, and then populate your text box or combo box with that table.

   That would pass the proper name to your module.

   In any event, you can't query the module for the variable names.

   When you mention that there are 80 variables and they each need a seperate piece of data, does that mean you want to pass data to the functions in your module? If so, you can store data in a seperate table and pass the selected values to your functions.

   You also say you have a report that is a form? That isn't right. But you have text boxes on a report that needs to get data from a module? If that is the case, then you need to enter the name of the function in the unbound text boxes control source. I have a function called "PG" in one of my reports that I reference from the control source like this: =PG()

   Since the language of your question is ambiguous, it is difficult for me to fully address your needs. Can you be more specific and not equivocate?

Thanks,


mmcdonal





Similar Threads
Thread Thread Starter Forum Replies Last Post
Populating an unbound form from a table Luis Access VBA 8 November 21st, 2008 08:37 AM
populating textboxes using list/Menu rylemer Javascript 0 November 23rd, 2005 10:05 PM
Populating a form maneor Access 1 September 30th, 2004 03:41 PM
Store Data From textboxes which form Table gadhiav ASP.NET 1.0 and 1.1 Basics 7 June 30th, 2004 11:10 PM
Populating Fields on a Form with Cookie Name-Value WebDevel Javascript How-To 1 December 5th, 2003 05:15 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.