LauraEFord
New Member
- Joined
- May 13, 2014
- Messages
- 5
I have macro in VBA that uses a data set in excel. Then it filters all but one specific vendor. Everyone else is removed from that data set. Unfilter. Then I'm left with headers only and no data lines (line 2 and below) or I'm left with header data and data in lines 2 and usually more.
Then I have the following.
Dim MyRange as range
Dim FindThis as String
FindThis = "VENDOR's NAME"
Set MyRange = Range ("B2:B65536").Find(What:=FindThis)
If MyRange is Nothing Then
Else
Save the file as Vender.xlsx
Attaches to email etc
End if
If it comes to one of the vendors that is not in the data set, then it just spins and does nothing. So yesterday, i got 6 files and emails and then it stops.
Then I have the following.
Dim MyRange as range
Dim FindThis as String
FindThis = "VENDOR's NAME"
Set MyRange = Range ("B2:B65536").Find(What:=FindThis)
If MyRange is Nothing Then
Else
Save the file as Vender.xlsx
Attaches to email etc
End if
If it comes to one of the vendors that is not in the data set, then it just spins and does nothing. So yesterday, i got 6 files and emails and then it stops.
Last edited: