Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I am a newbie at writing macros for excel, so bare with me. I need to
write a macro that looks for a character at the beginning of a line. If the a certain character exists, lets say capital A, I need to go to the end of the line and insert another character before the carriage return. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
If you're looking at text in a cell (G9 for example's sake)
If Left(Range("G9",1)="A" Then Range("G9")=Range("G9") & "X" End if note that in VB, "A" is not the same as "a". If you have the text in a variable, as myText, then: If Left(myText,1)="A" Then myText=myText & "X" End if " wrote: I am a newbie at writing macros for excel, so bare with me. I need to write a macro that looks for a character at the beginning of a line. If the a certain character exists, lets say capital A, I need to go to the end of the line and insert another character before the carriage return. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
copy of excel file not showing formulal/function in the function b | Excel Discussion (Misc queries) | |||
LINKEDRANGE function - a complement to the PULL function (for getting values from a closed workbook) | Excel Worksheet Functions | |||
Excel - User Defined Function Error: This function takes no argume | Excel Programming | |||
Need to open the Function Arguments window from VBA for a user defined function. | Excel Programming | |||
Emulate Index/Match combo function w/ VBA custom function | Excel Worksheet Functions |