Ok I put the code into new module in thworkbook where the fomr exist, then I put the application.run code into the command button in the workbook where the button exist.
Now I am getting the following error run time error 1004 Method "Run" of object"_Application" failed.
Bookmarks