×
Create a new article
Write your page title here:
We currently have 3,189 articles on s23. Type your article name above or create one of the articles listed here!



    s23
    3,189Articles
    < Vba
    • Sub matchRouterNames_RoutersTab_RCLDump_MGTIP()

    Worksheets("RCL.Dump").Select

    For y = 2 To 6

    RouterName = Range("Routers!A" & y).Value & "-BVI1" Range("A1").Select

       Set x = Range("A:A").Find(What:=RouterName, After:=ActiveCell, LookIn:=xlValues, _
           LookAt:=xlPart, SearchOrder:=xlByColumns, SearchDirection:=xlNext, MatchCase:=Falce)
       If x Is Nothing Then
    

    Range("Routers!C" & y).Value = "not Found"

       Else
           Cells(x.Row, x.Column).Select
           FoundRow = x.Row
           Range("Routers!C" & y).Value = Range("B" & FoundRow).Value
       End If
    

    Next y

    Worksheets("Routers").Select
    

    End Sub

    this macro will get an index from one sheet, try to find it on another sheet and then will copy info back to the main sheet.


    sorry if that makes no sence i will clean it up when i have the time.

    Cookies help us deliver our services. By using our services, you agree to our use of cookies.
    Cookies help us deliver our services. By using our services, you agree to our use of cookies.