Hi,
Is "mercy" the name of the sub routine or the function, or is a named range in the workbook?
It would help if you can elaborate a little on what want you are trying to do.
Ok, if you just want to remove a named range you do not need to do it in VBA. Here is how you can do it
.
In Excel main page (for Excel 97-2003) click Insert > Name > Define, then look in the list for "mercy", select it and click the Delete button. This will delete this range from the workbook, but you will need to correct all references to that name which will start showing an error because the name does not exists anymore.
Hope this helps. Let me know if you have any questions.
BS Degree in Engineering
20 years experience in Excel programming and various major applications.
It could be a sub, or function, or even a text entry in one of the cells or cell formulas. I can help you locate it, but can you please tell me what is the purpose of this exercise, do you just want to delete all instances of the word wherever it occurs in that workbook.
If you want me to remove it for you, you can send me the file through www.wikisend.com then when you get the 'Download Link' copy it and paste it in your reply here.
Thanks for the accept.
http://wikisend.com/download/600428/HPPD - RN LPN fix mercy.xls
I would also like to know how to proceed with this issue as well if that is possible.
I got the file, thanks.
Ok, there is no "mercy" in the named ranges, but there are plenty of cells that have the word "mercy", and that word also exists in several VBA modules.
So please let me know what exactly do you want me to do with this word, i.e. delete it and leave blank in its place, or replace it by another word , or what.
Also I will need to have the password as some sheets are protected.
When the program runs I no longer want the mercy code to be read, that site is no longer operational and no longer do we need to track.
the password ierh. sorry this has been given to me and I am still new at vba.
Ok, here you go:
http://wikisend.com/download/910116/HPPD%20-%20RN%20LPN%20fix%20mercy%20XYZ.xls
I have replaced all instances of "Mercy" in the all the worksheets by the word "XYZ"
and
I have replaced all instances of "Mercy" in all the VBA module to the "ZYX" (i.e the reverse of XYZ).
That way the code will lose any connection to the cells that have now XYZ in them. And at the same time you can keep track where the word Mercy used to be, both in the worksheets and the code (note: with these changes the codes may not run as or do what they were intended to)
I hope this is what you wanted to do. If not please let me know and we can look at it again.
Thank you again for the accepts and please feel free to get back to me if you need further assistance.