View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Mel Wasko via OfficeKB.com Mel Wasko via OfficeKB.com is offline
external usenet poster
 
Posts: 2
Default Thorough deletion of cell contents

I am using an Excel macro to format a file for import into another program.
The file is ultimately saved as a .csv file. Since a range of cells needs
to have the information deleted before it can be imported I have written
the following: Selection.Clear. However, when I try to import this file
the host program is seeing something there and kicking it back. If I open
the .csv file and select the cells in question and press the delete key,
save and close, the file imports with no problem.
MY QUESTION IS, what code can I use instead of ?Selection.Clear? that will
more accurately duplicate what happens when I press the delete key? (When
you record a macro and look at the code pressing the delete key results in
the command ?Selection.ClearContents? ? this, however, results in the same
problem)

--
Message posted via http://www.officekb.com