Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
hbk hbk is offline
external usenet poster
 
Posts: 1
Default Please Help!!!

I made a box with values(e.g. N = No Work, 1 = New Ceiling Tile, 2 = New etc.). How do I write a function so that it will check all the values. The only thing I remember from school is else or elseif statements. Can you do those in Excel or is there just some way I'm naive to?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Please Help!!!

Hi

Not sure I understand your question ?

You posted in programming so I give you a code example
Do you need that??

You can use the change event with Select Case

Here is a example that use the Change event of the worksheet
Right click on a sheet tab and choose view code.
Paste the event in there and press Alt-Q to go back to Excel.

This will only work in a1:a20

Private Sub Worksheet_Change(ByVal Target As Range)
If Not Application.Intersect(Range("a1:a20"), Target) Is Nothing Then
Select Case Target.Value
Case "N"
Target.Value = "No Work"
Case 1
Target.Value = "New Ceiling Tile"
Case 2
Target.Value = "New ...."
End Select
End If
End Sub

--
Regards Ron de Bruin
http://www.rondebruin.nl


"hbk" wrote in message ...
I made a box with values(e.g. N = No Work, 1 = New Ceiling Tile, 2 = New etc.). How do I write a function so that it will check

all the values. The only thing I remember from school is else or elseif statements. Can you do those in Excel or is there just
some way I'm naive to?


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



All times are GMT +1. The time now is 01:42 AM.

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"