PC Review


Reply
Thread Tools Rate Thread

check for #N/A

 
 
=?Utf-8?B?cm9kY2hhcg==?=
Guest
Posts: n/a
 
      6th Sep 2007
Hey all,
in VBA how do i check for #N/A? i keep getting a runtime error when code
tries to read this record that has this value.

thanks,
rodchar
 
Reply With Quote
 
 
 
 
JW
Guest
Posts: n/a
 
      6th Sep 2007
You can use Application.WorksheetFunction.IsNA to search for only #N/A
errors or use VBA's IsError to search for any errors at all.
rodchar wrote:
> Hey all,
> in VBA how do i check for #N/A? i keep getting a runtime error when code
> tries to read this record that has this value.
>
> thanks,
> rodchar


 
Reply With Quote
 
Dave Peterson
Guest
Posts: n/a
 
      6th Sep 2007
Or you could look at the .text property:

if mycell.text = "#N/A" then


rodchar wrote:
>
> Hey all,
> in VBA how do i check for #N/A? i keep getting a runtime error when code
> tries to read this record that has this value.
>
> thanks,
> rodchar


--

Dave Peterson
 
Reply With Quote
 
JW
Guest
Posts: n/a
 
      6th Sep 2007
Good point Dave.

Dave Peterson wrote:
> Or you could look at the .text property:
>
> if mycell.text = "#N/A" then
>
>
> rodchar wrote:
> >
> > Hey all,
> > in VBA how do i check for #N/A? i keep getting a runtime error when code
> > tries to read this record that has this value.
> >
> > thanks,
> > rodchar

>
> --
>
> Dave Peterson


 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Spell check -- text marked skip spelling and grammar check =?Utf-8?B?RGF2aWQgQS4=?= Microsoft Word Document Management 8 9th Aug 2008 11:47 PM
Asp.net Treeview Clientscript - Auto Check Child Notes After Check Parent Node Sylvie Microsoft C# .NET 1 9th Oct 2007 02:25 PM
Treeview Clientscript - Auto Check Child Notes After Check Parent Node Sylvie Microsoft ASP .NET 1 9th Oct 2007 02:25 PM
In outlook get message "Spell check cannot check items...try agai =?Utf-8?B?am1yYW5jaG1hbg==?= Microsoft Outlook Discussion 1 28th Sep 2006 10:26 PM
Xp:Check Disk:Tools:Check Now:Both Options:reboot countdown does not complete? RAS Windows XP General 3 1st Feb 2005 06:23 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:36 AM.