Please refine this to use lowercase instead of Proper

  • Thread starter Thread starter Solutions Manager
  • Start date Start date
S

Solutions Manager

I have the following bit of code that works great for Proper case, but
doesn't work for Lowercase. I have tried LCase, vbLowerCase, Lower.... and it
doesn't work. Can this be adjusted?

Sub case_TEST()
Application.ScreenUpdating = False
ActiveWorkbook.Sheets("manifest").Select
Range("A2:Y201").Value = Application.proper(Range("A2:Y201").Value)
Application.ScreenUpdating = True
End Sub
 
Have you tried

Range("A2:Y201").Value = Application.lcase(Range("A2:Y201").Text)

I can't test it now, so let me know.
 
Change From:
Range("A2:Y201").Value = Application.proper(Range("A2:Y201").Value)

To:
Range("A2:Y201").Value = Lower(Range("A2:Y201").Value)
 
Ddisregard the other and Change From:
Range("A2:Y201").Value = Application.proper(Range("A2:Y201").Value)

To:
Range("A2:Y201").Value = LCase(Range("A2:Y201").Value)
 
so far the presented solutions from everyone have not worked. I get object
not supported and variable not defined errors. It really seems like this
should work. Thanks for the help though...
 
I have days like this. You can't change a range of cells in block. You have
to use a loop to do it. Try this:

Sub chCase()
For Each c In Range("A2:Y201")
c.Value = LCase(c.Value)
Next
End Sub
 
Thank you. This will work.

JLGWhiz said:
I have days like this. You can't change a range of cells in block. You have
to use a loop to do it. Try this:

Sub chCase()
For Each c In Range("A2:Y201")
c.Value = LCase(c.Value)
Next
End Sub
 
Just be aware that if you have any formulas in the range, they will be wiped
out.

I would revise to this...........

Sub chCase()
For Each c In Range("A2:Y201")
c.Formula = LCase(c.Formula)
Next
End Sub


Gord Dibben MS Excel MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top