View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
Jacob Skaria Jacob Skaria is offline
external usenet poster
 
Posts: 8,520
Default How do I remove ALT+ENTER in same cell?

Use this formula
=SUBSTITUTE(E14,CHAR(10),CHAR(32))

OR

Use the below macro which works on the active sheet

Sub Macro()
For Each cell In ActiveSheet.UsedRange
If InStr(cell, Chr(10)) < 0 Then _
cell.Value = Replace(cell.Text, Chr(10), Chr(32))
Next
End Sub

If you are new to macros Set the Security level to low/medium in
(Tools|Macro|Security). From workbook launch VBE using short-key Alt+F11.
From menu 'Insert' a module and paste the below code. Save. Get back to
Workbook. Run macro from Tools|Macro|Run <selected macro()

If this post helps click Yes
---------------
Jacob Skaria


"Govindareddy" wrote:

I have hit ALT+ENTER to seperate lines in same cell. I need to remove this -
don't know how to remove this from a saved file.