Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 318
Default Cell with a certain value to go to...

Hello
I need a code to do the following
This is for a form I created
If the value in cell N39 is YES then go to cell q36
If the value is something else besides Yes then it should do nothing
Thank you

  #2   Report Post  
Posted to microsoft.public.excel.misc
bj bj is offline
external usenet poster
 
Posts: 1,397
Default Cell with a certain value to go to...

when is this to take place?
When you open it?
when you print it?
When you close it?
etc.
do you want it to stay at Q36 from then on?
How does N39 get changed?

"Wanna Learn" wrote:

Hello
I need a code to do the following
This is for a form I created
If the value in cell N39 is YES then go to cell q36
If the value is something else besides Yes then it should do nothing
Thank you

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 318
Default Cell with a certain value to go to...

bj thanks
This is a protected form (Below are the correct cell numbers)
This is to take place when the person completing the form gets to cell N29
and from the dropdown list (created in validation -List- source =indirect
(B29) selects yes or Lab without (there are only 4 choices in the dropdown
list (Yes , No, lab with, lab without)

If the person selects Yes or lab without then it should go to O31 (that is
skip Q29)
One thing O31 is an option button (created from the forms toolbar) = yes
or no which answers a question on row 31 ) . After that person should be
able to complete the rest of the form

IF the person selects No or Lab with it should go to Q29 then after that O31
. After that person should be able to complete the rest of the form
Thanks BJ Hope this is clear

"bj" wrote:

when is this to take place?
When you open it?
when you print it?
When you close it?
etc.
do you want it to stay at Q36 from then on?
How does N39 get changed?

"Wanna Learn" wrote:

Hello
I need a code to do the following
This is for a form I created
If the value in cell N39 is YES then go to cell q36
If the value is something else besides Yes then it should do nothing
Thank you

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 136
Default Cell with a certain value to go to...

a) Open VB Editor
b) Find your project in the Explorer pane
c) Double click to open the worksheet where your form is
d) Paste this:

Private Sub Worksheet_Change(ByVal Target As Range)

If Target.Address = Range("N29").Address Then
If Target = "Yes" Or Target = "Lab with" Then
Range("O32").Select
Else
Range("Q29").Select
End If
End If

End Sub

"Wanna Learn" wrote:

bj thanks
This is a protected form (Below are the correct cell numbers)
This is to take place when the person completing the form gets to cell N29
and from the dropdown list (created in validation -List- source =indirect
(B29) selects yes or Lab without (there are only 4 choices in the dropdown
list (Yes , No, lab with, lab without)

If the person selects Yes or lab without then it should go to O31 (that is
skip Q29)
One thing O31 is an option button (created from the forms toolbar) = yes
or no which answers a question on row 31 ) . After that person should be
able to complete the rest of the form

IF the person selects No or Lab with it should go to Q29 then after that O31
. After that person should be able to complete the rest of the form
Thanks BJ Hope this is clear

"bj" wrote:

when is this to take place?
When you open it?
when you print it?
When you close it?
etc.
do you want it to stay at Q36 from then on?
How does N39 get changed?

"Wanna Learn" wrote:

Hello
I need a code to do the following
This is for a form I created
If the value in cell N39 is YES then go to cell q36
If the value is something else besides Yes then it should do nothing
Thank you

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 318
Default Cell with a certain value to go to...

Tevuna Awesome PERFECT thanks!

"Tevuna" wrote:

a) Open VB Editor
b) Find your project in the Explorer pane
c) Double click to open the worksheet where your form is
d) Paste this:

Private Sub Worksheet_Change(ByVal Target As Range)

If Target.Address = Range("N29").Address Then
If Target = "Yes" Or Target = "Lab with" Then
Range("O32").Select
Else
Range("Q29").Select
End If
End If

End Sub

"Wanna Learn" wrote:

bj thanks
This is a protected form (Below are the correct cell numbers)
This is to take place when the person completing the form gets to cell N29
and from the dropdown list (created in validation -List- source =indirect
(B29) selects yes or Lab without (there are only 4 choices in the dropdown
list (Yes , No, lab with, lab without)

If the person selects Yes or lab without then it should go to O31 (that is
skip Q29)
One thing O31 is an option button (created from the forms toolbar) = yes
or no which answers a question on row 31 ) . After that person should be
able to complete the rest of the form

IF the person selects No or Lab with it should go to Q29 then after that O31
. After that person should be able to complete the rest of the form
Thanks BJ Hope this is clear

"bj" wrote:

when is this to take place?
When you open it?
when you print it?
When you close it?
etc.
do you want it to stay at Q36 from then on?
How does N39 get changed?

"Wanna Learn" wrote:

Hello
I need a code to do the following
This is for a form I created
If the value in cell N39 is YES then go to cell q36
If the value is something else besides Yes then it should do nothing
Thank you

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I make a blank cell in a formula cell with a range of cell Vi Excel Discussion (Misc queries) 5 June 21st 07 02:46 PM
cell data not validated if navigating cell to cell with mouse LoveThatMouse Excel Worksheet Functions 6 May 21st 06 09:03 PM
How to create/run "cell A equals Cell B put Cell C info in Cell D abmb161 Excel Discussion (Misc queries) 5 January 26th 06 07:36 PM
Cell Formula reference to cell Based On third Cell Content Gabriel Excel Discussion (Misc queries) 1 February 11th 05 07:36 AM
Cell Formula reference to cell Based On third Cell Content Gabriel Excel Discussion (Misc queries) 0 February 11th 05 06:35 AM


All times are GMT +1. The time now is 10:48 PM.

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

About Us

"It's about Microsoft Excel"