# Off Topic > Hello..Introduce yourself >  >  run-time error '-2146233080 (80131508)': index was outside the bounds of the array

## Gozer1

Im getting "run-time error '-2146233080 (80131508)': index was outside the bounds of the array" if i run this program more than 11 times with different ipaddr strings. 
is there a temp memory that remembers the first 11 strings of the IP addresses used? It will run again if i use one of the first 11 addresses, or if i close out excel and restart it.
I need a way to clear out the memory so i can use this for several Ip addresses.  




Sub readFromPLC()

    Dim TagAdress As String, iRow As Integer
    Dim ipaddr As String, plc_slot As Integer
    Dim EipCommClient As New EipExcelComm
    ipaddr = vbNullString
    ipaddr = ActiveWorkbook.Worksheets("VarTab").Cells(2, 9).Value
    plc_slot = ActiveWorkbook.Worksheets("VarTab").Cells(3, 9).Value
    EipCommClient.setPlcIPAddress (ipaddr)
    EipCommClient.setPlcSlot (plc_slot)

    iRow = 3
    Do Until IsEmpty(ActiveWorkbook.Worksheets("VarTab").Cells(iRow, 3))
        TagAdress = ActiveWorkbook.Worksheets("VarTab").Cells(iRow, 3).Value
        ActiveWorkbook.Worksheets("VarTab").Cells(iRow, 4).Value = EipCommClient.GetData(TagAdress)
        iRow = iRow + 1
    Loop

    EipCommClient.Close

End Sub

----------


## arlu1201

Hello Gozer1, 

Welcome to Excelforum. Be a part of large Excel community. Enjoy Learning.

----------


## milesvantassel

I am having the same problem with EipCommClient.  11 seams to be the max and EIPCommClient.close does not reset the count.

----------


## Glenn Kennedy

Please read Forum rule 4:
4. Do not post a new help request in an existing thread.

Start your own.  In any event, this thread is 10 years old. The original question didn't get an answer!!  Read the yellow banner (top).  Start your OWN threas and include a smaple file.

----------

