excel - find a cell with specific text, multiple occurences, and past active cell in all cells containing specific text -


i working on report, originating in infoview (sap business objects)

this report provides valuable information on weekly basis, enhance awareness of current shop performance.

like tile of post might show want find cell specific text. has multiple occurrences, , want past selected cell in of instances.

i can reach same result ctrl-f, "search all" ( "specific text") , paste (the selected cell) ( http://www.extendoffice.com/documents/excel/816-excel-select-cells-with-specific-text.html) automate this.

i want use:

    cells.find(what:="[ö]", after:=activecell, lookin:=xlformulas, lookat:= _     xlpart, searchorder:=xlbyrows, searchdirection:=xlnext, matchcase:=false _     , searchformat:=false).activate 

and

      cells.findnext(after:=activecell).activate 

but can't incorporate 2 in 1 macro gives me result describes above.

the selected cell contains formula, containing index(match) , reference cell on same row "specific text". in opinion way of doing stuff saves me lot of trouble dynamic cell references ect.

i hope can help

your request little vague, believe started

dim pastevalue string 'this you're pasting in dim ws worksheet dim firstcell string dim rng range  pastevalue = 'do here value  set rng = cells.find(what:="[ö]", lookin:=xlformulas, lookat:= xlpart, _     searchorder:=xlbyrows, searchdirection:=xlnext, matchcase:=false, _     searchformat:=false) while not rng nothing    'make sure found   if len(firstcell) = 0      firstcell = rng.address    'save spot off don't keep looping   end if   rng.value = pastevalue   'now find next 1   set rng = cells.find(what:="[ö]", lookin:=xlformulas, lookat:= xlpart, _       searchorder:=xlbyrows, searchdirection:=xlnext, matchcase:=false, _       searchformat:=false)   if rng.address = firstcell  'back @ first cell     set rng = nothing              'so out of loop   endif end while 

Comments

Popular posts from this blog

Payment information shows nothing in one page checkout page magento -

tcpdump - How to check if server received packet (acknowledged) -