View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
ZeroCool127 ZeroCool127 is offline
external usenet poster
 
Posts: 1
Default How can I copy range's style to another in Excel?

Hi everybody,

I have a problum that I selected a range on Excel worksheet, and inserted
another range on the same worksheet, now I wanna copy the selected range's
style to the inserted one, I use

insertedRange.Style = selectedRange.Style;

or

insertedRange.Cells.Style = selectedRange.Cells.Style;

both of the two works not correctly, what is the mistake?


--
If you enter this world knowing you are loved and leave this world knowing
the same, then everything that happens in between can be dealt with.