Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11
Default Format data to a different look

I receive a spreadsheet with data that I need to copy and paste this in to
another spreadsheet.

The data appears as follows in the following format:
1378:20:00
675:00:00
11:40:00
1:40:00
0:00

I need to write a formula or convert this into the following format:
1378.20
675.00
11.40
1.40
0.00

How can this be accomplished?

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7,247
Default Format data to a different look

With a formula, you can use

=INT(A1*24)+(MINUTE(A1)/100)

To convert a lot of cells at once, use the following code:

Sub AAA()
Dim R As Range
For Each R In Selection.Cells
R.Value = Int(R * 24) + (Minute(R) / 100)
Next R
End Sub

Select the cell(s) you want to convert and then run the code. Be sure
to format the result cells as General or Numeric, not Date or Time.

Cordially,
Chip Pearson
Microsoft Most Valuable Professional
Excel Product Group, 1998 - 2009
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)


On Mon, 9 Feb 2009 10:10:01 -0800, rylv5050
wrote:

I receive a spreadsheet with data that I need to copy and paste this in to
another spreadsheet.

The data appears as follows in the following format:
1378:20:00
675:00:00
11:40:00
1:40:00
0:00

I need to write a formula or convert this into the following format:
1378.20
675.00
11.40
1.40
0.00

How can this be accomplished?

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,934
Default Format data to a different look

I would think you can use this formula in another cell...

=TEXT(A1,"[h].mm")

and Copy/Paste Special/Values that column into your other worksheet.

--
Rick (MVP - Excel)


"rylv5050" wrote in message
...
I receive a spreadsheet with data that I need to copy and paste this in to
another spreadsheet.

The data appears as follows in the following format:
1378:20:00
675:00:00
11:40:00
1:40:00
0:00

I need to write a formula or convert this into the following format:
1378.20
675.00
11.40
1.40
0.00

How can this be accomplished?


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
Lock Cell Format - Allow copy and paste of data without format change Chris12InKC Excel Worksheet Functions 2 May 9th 23 07:42 PM
Increase Your Business By Data Conversion, Data Format and Data EntryServices in India Data Entry India Excel Worksheet Functions 1 March 31st 08 12:51 PM
Data Entry Online, Data Format, Data Conversion and Data EntryServices through Data Entry Outsourcing [email protected] Excel Discussion (Misc queries) 0 March 20th 08 12:45 PM
Data in Cross-Tab format: needs to be written in Table Format runyan Excel Programming 2 October 4th 05 07:58 AM
code for converting data format in another format mistral Excel Programming 0 August 19th 04 04:50 PM


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