Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Hi everybody, this is probably not the most challenging question for you, but still don't know how to do it (Newbie). I have a little Macro, that counts lines with certain Elements in logfile: Code ------------------- Sub LogDateiLesen() Dim zeile, anz ' zeile means line Open "C:\Log.txt" For Input As 1 While Not EOF(1) Line Input #1, zeile If InStr(zeile, "ELEMENT") 0 And InStr(zeile, "pubid-601311277") 0 Then anz = anz + 1 Wend Close Cells(5, 4) = anz 'cell D5 End Su ------------------- Now, instead of ELEMENT as one of the criteria above, I would like t have the _content_of_the_cell_A3__of the active worksheet as criteria. PLUS this content shall be followed by an additional space. So I guess I have to define a variable....? How do I have to put it into that code?? THANKS SO MUCH!!! JVLenno -- JVLenno ----------------------------------------------------------------------- JVLennox's Profile: http://www.excelforum.com/member.php...fo&userid=3250 View this thread: http://www.excelforum.com/showthread.php?threadid=56307 |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Variable Macro | Excel Discussion (Misc queries) | |||
Macro prompts for a number to be used in this macro as a variable | Excel Programming | |||
Running a variable macro when any value is entered into a variable cell | Excel Programming | |||
Macro Creating Variable and using variable in a SQL statement | Excel Programming | |||
using one macro to set a variable in another | Excel Programming |