Solved

if else including null and empty record

Posted on 2006-07-09
3
182 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

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

It's sometimes a bit tricky to use date functions in Oracle BPEL. I'll explain quickly how you can add N days to the current date. In a BPEL process this can be useful, and you can adapt it to fit your needs. First of all, let's see how to add 1 …
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:
Viewers will learn about basic arrays, how to declare them, and how to use them. Introduction and definition: Declare an array and cover the syntax of declaring them: Initialize every index in the created array: Example/Features of a basic arr…

708 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

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now