Results 1 to 4 of 4

Use of Variable

Threaded View

  1. #1
    Registered User
    Join Date
    02-23-2012
    Location
    Helsinki, Finland
    MS-Off Ver
    Excel 2010
    Posts
    2

    Use of Variable

    I'm wondering how I can use variable here:

    Sub Delete_Till()
    Dim Del_Till As Integer
    Del_Till = Range("h1").Value
    Rows("2:100").Delete Shift:=xlUp
    End Sub

    I need use variable value instead of ex. 100 above.
    This does not work:

    Sub Delete_Till()
    Dim Del_Till As Integer
    Del_Till = Range("h1").Value
    Rows("2:Del_Till").Delete Shift:=xlUp
    End Sub

    -Thank, Jackie
    Last edited by JackieJag; 02-23-2012 at 12:39 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1