Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 80
Default check for #N/A

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
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 638
Default check for #N/A

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


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default check for #N/A

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
  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 638
Default check for #N/A

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
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
make a check form, and then have info go to a check register richie g Excel Worksheet Functions 0 May 5th 10 12:10 AM
Copy and move check box (check boxes) with new cell link? Marty Excel Worksheet Functions 1 January 20th 10 07:43 PM
Increase size of a Forms Check Box (click on to enter check mark) 718Satoshi Excel Discussion (Misc queries) 0 August 17th 07 01:52 AM
Check if Conditional Format is True or False / Check cell Color Kevin McCartney Excel Worksheet Functions 5 June 29th 07 11:12 AM
Enable check box in protected sheet + group check boxes Dexxterr Excel Discussion (Misc queries) 4 August 2nd 06 12:00 PM


All times are GMT +1. The time now is 01:56 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"