Results 1 to 6 of 6

Messed up code :-/

Threaded View

  1. #1
    Registered User
    Join Date
    10-15-2012
    Location
    Birmingham
    MS-Off Ver
    Excel 2003
    Posts
    81

    Messed up code :-/

    Below is a code I've tried to alter the change values in certain cells in sheets with the same prefix to proper case ...

    Can anyone advise where I've gone wrong ??

    Thanks

    James

    Public Sub Proper_Case()
    Dim SH As Worksheet
    Dim rng As Range
    Dim rCell As Range
     
    Set rng = ActiveWorkbook.Sheets("Control").Range(ws.Name Like "PP*")
    For Each SH In ActiveWorkbook.Worksheets
    If Not IsError(Application.Match(SH.Name, rng, 0)) Then
    Range("B5").Select
    ActiveCell = WorksheetFunction.Proper(ActiveCell.Value)
    Range("I5").Select
    ActiveCell = WorksheetFunction.Proper(ActiveCell.Value)
    End If
    Next SH
    End Sub
    Last edited by james 35; 03-07-2013 at 05:30 AM.

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