Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I'm not sure what you mean by "do this in VB without cell references". You
have to have cell references somehow so that it knows what to format. What did you have in mind? FYI, the convention in this newgroup is to top post. Threads get very messy when there is top and bottom posting. I'm guessing you're using a newsreader that defaults to bottom posting. Barb Reinhardt "Stopher" wrote: On Aug 22, 12:10 pm, OssieMac wrote: Since viewing Barb Reinhardt's reply I now believe that I mis-interpreted what you wanted to do. Barb's reply is the correct one. Regards, OssieMac "OssieMac" wrote: Hi Stopher, Try this and see if it does what you want:- Sub Font_Mix() Dim strTest As String 'String with all characters Dim umPosition As Single 'Position where um starts strTest = "Testum" 'Find start position of characters um umPosition = InStr(1, strTest, "um") 'Assign string to a cell 'NOTE: the font code below does not work with a variable Range("A1") = strTest 'Change font on 1 character starting at position umPosition With Range("A1").Characters(Start:=umPosition, Length:=1).Font .Subscript = True End With End Sub regards, OssieMac "Stopher" wrote: Hi All, How do i add a symbol to text string? I have something like: Text_String = " Text" & Variable & " um" but what i want is the u in the um above to be the micron symbol (.font = "Symbol") on m I was thinking something like: Text_String = " Text" & Variable & len("m").font = "Symbol" & "m" or something like that, with formating the m in the text string itself. Any ideas? Stopher- Hide quoted text - - Show quoted text - Thnx for the replies, but am really trying to do this in VB without cell references, so having a function in a text string that will format one or more letter to a different font. Stopher |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
INTERMIDIATE VALUE OF A CURVE (PRECISION 1 MICRON) | Excel Worksheet Functions | |||
Adding text string to cells | New Users to Excel | |||
Adding Text to a String | Excel Discussion (Misc queries) | |||
the ' symbol ends the SQL string, how do you replace it Excel | Excel Programming | |||
isolating a string containing a % symbol | Excel Worksheet Functions |