macro to send user to another sheet in document if checkbock is ticked, but do nothing if unticked

yashoo0

New Member
Joined
May 27, 2019
Messages
1
I Team,
I need help with code for an excel macro, which sends users to another sheet in an excel table once a checkbox is checked, but does nothing if it is unchecked.

I tried this already, but no luck:
<code>Sub CheckBox28_Click()
If OptionButton1 = True Then
Sheets("Sheet3!A1").Select
ElseIf OptionButton1 = False Then
End If


End Sub</code> It compiles, but nothing happens when the macro is assigned to the checkbox

Please, help :)
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.
When you activate CheckBox28 and optionbutton1 is active then it goes to the other sheet


But if you turn off the CheckBox28, nothing happens
What do you want the macro to do?


If you activate CheckBox28 and optionbutton1 is deactivated then nothing happens
What do you want the macro to do?
 
Upvote 0

Forum statistics

Threads
1,224,818
Messages
6,181,152
Members
453,021
Latest member
Justyna P

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