Locking a Checkbox to a line

Scott_j

New Member
Joined
Jul 5, 2019
Messages
5
Hey guys ive search this forum and found how to lock and also how to link; a checkbox to a cell but when I sort my data the checkbox remains where it was placed.
My spread sheet is an inspection list
where cell A1 is true/false
Cell B1 is my checkbox (Active X)
Cell C1 is an address
Cell D1 is a suburb
Cell F1 is an inspection date
Cell G1 is a Yes/No data validation.

My check box is formatted to checkif "Yes"


naturally the cells below are filled in the same way and this is where I get stuck;
Firstly I cant lock my checkboxes to a cell so if I delete an entire line everything shifts up and
When I sort my data so all the Suburbs are alphabetical the check boxes do not move with the corresponding row.

I hope this makes sense.
Also as the list I am generating grows fast can i creat rows of check boxes (Ie the pull down method) or do i have to make and format each checkbox as i enter the line items?

Cheers
-Scotty
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.
I never believe it's a good practice to use a lot of Checkboxes like this:

When you click on the Checkbox what do you expect to happen?

Why not use something like double click on B1 and do something.
 
Upvote 0
Thanks for getting back to me so quickly.

I was trying to utilize for reporting purposes; I have an additional field for countif that displays
number of inspections total, number completed, number outstanding and total%

I was hoping to keep these Countif fields based on the true/false and total number of Column A (true/false column)
 
Upvote 0
I'm not sure what your wanting.

Tell me when you click om the checkbox what do you want to happen?

For example say when I click on checkbox I want Range("C2"). value to say "Yes"

And when you say:
I was hoping to keep these Countif fields

Where are these cells. Say something like Range("A1")
 
Upvote 0
apologies i may have over simplified above;
My checkbox is located in B16 and linked to A16.
A16 is =IF(N16="No",TRUE,FALSE)

which means if I have completed a job on my spreadsheet (Yes/No in Ncolumn) then the checkbox is ticked.

Located at the top of my spreadsheet is my statistics;
Total inspections; =COUNTA(A16:A100)
Completed inspections: =COUNTIF(A16:A100,TRUE)
Remaining Inspections: =SUM(E4-E5)
% of compelted: =COUNTIF(A16:A100,TRUE)/COUNTA(C16:C100)

So my stats are comprised of hidden column A True /False
The check boxes are visual purposes only but I am not able to lock them to a cell. If i sort (Suburb for example) then the checkboxes and fomulas do not move with the data. Is there a way to lock them to the row?
 
Upvote 0
zX6sJ5n
 
Upvote 0

Forum statistics

Threads
1,214,643
Messages
6,120,707
Members
448,981
Latest member
recon11bucks

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top