LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 102
Default Clear then move text up

I have the following code for clearing an entry on a worksheet:

Dim rng As Range, res As Variant, rng1 As Range
Set rng = Worksheets("B Sheet").Range("b8:b23")


res = Application.Match(CStr(ComboBox1.Text), rng, 0)
If Not IsError(res) Then
Set rng1 = rng(res)
rng1.Offset(0, 5).ClearContents
rng1.Offset(0, 0).ClearContents

What do I need to add to the code to move up the entries in the cells below
the entry I am deleting and within the range ?
I have different data in the cells below B23 so I can't have the text in
those cells move up.I have tried Delete Shift:=xlUp and it just puts messes
up all the cells below the range ("b8:b23").


Cheers
gregork




 
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
clear cell based on text in opposing column [email protected] Excel Worksheet Functions 2 July 14th 08 04:09 AM
clear text Chey Excel Discussion (Misc queries) 1 January 10th 08 12:29 AM
clear the clear the web page email attachment lines MCrider Excel Discussion (Misc queries) 0 November 11th 07 10:05 PM
How do I clear blank space at the top of a word-wrapped text cell? mirage1210 Excel Discussion (Misc queries) 2 February 11th 05 09:19 PM
Clear Contents Of A Text Box In User Form Graham[_5_] Excel Programming 1 April 22nd 04 09:09 AM


All times are GMT +1. The time now is 07:56 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"