Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default Excel Macro to Insert the contents of one column to other

Hello,

I have a worksheet in which my data is arranged as per temp. I have
Temp in one column and the corresponding value in the other. I need to
inser

For eg.
I have
temp 25C in two adjacent columns

i have to make it Temp: 25C

and remove the 25C from that column.

Can I get some help with the Excel Macro for the same.

Dhawal...

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 623
Default Excel Macro to Insert the contents of one column to other

The easiest way would be to simply record the macro. Start the macro recorder
(ToolsMacros...), then execute the commands you need. Stop the recorder, and
save the macro with whatever name you want.

--
Regards,
Fred


"Dhawal" wrote in message
ups.com...
Hello,

I have a worksheet in which my data is arranged as per temp. I have
Temp in one column and the corresponding value in the other. I need to
inser

For eg.
I have
temp 25C in two adjacent columns

i have to make it Temp: 25C

and remove the 25C from that column.

Can I get some help with the Excel Macro for the same.

Dhawal...



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default Excel Macro to Insert the contents of one column to other

That Helps. But the data is uncertain so I have temp in many different
columns. There is more data below temp. I need some help with that.

Regards,
Dhawal



Fred Smith wrote:
The easiest way would be to simply record the macro. Start the macro recorder
(ToolsMacros...), then execute the commands you need. Stop the recorder, and
save the macro with whatever name you want.

--
Regards,
Fred


"Dhawal" wrote in message
ups.com...
Hello,

I have a worksheet in which my data is arranged as per temp. I have
Temp in one column and the corresponding value in the other. I need to
inser

For eg.
I have
temp 25C in two adjacent columns

i have to make it Temp: 25C

and remove the 25C from that column.

Can I get some help with the Excel Macro for the same.

Dhawal...


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 7
Default Excel Macro to Insert the contents of one column to other

That Helps. But the data is uncertain so I have temp in many different
columns. There is more data below temp. I need some help with that.

Regards,
Dhawal



Fred Smith wrote:
The easiest way would be to simply record the macro. Start the macro recorder
(ToolsMacros...), then execute the commands you need. Stop the recorder, and
save the macro with whatever name you want.

--
Regards,
Fred


"Dhawal" wrote in message
ups.com...
Hello,

I have a worksheet in which my data is arranged as per temp. I have
Temp in one column and the corresponding value in the other. I need to
inser

For eg.
I have
temp 25C in two adjacent columns

i have to make it Temp: 25C

and remove the 25C from that column.

Can I get some help with the Excel Macro for the same.

Dhawal...


  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 623
Default Excel Macro to Insert the contents of one column to other

OK. Post the macro you have, then tell us what you need changed. That will be a
lot quicker than having everyone guess what your spreadsheet looks like.

--
Regards,
Fred


"Dhawal" wrote in message
oups.com...
That Helps. But the data is uncertain so I have temp in many different
columns. There is more data below temp. I need some help with that.

Regards,
Dhawal



Fred Smith wrote:
The easiest way would be to simply record the macro. Start the macro recorder
(ToolsMacros...), then execute the commands you need. Stop the recorder, and
save the macro with whatever name you want.

--
Regards,
Fred


"Dhawal" wrote in message
ups.com...
Hello,

I have a worksheet in which my data is arranged as per temp. I have
Temp in one column and the corresponding value in the other. I need to
inser

For eg.
I have
temp 25C in two adjacent columns

i have to make it Temp: 25C

and remove the 25C from that column.

Can I get some help with the Excel Macro for the same.

Dhawal...






  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,365
Default Excel Macro to Insert the contents of one column to other

Try this code - just be sure you're on the sheet you need to change things on
before using it - it works on the currently active/chosen sheet.

Sub CombineTemps()
Dim anyCell As Range

ActiveSheet.UsedRange.Select
For Each anyCell In Selection
If UCase(anyCell.Value) = "TEMP" Then
anyCell.Value = anyCell.Value & ": " & anyCell.Offset(0, 1).Value
anyCell.Offset(0, 1) = ""
End If
Next
End Sub

"Dhawal" wrote:

That Helps. But the data is uncertain so I have temp in many different
columns. There is more data below temp. I need some help with that.

Regards,
Dhawal



Fred Smith wrote:
The easiest way would be to simply record the macro. Start the macro recorder
(ToolsMacros...), then execute the commands you need. Stop the recorder, and
save the macro with whatever name you want.

--
Regards,
Fred


"Dhawal" wrote in message
ups.com...
Hello,

I have a worksheet in which my data is arranged as per temp. I have
Temp in one column and the corresponding value in the other. I need to
inser

For eg.
I have
temp 25C in two adjacent columns

i have to make it Temp: 25C

and remove the 25C from that column.

Can I get some help with the Excel Macro for the same.

Dhawal...



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
error when running cut & paste macro Otto Moehrbach Excel Worksheet Functions 4 August 9th 06 01:49 PM
Dynamic column insert (macro) Chris Excel Discussion (Misc queries) 2 March 15th 06 11:33 AM
TRYING TO SET UP EXCEL SPREADSHEET ON MY COMPUTER MEGTOM New Users to Excel 5 October 27th 05 03:06 AM
MS EXCEL does not let me insert a column sharmila Excel Discussion (Misc queries) 2 August 15th 05 10:29 PM
How do I insert a prompt into an Excel macro? TangoHammer Excel Discussion (Misc queries) 1 August 4th 05 09:31 PM


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