LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 25
Default testing a string for either "Minutes" and/or hours and extracting the values

Given a string similar to the one listed below (this is actually testing the
driving direction - printer friendly version pasted into one cell column BC)

Total Est. Time: 1 hour, 35 minutes Total Est. Distance: 94.75 miles

I want to get the time needed to travel in a format that can be added or
subtracted from a time in the format of "7:00PM" (Column D)

I have been using the following (column BE)
=IF(ISERROR(VALUE(MID(BC33,SEARCH("Total Est. Time:",BC33)+16,SEARCH("Total
Est. Distance:",BC33)-(SEARCH("Total Est.
Time:",BC33)+24)))),"",VALUE(MID(BC33,SEARCH("Tota l Est.
Time:",BC33)+16,SEARCH("Total Est. Distance:",BC33)-(SEARCH("Total Est.
Time:",BC33)+24))))


and then =D32 -TIME(0,BE32,0) (this is in Column T )

This seems fine, until it is over 59 minutes. The issue is in the BE column
test. In this case, it returns an empty value.

Thanks!

 
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
=SUBSTITUTE(C4,"~?#","") will this work to remove multiple string Raja Mahendiran S Excel Worksheet Functions 6 May 12th 10 09:10 PM
need a formula to find "*" in s string and multiply by preceding andfollowing values Tonso Excel Discussion (Misc queries) 4 April 20th 10 06:01 AM
Converting "uppercase" string data to "lower case" in CSV file [email protected] Excel Discussion (Misc queries) 2 August 12th 08 08:36 PM
text string: "91E10" in csv file auto converts to: "9.10E+11" [email protected] Excel Discussion (Misc queries) 2 August 12th 08 03:13 PM
Setting values for "TRUE","FALSE" and "#REF!" Hurtige[_2_] Excel Programming 1 August 11th 06 12:31 PM


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