Test or check if sheet exists

Some folk dislike this approach because of an “inappropriate” use of error handling, but I think it’s considered acceptable in VBA… An alternative approach is to loop though all the sheets until you find a match.

How to fill color in a cell in VBA?

Non VBA Solution: Use Conditional Formatting rule with formula: =ISNA(A1) (to highlight cells with all errors – not only #N/A, use =ISERROR(A1)) VBA Solution: Your code loops through 50 mln cells. To reduce number of cells, I use .SpecialCells(xlCellTypeFormulas, 16) and .SpecialCells(xlCellTypeConstants, 16)to return only cells with errors (note, I’m using If cell.Text = “#N/A” … Read more

How to install Date Picker form control in Excel 2016

I use Excel from Office 365 and want to use date picker form. Unfortunately, it is not listed in the list of additional controls (More Controls). How to include it into spreadsheet that I am developing? Is there something that I need to download and install?

How to install Date Picker form control in Excel 2016

I use Excel from Office 365 and want to use date picker form. Unfortunately, it is not listed in the list of additional controls (More Controls). How to include it into spreadsheet that I am developing? Is there something that I need to download and install?

Row count where data exists

If you need VBA, you could do something quick like this: This will print the number of the last row with data in it. Obviously don’t need MsgBox in there if you’re using it for some other purpose, but lastRow will become that value nonetheless.

Adding a newline character within a cell (CSV)

This question was answered well at Can you encode CR/LF in into CSV files?. Consider also reverse engineering multiple lines in Excel. To embed a newline in an Excel cell, press Alt+Enter. Then save the file as a .csv. You’ll see that the double-quotes start on one line and each new line in the file … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)