Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / General 2 / June 2007

Tip: Looking for answers? Try searching our database.

IS NULL

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
SIN - 28 Jun 2007 22:04 GMT
HI,
the if statement not execute .

the code:
v_checkvalue = xlRng.Value

If IsNull(v_checkvalue) = true Then
              MsgBox "null" & v_row & ""
              GoTo nextrow
End If

even when the value is null this code not working.

thanks.
Daniel - 28 Jun 2007 23:00 GMT
Are you sure your value is null?

There is difference between Null and "".

Perhaps this would work in your case
v_checkvalue = xlRng.Value

If IsNull(v_checkvalue) = true or v_checkvalue=""  Then
              MsgBox "null" & v_row & ""
              GoTo nextrow
End If
Signature

Hope this helps,

Daniel P

> HI,
> the if statement not execute .
[quoted text clipped - 10 lines]
>
> thanks.
SIN - 28 Jun 2007 23:14 GMT
THANKS.
i was sure becuse the message print only the word "null".

> Are you sure your value is null?
>
[quoted text clipped - 22 lines]
> >
> > thanks.
Dirk Goldgar - 28 Jun 2007 23:05 GMT
> HI,
> the if statement not execute .
[quoted text clipped - 8 lines]
>
> even when the value is null this code not working.

Is v_checkvalue a Variant?  If it is, and the MsgBox statement isn't
executed even when you *think* the value is Null, then I suspect the
value isn't really Null.  There are other possible "blank" values that
aren't Null.  Maybe it's a zero-length string, or even Empty, instead.

Set a breakpoint in the code, at the If statement.  When it stops there,
let your mouse pointer hover over v_checkvalue, and see if the tooltip
tells you that the value is something other than Null.

Signature

Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.