English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

Actually Ive been given to edit 1500 lines in excel....there i had to put commas between number arranged in column

123
234
124
345
456
into 234, 124, 345, 456

This seem to be a never ending task...there is no option in excel to change it that way...Can anybody write a simple executable software in which I can copy these column numbers and consequently obtain the desirable results in running it....

definitely 10 points..for the best answer..not good enough incentive...I know...but that the most i can do...

send the programme as attachment to vivex_7@yahoo.com or give me a download link....

2007-09-21 18:34:10 · 3 answers · asked by robin 3 in Computers & Internet Programming & Design

3 answers

Open the doc in Excel. Go to Visual Basic Editor (Tools --> Macros?).
Copy & Paste the following macro:

Public Sub Temp()
Dim I As Integer
For I = 1 To 1500
Cells(1, 2) = Cells(1, 2) & Cells(I, 1) & ", "
Next I
End Sub

Then execute the Temp macro. I think the F5 key should do it if your cursor is between Sub and End Sub. This assumes that your data is in column one and puts the comma-separated list in the first row of the second column.

2007-09-21 19:01:29 · answer #1 · answered by Keith 1 · 0 0

Assuming that your values are in cells A1:A1500,

1) Insert a blank row before row 1. This will move everything down from A1:A1500 to A2:A1501

2) Highlight all of the values you want to transpose (do not highlight the whole column, just drag across the individual values)

3) Copy this to the clipboard

4) Right-click on the number "1" to highlight the entire row 1

5) Click on "Paste Special." In the box that appears, check "Transpose" and click OK

6) Now you have all of your values across row 1 as well as down column 1. Now delete all of the values down the column, and keep the values across row 1.

7) Save this as a comma-delimited text file. Click File>Save As, and select comma-delimited (.csv) file. Save it on your desktop.

8) Go to your desktop, and change the name to something that ends in .txt

9) Open the file with a text editor instead of Excel.

10) Voila!

2007-09-23 16:26:06 · answer #2 · answered by merlot7799 3 · 0 0

Save the file as text.
Open the file with Word.
Hit Ctrl+H.
Type ^p in the find what box.
Type a comma followed by a space in the replace with box.
Hit Replace all.
Hit Ctrl+A.
Go back to Excel.
Double-click a blank cell.
Hit Ctrl+V.
Done.

2007-09-22 01:43:01 · answer #3 · answered by Secret Agent of God (BWR) 7 · 1 0

fedest.com, questions and answers