Monthly Archives: September 2008

Automatically Protect/UnProtect All Worksheets

Tonight I want to automatically protect and unprotect all Microsoft Excel Worksheets in my Workbook with password, instead of doing it manually, I put these following Excel VBA macro code in my Workbook. Public Sub ProtectAllSheets() Dim objSheet As Worksheet … Continue reading

Posted in Workbook and Worksheet | Tagged , , , , , , , | 4 Comments

How To Hide an Excel Worksheet

Some time we want to hide a certain Excel Worksheet from view, and it’s a common practice to use select the Worksheet, go to menu Format > Sheet > Hide. Using the method explained above is right, but unfortunately, others … Continue reading

Posted in Workbook and Worksheet | Tagged , , , , , , , , , , , , , , , , , , , , , , , , | 7 Comments

Create New Excel Worksheet With VBA

The Excel VBA macro below will create a new Excel Worksheet called ‘RawData’ or we can use msgbox to ask for the Worksheet name if needed. If there is already a Worksheet called RawData, user will be ask whether they … Continue reading

Posted in Workbook and Worksheet | Tagged , , , , , , , , , , , , , , | 11 Comments

How To Open Excel File Using Macro

Imagine this condition; We are in the middle of doing something using Excel VBA macro, then we want the macro to automatically show the File Open dialog box to make us (user) able to choose another Excel file to be … Continue reading

Posted in Excel VBA Function | Tagged , , , , , , , , , , , , , | 16 Comments

Changing Microsoft Excel Status Bar

Maybe for some reason we want to change our Microsoft Excel Status Bar, then this simple vba function will do the work for us. The end result will look like this: Ok, to do it, put this following code in … Continue reading

Posted in Excel VBA Function | Tagged , , , | 6 Comments

Handy VBA To Calculate Person Age

This handy VBA procedure is just to show you how we can calculate and display someone Age. To do this, of course we need to know their date of birth first, then simply using datediff and mod vba functions we … Continue reading

Posted in Excel VBA Function | Tagged , , | 13 Comments

Getting Cell Reference With Input Box

We can get an input from user using Input Box, but we also can use the Input Box to get the address of cell reference in Microsoft Excel. Using simple Excel VBA procedure below we can ask user to select … Continue reading

Posted in Excel VBA Function | Tagged , , , , , , , | 158 Comments