Greetings,
1- Open enclosed file.
2- Run Macro1.
After running Macro1 you will see that there is an error on red line...![]()
Please Login or Register to view this content.
Any support will be appreciated.
Greetings,
1- Open enclosed file.
2- Run Macro1.
After running Macro1 you will see that there is an error on red line...![]()
Please Login or Register to view this content.
Any support will be appreciated.
![]()
Sub DontForgetThese() If Your thread includes any code Then Please use code tags... If Your thread has been solved Then Please mark as solved... If Anybody has helped to you Then Please add reputation... End Sub
See if this works for you:
![]()
Please Login or Register to view this content.
If I've helped you, please consider adding to my reputation - just click on the liitle star at the left.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~(Pride has no aftertaste.)
You can't do one thing. XLAdept
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~aka Orrin
When you delete the worksheet, the object variable is disconnected from the object, so there is no ws.Next.
As generally for deleting things, loop backwards:
![]()
Please Login or Register to view this content.
Last edited by shg; 09-08-2014 at 01:13 PM.
Entia non sunt multiplicanda sine necessitate
![]()
Please Login or Register to view this content.
Sorry Harry
You have defined ws as worksheet 1
You then deleted worksheet 1
Then you ask excel to switch to the next worksheet 1.
Yes I can see why you would get an error.
![]()
Please Login or Register to view this content.
Very thanks...Solved...
Hi shg,
There will be any diffrence if I use
instead of![]()
Please Login or Register to view this content.
???![]()
Please Login or Register to view this content.
Yes.There will be any diffrence if I use
The first code will only have a positive match with: "apple"
The second code with have a positive match with: "APPLE", "apple", "Apple", "APPle", etc
Ok..
What is InStr for ?
![]()
Please Login or Register to view this content.
using Instr will return a positive match with: "apple", "aaappleee", "this is an apple", "sappled", etc
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks