#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 5
Default if statement

Hi there,
I have a workbook that gives me information with time in 24hr clock and what
l alo have is a list of of numbers that l want to match as close as possibleo
each time. example
list of numbers to choose from
06:00 230
07;00 231
08:00 232
So what l am trying to do is if 06;00 equals 230 then put in 230 into column
whatever
then 07:00 would have to equal 231
then 08;00 would have to be 232 and so on
it will always equal a number referenced of the side numbers so there will
be no false statement.
what l have done is =if(f:f<300,"230"),(g:g)
l want it to put the information back into column G. So what l am trying to
say is if <300 make it 230 and return it to column G. then for the next one l
have done is
=if(f:f0700,"231"),(g:g) if greater than 0700 make it 231. Can l do this at
all as l have value written in column G? Thanks chris



--
chris
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,651
Default if statement

Are your values in the first column (and the values with which you are
comparing them) Excel times, or text values, or a mixture?
In your message you've got a mixture of formats such as 06;00 and 06:00.
Excel times should be 06:00. If you want to compare with 06:00 you can
either use TIME(6,0,0) or --"06:00".

Your syntax for the IF function is wrong. Look in Excel help at the syntax.
Remember also that a formula won't return a value for a column, but a value
for a cell. You can then copy that formula to other cells in the column if
you so wish.

You may also need to be more careful with your comparison formulae, as to
whether you want < or <=, and similarly or =. Think about what you want
the formula to give if the values aree equal.
--
David Biddulph

"hotlh" wrote in message
...
Hi there,
I have a workbook that gives me information with time in 24hr clock and
what
l alo have is a list of of numbers that l want to match as close as
possibleo
each time. example
list of numbers to choose from
06:00 230
07;00 231
08:00 232
So what l am trying to do is if 06;00 equals 230 then put in 230 into
column
whatever
then 07:00 would have to equal 231
then 08;00 would have to be 232 and so on
it will always equal a number referenced of the side numbers so there will
be no false statement.
what l have done is =if(f:f<300,"230"),(g:g)
l want it to put the information back into column G. So what l am trying
to
say is if <300 make it 230 and return it to column G. then for the next
one l
have done is
=if(f:f0700,"231"),(g:g) if greater than 0700 make it 231. Can l do this
at
all as l have value written in column G? Thanks chris



--
chris



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 10,593
Default if statement

Here is a suggestion

=INDEX(B:B,ROUNDUP(A1*24,0))

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"hotlh" wrote in message
...
Hi there,
I have a workbook that gives me information with time in 24hr clock and
what
l alo have is a list of of numbers that l want to match as close as
possibleo
each time. example
list of numbers to choose from
06:00 230
07;00 231
08:00 232
So what l am trying to do is if 06;00 equals 230 then put in 230 into
column
whatever
then 07:00 would have to equal 231
then 08;00 would have to be 232 and so on
it will always equal a number referenced of the side numbers so there will
be no false statement.
what l have done is =if(f:f<300,"230"),(g:g)
l want it to put the information back into column G. So what l am trying
to
say is if <300 make it 230 and return it to column G. then for the next
one l
have done is
=if(f:f0700,"231"),(g:g) if greater than 0700 make it 231. Can l do this
at
all as l have value written in column G? Thanks chris



--
chris



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
Can an If statement answer an If statement? M.A.Tyler Excel Discussion (Misc queries) 2 June 24th 07 04:14 AM
appending and IF statement to an existing IF statement spence Excel Worksheet Functions 1 February 28th 06 11:00 PM
if statement Frank Drost Excel Discussion (Misc queries) 1 December 12th 05 04:32 AM
If statement and Isblank statement Rodney C. Excel Worksheet Functions 0 January 18th 05 08:39 PM
Help please, IF statement/SUMIF statement Brad_A Excel Worksheet Functions 23 January 11th 05 02:24 PM


All times are GMT +1. The time now is 10:31 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"