A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » New Users
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Creating a 'select all' button



 
 
Thread Tools Display Modes
  #1  
Old February 4th, 2009, 09:16 PM posted to microsoft.public.access.gettingstarted
Juniper
external usenet poster
 
Posts: 19
Default Creating a 'select all' button

Hi all,

I have created a check box for a project that I'm working on in which I have
to select over 7,000 records in this database.

Is there a way for me to create a 'select all' button that will allow me to
select all the records instead of doing it one by one?

I'm using Microsoft Access 2003.
--
Desperately seeking info
  #2  
Old February 4th, 2009, 09:35 PM posted to microsoft.public.access.gettingstarted
fredg
external usenet poster
 
Posts: 4,386
Default Creating a 'select all' button

On Wed, 4 Feb 2009 13:16:01 -0800, Juniper wrote:

Hi all,

I have created a check box for a project that I'm working on in which I have
to select over 7,000 records in this database.

Is there a way for me to create a 'select all' button that will allow me to
select all the records instead of doing it one by one?

I'm using Microsoft Access 2003.


You mean you wish to set the check box to true for each record?
Just run an Update query.
Code the Click event of a Command Button:

CurrentDb.Execute "Update MyTable Set MyTable.[CheckBoxName] =
True;",dbFailIOnError

To then uncheck the field for all records:

CurrentDb.Execute "Update MyTable Set MyTable.[CheckBoxName] =
False;",dbFailIOnError
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail
  #3  
Old February 5th, 2009, 09:56 AM posted to microsoft.public.access.gettingstarted
troy23
external usenet poster
 
Posts: 55
Default Creating a 'select all' button

If the check boxes are on a form you can write some code to cycle
through each one and check it or uncheck it. There are lots of samples
on the net.

For FREE Access ebook and videos click here
http://access-databases.com/ebook

On 4 Feb, 21:16, Juniper wrote:
Hi all,

I have created a check box for a project that I'm working on in which I have
to select over 7,000 records in this database.

Is there a way for me to create a 'select all' button that will allow me to
select all the records instead of doing it one by one?

I'm using Microsoft Access 2003.
--
Desperately seeking info


  #4  
Old February 5th, 2009, 04:22 PM posted to microsoft.public.access.gettingstarted
Juniper
external usenet poster
 
Posts: 19
Default Creating a 'select all' button

I tried this but I got an error message that I was missing an operand.
But I'll figure it out.

Thanks so much,
--
Desperately seeking info


"fredg" wrote:

On Wed, 4 Feb 2009 13:16:01 -0800, Juniper wrote:

Hi all,

I have created a check box for a project that I'm working on in which I have
to select over 7,000 records in this database.

Is there a way for me to create a 'select all' button that will allow me to
select all the records instead of doing it one by one?

I'm using Microsoft Access 2003.


You mean you wish to set the check box to true for each record?
Just run an Update query.
Code the Click event of a Command Button:

CurrentDb.Execute "Update MyTable Set MyTable.[CheckBoxName] =
True;",dbFailIOnError

To then uncheck the field for all records:

CurrentDb.Execute "Update MyTable Set MyTable.[CheckBoxName] =
False;",dbFailIOnError
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail

  #5  
Old February 5th, 2009, 06:45 PM posted to microsoft.public.access.gettingstarted
Gina Whipp
external usenet poster
 
Posts: 3,500
Default Creating a 'select all' button

Juniper,

If you post the code you are using someone can take a look to see what is
happening...

--
Gina Whipp

"I feel I have been denied critical, need to know, information!" - Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm

"Juniper" wrote in message
...
I tried this but I got an error message that I was missing an operand.
But I'll figure it out.

Thanks so much,
--
Desperately seeking info


"fredg" wrote:

On Wed, 4 Feb 2009 13:16:01 -0800, Juniper wrote:

Hi all,

I have created a check box for a project that I'm working on in which I
have
to select over 7,000 records in this database.

Is there a way for me to create a 'select all' button that will allow
me to
select all the records instead of doing it one by one?

I'm using Microsoft Access 2003.


You mean you wish to set the check box to true for each record?
Just run an Update query.
Code the Click event of a Command Button:

