ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   proper (https://www.excelbanter.com/excel-programming/421037-proper.html)

geebee

proper
 
hi,

i have the following:

dim test as string
test = proper(sheets("sheet1").range("A1").value)

but this is not working... i am just trying to assign the Proper(A1) as a
string.

please help

thanks in advance,
geebee


Don Guillett

proper
 

test = proper(sheets("sheet1").range("A1").value)
test = worksheetfunction.proper(sheets("sheet1").range("A 1").value)

--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"geebee" (noSPAMs) wrote in message
...
hi,

i have the following:

dim test as string
test = proper(sheets("sheet1").range("A1").value)

but this is not working... i am just trying to assign the Proper(A1) as a
string.

please help

thanks in advance,
geebee



JE McGimpsey

proper
 
Proper is not a VBA function, it's an XL function. Try:

Dim test As String
test = Application.WorksheetFunction.Proper( _
Worksheets("Sheet1").Range("A1").Text)


In article ,
geebee (noSPAMs) wrote:

hi,

i have the following:

dim test as string
test = proper(sheets("sheet1").range("A1").value)

but this is not working... i am just trying to assign the Proper(A1) as a
string.

please help

thanks in advance,
geebee


Dave Peterson

proper
 

And VBA has its own strconv function, too.

You can read VBAs help for more info.

geebee wrote:

hi,

i have the following:

dim test as string
test = proper(sheets("sheet1").range("A1").value)

but this is not working... i am just trying to assign the Proper(A1) as a
string.

please help

thanks in advance,
geebee


--

Dave Peterson

Chip Pearson

proper
 

VBA has a function name StrConv that allows you to change a string to
various formats:

Dim S As String
Dim InText As String
InText = Range("A1").Text
S = StrConv(InText, vbProperCase)
Debug.Print S

Cordially,
Chip Pearson
Microsoft MVP
Excel Product Group
Pearson Software Consulting, LLC
www.cpearson.com
(email on web site)



On Tue, 9 Dec 2008 07:01:41 -0800, geebee
(noSPAMs) wrote:

hi,

i have the following:

dim test as string
test = proper(sheets("sheet1").range("A1").value)

but this is not working... i am just trying to assign the Proper(A1) as a
string.

please help

thanks in advance,
geebee



All times are GMT +1. The time now is 05:02 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com