Login | Register   
RSS Feed
Download our iPhone app
Browse DevX
Sign up for e-mail newsletters from DevX

By submitting your information, you agree that devx.com may send you DevX offers via email, phone and text message, as well as email offers about other products and services that DevX believes may be of interest to you. DevX will process your information in accordance with the Quinstreet Privacy Policy.

Tip of the Day
Language: Visual Basic
Expertise: Beginner
Jan 3, 2001



Application Security Testing: An Integral Part of DevOps

Another Way of Handling Null Database Fields

A compact way of handling null database fields is as follows:
txtText1.text = Format(rs!Field)

If rs!Field is null, Format(rs!Field) will resolve to an empty string. Otherwise the value in the recordset field will be entered into the text box. This behavior of Format() is rarely noticed but is useful because it makes code simpler to read.
Stuart Hallows
Comment and Contribute






(Maximum characters: 1200). You have 1200 characters left.



Thanks for your registration, follow us on our social networks to keep up-to-date