Solved

if else including null and empty record

Posted on 2006-07-09
3
211 Views
Last Modified: 2010-04-06
Hello,

I have an if else statement which works if the record is empty but has a had a record in it before, how can I have this so it can also check for null, as in if spud = "" or null.

 <%
' Show IF Conditional region14
  If (Recmostofuser.Fields.Item("spud").Value) = "" Then
%>

grateful for any help

regards


Kenny
0
Comment
Question by:thatelvis
3 Comments
 
LVL 52

Expert Comment

by:Carl Tawn
ID: 17068901
Try:

    If IsNull(Recmostofuser.Fileds.Item("spud").Value) Or Recmostofuser.Fields.Item("spud").Value) = "" Then
0
 
LVL 26

Accepted Solution

by:
DireOrbAnt earned 125 total points
ID: 17069319
That might not work. If it doesn't try:
If IsDBNull(Recmostofuser.Fileds.Item("spud").Value) Or Recmostofuser.Fields.Item("spud").Value = "" Then
Or try:
If ("" & Recmostofuser.Fields.Item("spud").Value) = "" Then

0
 
LVL 1

Author Comment

by:thatelvis
ID: 17071473
this worked thanks all

If ("" & Recmostofuser.Fields.Item("spud").Value) = "" Then


kenny
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
HTML Video won't Autoplay on site 6 39
Simple Text Web Page rendering differently on IE versus Chrome 3 108
React or Angular? 6 86
Create animated movies for web page 18 118
Preface This article introduces an authentication and authorization system for a website.  It is understood by the author and the project contributors that there is no such thing as a "one size fits all" system.  That being said, there is a certa‚Ķ
Styling your websites can become very complex. Here I'll show how SASS can help you better organize, maintain and reuse your CSS code.
Viewers will learn about the regular for loop in Java and how to use it. Definition: Break the for loop down into 3 parts: Syntax when using for loops: Example using a for loop:
The viewer will learn how to count occurrences of each item in an array.

713 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question