Hi guys,
I`m copying fields from excel to attachmate, I need to go to next loop if the value already exists in attachmate.
I`m copying fields from excel to attachmate, I need to go to next loop if the value already exists in attachmate.
Code:
Dim Row As Long
With xlApp.ActiveSheet
Set MyRange = .Range("A1:A65536").Resize(xlApp.CountA(.Range("A1:A65536")))
Set MyRange2 = .Range("B1:B65530").Resize(xlApp.CountA(.Range("B1:B65530")))
End With
For Row = 1 To MyRange.Rows.Count
Sess0.Screen.PutString MyRange.Rows(Row).Value, 7, 4 * insert first string from column A in excel
Sess0.Screen.WaitHostQuiet 30
Sess0.Screen.SendKeys "<ENTER>"
If Sess0.Screen.GetString(20,2,8) = "SVIP210E" Then * here if the string already exist i need to go to the next row in loop
End If
Sess0.Screen.WaitHostQuiet 30
Sess0.Screen.PutString MyRange2.Rows(Row).Value, 8, 33 * enter another string from column B in excel
Sess0.Screen.SendKeys "<ENTER>"
Sess0.Screen.WaitHostQuiet 30
Sess0.Screen.SendKeys("<PF3>")
Sess0.Screen.WaitHostQuiet 30
Next Row
End Sub