Results 1 to 2 of 2
  1. #1
    Star Lounger
    Join Date
    Apr 2001
    Location
    new york city
    Posts
    98
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Unique Identifying Number

    <img src=/S/shrug.gif border=0 alt=shrug width=39 height=15> Someone recently asked me if there were a way to mark different sheets of an Excel Workbook with unique identifying numbers, as you might get in Access. Is there a way to do this?

    Meredith Rendall

  2. #2
    Uranium Lounger
    Join Date
    Jan 2001
    Location
    South Carolina, USA
    Posts
    7,295
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Unique Identifying Number

    The following VBA procedure will sequentially number each sheet in the active workbook in cell A1:

    <pre>Public Sub NumberSheets()
    Dim I As Integer
    Dim oCSheet As Worksheet
    I = 1
    For Each oCSheet In Worksheets
    oCSheet.Range("A1") = I
    I = I + 1
    Next oCSheet
    End Sub
    </pre>


    Is that what you want to do?
    Legare Coleman

Posting Permissions

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