CurrentDb.Execute "Update MyTable Set MyTable.[CheckBoxName] =
True;",dbFailIOnError

To then uncheck the field for all records:

CurrentDb.Execute "Update MyTable Set MyTable.[CheckBoxName] =
False;",dbFailIOnError
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail



  #6  
Old February 6th, 2009, 02:30 PM posted to microsoft.public.access.gettingstarted
Juniper
external usenet poster
 
Posts: 19
Default Creating a 'select all' button

Hi Gina,

I created a checkbox called 'Select All' and I need to somehow link this to
three other existing checkboxes called 'auto-renew', 'DNR' and 'verified'. I
want to be able to click on the 'select all' button and have it select all
the records by either one of these checkboxes 'auto-renew', 'DNR' and
'verified'. Sometimes I need to select the records only by 'auto-renew'. So,
the action of select all is only for one checkbox at any given time.

Do I need to create a 'Select All' button for each of the three checkboxes
and how do I create a link between them?

--
Desperately seeking info


"Gina Whipp" wrote:

Juniper,

If you post the code you are using someone can take a look to see what is
happening...

--
Gina Whipp

"I feel I have been denied critical, need to know, information!" - Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm

"Juniper" wrote in message
...
I tried this but I got an error message that I was missing an operand.
But I'll figure it out.

Thanks so much,
--
Desperately seeking info


"fredg" wrote:

On Wed, 4 Feb 2009 13:16:01 -0800, Juniper wrote:

Hi all,

I have created a check box for a project that I'm working on in which I
have
to select over 7,000 records in this database.

Is there a way for me to create a 'select all' button that will allow
me to
select all the records instead of doing it one by one?

I'm using Microsoft Access 2003.

You mean you wish to set the check box to true for each record?
Just run an Update query.
Code the Click event of a Command Button:

CurrentDb.Execute "Update MyTable Set MyTable.[CheckBoxName] =
True;",dbFailIOnError

To then uncheck the field for all records:

CurrentDb.Execute "Update MyTable Set MyTable.[CheckBoxName] =
False;",dbFailIOnError
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail




  #7  
Old February 6th, 2009, 05:32 PM posted to microsoft.public.access.gettingstarted
Gina Whipp
external usenet poster
 
Posts: 3,500
Default Creating a 'select all' button

Juniper,

Looks like Fredg's snippet will give you what you want or is that not the
way you want to do it? The code could be attched to a button.

--
Gina Whipp

"I feel I have been denied critical, need to know, information!" - Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm

"Juniper" wrote in message
...
Hi Gina,

I created a checkbox called 'Select All' and I need to somehow link this
to
three other existing checkboxes called 'auto-renew', 'DNR' and 'verified'.
I
want to be able to click on the 'select all' button and have it select all
the records by either one of these checkboxes 'auto-renew', 'DNR' and
'verified'. Sometimes I need to select the records only by 'auto-renew'.
So,
the action of select all is only for one checkbox at any given time.

Do I need to create a 'Select All' button for each of the three checkboxes
and how do I create a link between them?

--
Desperately seeking info


"Gina Whipp" wrote:

Juniper,

If you post the code you are using someone can take a look to see what is
happening...

--
Gina Whipp

"I feel I have been denied critical, need to know, information!" -
Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm

"Juniper" wrote in message
...
I tried this but I got an error message that I was missing an operand.
But I'll figure it out.

Thanks so much,
--
Desperately seeking info


"fredg" wrote:

On Wed, 4 Feb 2009 13:16:01 -0800, Juniper wrote:

Hi all,

I have created a check box for a project that I'm working on in
which I
have
to select over 7,000 records in this database.

Is there a way for me to create a 'select all' button that will
allow
me to
select all the records instead of doing it one by one?

I'm using Microsoft Access 2003.

You mean you wish to set the check box to true for each record?
Just run an Update query.
Code the Click event of a Command Button:

CurrentDb.Execute "Update MyTable Set MyTable.[CheckBoxName] =
True;",dbFailIOnError

To then uncheck the field for all records:

CurrentDb.Execute "Update MyTable Set MyTable.[CheckBoxName] =
False;",dbFailIOnError
--
Fred
Please respond only to this newsgroup.
I do not reply to personal e-mail






 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 08:32 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.