How To Have Only One Checkbox In A Group Of 3 Selected At A Time
Mar 23, 2008
I have a spreadsheet that consists for 30 rows of groups of three checkboxes on each row. I want to have only one checkbox per row checked at a time. If the user checks one box while another it already checked then I want that checbox to be unchecked.
I want checkboxes to work like groups of option buttons. Actually, option buttons would be fine but with option buttons there is always one clicked but I need them all clear until the user clicks one. They will start off clear but if the user clicks one by mistake there is no way that I know of to clear it again. Checkboxes will clear again if you click it again so I thought I would use them.
how to have a group of three option buttons or checkboxes that will begin unchecked and be able to uncheck all three is one is checked in error,
I have up to 6 checkboxes on a work sheet but I only want one of them to be allowed to be checked at any given time. Is there a way to make sure this happens? As an example if the first check box is marked and then the user checks Checkbox4 checkbox1 would automatically be unmarked.
I have a spreadsheet that I use for people to make requests.
They can only select from the dropdown menus or the check boxes in the spreadsheet. Some fields are required.
I have a button that they click on to save the workbook.
When they click on it a macro checks if all required fields are completed. If they aren't, The user receives a Message box asking them to complete all required fields.
The problem I'm having is with 5 checkboxes each linked to a cell (B11:B15).
The user can check any or all of the boxes but they need to select at least one.
how I can check if the user selected at least one and if not then I would display a Message box asking them to select at least one?
I would like to ask regarding checkbox checking. I have 1 master checkbox and 3 sub checkboxes on the userform, and my target is that if the master checkbox is selected then I want to receive a msg if one of 3 checkbox are not selected when I hit the "Confirm" commandbutton.
I was asked about if i can copy defined cells when i checked its checkbox by using vba button , and another button in another book to paste those cells .
Mention that i may select more than one checkbox in copying and when i would paste these checkboxes , they would be in queue.
I have a workbook containing several sheets, each sheet has a large number of ActiveX check box controls on it.
The controls are presented in groups of three to capture responses to a question (Y/N/NA). If one of the three check boxes is set to True, the other two associated check boxes must be set to False.
What I want to do is avoid having to have an On_Click event sub for every single check box.
I have written a function that will handle updating the related check boxes but I am unsure how to call this function, passing it the name of the clicked Check Box whenever any check box is clicked.
Here is my current code with an On_Click event being used to call the function:
Private Sub chk100_01Y_Click()
' Want to replace this with a dynamic sub that will be invoked ' when any Check Box is clicked and pass the name of that Check ' box to the function
I currently have a user form and am trying to make a counter to that will increment if the check box is not selected, but will not increment if the check box is selected.
I am assuming I could use an if then statement for this, under the command_click OK. but I cant get it to work.
I would like to do is to sort only selected sheets. Can someone give me this additional code that can be incorporated in the code below. (If I just select the sheets I want sorted and run the code below, it sorts all worksheets irrespective of whether it is active or not).
Sub SortWorksheets() Dim N As Integer Dim M As Integer Dim FirstWSToSort As Integer Dim LastWSToSort As Integer Dim SortDescending As Boolean SortDescending = False If ActiveWindow.SelectedSheets.Count = 1 Then FirstWSToSort = 1 LastWSToSort = Worksheets.Count Else With ActiveWindow.SelectedSheets For N = 2 To .Count ................
Im looking for a macro that can get a cell RANGE, the data in the RANGE will be copied then if the checkbox is selected it will copy the same data in the RANGE and add the selected checkbox in next column
I have column A and Column B < this is my selected range
Capture1.PNG
I will have a form that has checkbox and buton.
When all the checkbox is selected. when the button is click. the result will be.
I would like to group some columns to all the sheets that I will have selected. Unfortunately the below code only apply the code to the sheet I am looking at.
Code: Sub Group() Dim ws As Worksheet
For Each ws In ActiveWorkbook.Worksheets With ws.Range("F:Q").Group End With Next ws End Sub
I have a survey with different groups of Control Toolbox options buttons on it. I want to ensure that each question has an option button selected before the survey can be exited and emailed onwards. The grouped button names are: GroupA, Group1 through to Group6.
On the attached Dynamic chart I have attached there are 3 checkboxes to display certain data. My issue is this, if I click the outside checkbox and the ISE checkbox at the same time that is OK, it gives me a comparison of the two data sets in a bar chart. Perfect. If I click just the total checkbox it gives me the total info of the outside and ISE, again perfect.
But, If I click all 3, it doubles all the numbers because total is total and outside + ISE also equals the total.
My Question, -Is there a way to lock out a checkbox if another is active? if 1 then no 2 or 3. if 2, 3 is OK but 1 is not. if 3 then 2 is ok but 1 is not? -If it can't be locked can it do something like; If #1 has a check and you try to enter #2 a red error message could come up saying these two choices together the data will be inaccurate. I'm thinking this might be done in conditional formatting.
If option one is doable and easy, is it also possible to have an error message like in my second idea so people will know why they can't click that second box? This would be my preferred fix but I am open to any other option you may have to accomplish this.
I need a date and time to appear and disappear in the corresponding cells when the checkbox is ticked and unticked. I got it to work but that was before i had multiple checkboxes on one line and added merged cells.
In my userform I have a list of check box's that can be selected. Currently if more than one is selected, they will appear in the spread sheet in the same line one after another with a space between them. How do I make it so they either appear with a comma appearing after each, so the next value appears on the next line below or most perferably the cell turning to a drop down list with the values?
Current code
VB: If CheckBox1.Value = True Then ws.Cells(iRow, 2).Value = ws.Cells(iRow, 2).Value & " " & CheckBox1.Caption If CheckBox2.Value = True Then ws.Cells(iRow, 2).Value = ws.Cells(iRow, 2).Value & " " & CheckBox2.Caption If CheckBox3.Value = True Then ws.Cells(iRow, 2).Value = ws.Cells(iRow, 2).Value & " " & CheckBox3.Caption If CheckBox4.Value = True Then ws.Cells(iRow, 2).Value = ws.Cells(iRow, 2).Value & " " & CheckBox4.Caption If CheckBox5.Value = True Then ws.Cells(iRow, 2).Value = ws.Cells(iRow, 2).Value & " " & CheckBox5.Caption If CheckBox6.Value = True Then ws.Cells(iRow, 2).Value = ws.Cells(iRow, 2).Value & " " & CheckBox6.Caption
Spreadsheet current cell appearence if all 6 are selected ' Chinnook EH101 Lynx Puma Sea King Fixed Wing'
Required appearence: Chinnook EH101 Lynx Puma Sea King Fixed Wing
I have several 4 groups that all need to do the same thing. Is it possible to write all of them in one group or do I have to write each one individual in the conditional formatting?
I want to graph the composition of a group over time. I want to create an area graph, where you can see what kinds of things were in the group at any given year . There are, let's say,three categories of things: A, B, and C - and I have the purchase and sale date for each.
I'm having an issue right now with an employee list that I am working on. What I am trying to do is determine the earliest time that an employee signed in, but the list that I can export may have the same employee on it multiple times in a day.
Here is a sample of the data that I'm using:
Emp No. Time In 9900872 9:00am 9900874 9:03am 9900874 11:00am 9900874 11:45am 9900875 10:15am 9900875 11:45am
What I want to get is the minimums only, so that the list would show:
Emp No. Time In 9900872 9:00am 9900874 9:03am 9900875 10:15am
I know how I could do this in VBA, however I have everything else working without using VBA, so if possible I would like to leave it that way. Also, I do not know if it would matter to the solution, but the employee numbers are always sorted numerically, although their clock in times are not.
I have a larger data file (120,000+ rows). Each row has one column for date and another for time. Basically, I need to add 6 hours to all time entries, but also change the date accordingly.
I am trying to find a way to have excel recognize text data input as date/time.
[Code] .....
Where 02 Is the Date, 2020 is the time (military) Z is Zulu/GMT, MAR is Month and 14 is Year. I believe excel recognizes
[Code] .....
But I have a spreadsheet (on a confidential system) with thousands of entries that I need to convert. Also, the people I have working for me are not remotely. I reject the idea of entering data that way.
I am also trying to keep the display the same format: ddhhmm"Z" MMM yy
now i want to make 5 different graphs one per each group. Now i am making them manually in excel but it is taking lot of time to format each graphs to get unique graphs. I am attching sample file and graph for better understanding.
I have 3 checkboxes; when one is checked, a set/range of rows should be visible. Only 1 checkbox should be checked at a time.
If checkbox 18 is already checked, and checkbox 20 is then checked, I want the first checkbox unchecked and the rows for checkbox hidden.
I'm using the following code. It works great as long as I check and uncheck the same box before attempting to check another box. But if Checkbox18 is already checked with its rows showing, and I then check checkbox20, the checkbox20 sub runs and as I step through, it jumps to sub checkbox18.
How can I stop my subs from jumping from one to another?
Code: Private Sub CheckBox18_Click() If CheckBox18.Value = True Then Worksheets("TRF").Rows("36:41").Hidden = False Worksheets("TRF").Rows("42:64").Hidden = True Worksheets("TRF").Rows("65:76").Hidden = True CheckBox19.Value = False
Attached is a workbook. I have manually highlighted the cells to give idea of what I would like the outcome to be.
Moonah OPS sheet.
In Row 5(Shift times), under the drop down menu in cells B5:J5, there is a range of Shift times. And for the purpose of this I have selected B5 as 0800:1621, manually highlighted B11:B27 C5 as 06:00, manually highlighted C7:C24 D5 as 07:00:1521, manually highlighted B11:B27 E5:I55(RDO, REC, SICK, Travel) can remain as manual input if it is to much to work out.
Is it possible or just a pipe dream, to use some method to automatically highlight a range of cells based on the C5:J5 'time'?
If the time is an actual shift time, the colour will be green and dark green writing as default, then we can allocate jobs/training/meetings and manually colour them.
Daysheet DAY MONTH YEAR template - Highlight.xlsx
I have a combobox with populated values from a named range. I need the first value to be always selected when the form is opened - is there a way to do this
What is the code i need to use to assign a macro to a command button which inserts the current date and time in the selected cell regardless of where that cell is?
I am trying to write VBA code that groups cells between blank rows and inserts a message if a string of text (a name) is missing from the entire group. I want the code to search cells in column A and group the cells between blank cells. Use the name I input in an input box as the search criteria and insert a message in the Column C next to the last blank cell in the group and then move on to the next group and highlight the cell in red with bold text. I am including a spreadsheet with an example of what the sheet should look like before and after the code is run.