X
xentheon
Hello I would like to be able to loop through all values in row a, find
all that have a hyperlink present and then copy these values into a new
worksheet.
This is what i have so far:
Sub SameData()
Dim n As Integer, i As Integer
Dim int_Unit As Integer
int_Unit = Sheets("Industry").UsedRange.Rows.Count
n = 1
Do While Not IsEmpty(Sheets("Industry").Cells(n, 1))
For i = 1 To int_Unit
If Sheets("Industry").Cells(n, 1) = ActiveCell.Hyperlinks.Count
Then
Sheets("newsheet").Cells(n, 2) = Sheets("Industry").Cells(i,
1)
End If
Next i
n = n + 1
End Sub
The error i get is 'Do without Loop' could someoen improve this code to
do what i think is essentially a simple code.
thank you
all that have a hyperlink present and then copy these values into a new
worksheet.
This is what i have so far:
Sub SameData()
Dim n As Integer, i As Integer
Dim int_Unit As Integer
int_Unit = Sheets("Industry").UsedRange.Rows.Count
n = 1
Do While Not IsEmpty(Sheets("Industry").Cells(n, 1))
For i = 1 To int_Unit
If Sheets("Industry").Cells(n, 1) = ActiveCell.Hyperlinks.Count
Then
Sheets("newsheet").Cells(n, 2) = Sheets("Industry").Cells(i,
1)
End If
Next i
n = n + 1
End Sub
The error i get is 'Do without Loop' could someoen improve this code to
do what i think is essentially a simple code.
thank you