Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
Don Guillett
 
Posts: n/a
Default Convert Data Range in to individual values

If you meant
50020
50021
50022
50023
50024
50025

then try

Sub fixdata()
For i = Cells(Rows.Count, "d").End(xlUp).Row To 2 Step -1
Set mc = Cells(i, 4)
inst = InStr(mc, "-")
If inst 0 Then
n1 = Left(mc, inst - 1)
n2 = Right(mc, Len(mc) - inst)
Count = n2 - n1
mc.Value = n1
Cells(mc.Row + 1, 4).Resize(Count, 1).EntireRow.Insert
mc.AutoFill Destination:=mc.Resize(Count + 1)
End If
Next i
End Sub

--
Don Guillett
SalesAid Software

"mistryrg" wrote in message
...

Hi,

Need some help!

I am trying to convert a spreadsheet of data which has individual cells
and data-range cells and convert them into indvidual values.

e.g.

50010
50013
50020-50033
50050

The individual cells are fine, but the 50020-50033 for example I want
to be able to convert/export as individual cells, i.e. 50020, 50021,
50022,...50031,50033.

Can anyone please help me with this.

All help is very much appreciated

Thanks
Raj Mistry


--
mistryrg



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
consolidation of tables in excel with text and figures samenvoegen van sheets Excel Worksheet Functions 8 March 2nd 06 03:27 PM
Newbie to charts question - projecting values between data points 38N90W Excel Discussion (Misc queries) 3 January 6th 05 05:15 AM
Convert data type of cells to Text,Number,Date and Time Kevin Excel Worksheet Functions 1 December 31st 04 12:57 PM
Extending a Chart Data Series from an Array - Can it be done? Jon Peltier Charts and Charting in Excel 4 November 30th 04 03:30 AM
Can you average data in 1 column based on a range of values in another? kman24 Excel Worksheet Functions 2 November 17th 04 02:09 PM


All times are GMT +1. The time now is 12:33 PM.

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

About Us

"It's about Microsoft Excel"