A common trick is to check like this:
trim(TextBox1.Value & vbnullstring) = vbnullstring
this will work for spaces, empty strings, and genuine null values
More Related Contents:
- Format Cell Contents
- Excel formula checklist in employees
- How do I put double quotes in a string in vba?
- Excel VBA – How to add dynamic array formula
- How can I URL encode a string in Excel VBA?
- Check if the file exists using VBA
- Compare double in VBA precision problem
- Row count on the Filtered data
- Excel VBA Macro: User Defined Type Not Defined
- Automate IE via Excel to fill in a dropdown and continue
- Run-Time error 1004 Excel 2013
- VBA – Write all possible combinations of 4 columns of data [duplicate]
- Excel VBA to Export Selected Sheets to PDF
- Remove duplicates from array using VBA
- Controlling Internet Explorer local intranet using Excel VBA
- How to automatically insert a blank row after a group of data
- Count unique values in Excel
- Get File Path (ends with folder)
- Get length of array?
- Email a single attachment from folder of files each to a different person
- Bad data selection using VBScript , on date field values
- Sending object array to variant works before August 2019 Windows update, but fails after update
- Find last row in range
- How can I install/use “Scripting.FileSystemObject” in Excel 2010 for MAC?
- Differences between Excel’s Form Controls & ActiveX Controls
- Excel VBA User Defined Function that counts cells with conditional formatting
- How to extract text within a string of text
- How to open a workbook specifying its path
- GET pictures from a url and then rename the picture
- How to protect Excel workbook using VBA?