Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Microsoft Office > Excel VBA > Excel VBA
Password Reminder
Register
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Excel VBA Discuss using VBA for Excel programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Excel VBA section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old August 17th, 2006, 10:37 AM
Registered User
 
Join Date: Jul 2004
Location: , MO, USA.
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default "Unable to set the FormulaArray property..."

I hope someone can help me with this. When I manually enter this array formula into a cell using Ctrl-Shift-Enter, everything works fine:

=IF(ISERROR(INDEX('Oct 05 FINAL'!$J$27:$J$1500,MATCH(1,('Oct 05 FINAL'!$C$27:$C$1500=$B4)*('Oct 05 FINAL'!$E$27:$E$1500=$D4),0))),"",INDEX('Oct 05 FINAL'!$J$27:$J$1500,MATCH(1,('Oct 05 FINAL'!$C$27:$C$1500=$B4)*('Oct 05 FINAL'!$E$27:$E$1500=$D4),0)))

But, when I run this same event with code, the following code:

Selection.FormulaArray = "=IF(ISERROR(INDEX('Oct 05 FINAL'!$J$27:$J$1500,MATCH(1,('Oct 05 FINAL'!$C$27:$C$1500=$B4)*('Oct 05 FINAL'!$E$27:$E$1500=$D4),0))),"""",INDEX('Oct 05 FINAL'!$J$27:$J$1500,MATCH(1,('Oct 05 FINAL'!$C$27:$C$1500=$B4)*('Oct 05 FINAL'!$E$27:$E$1500=$D4),0)))"

...DOES NOT WORK. I get an error msg: "Unable to set the FormulaArray property of the Range class"

If I leave off the "IF(ISERROR(..." in my code and run it, it works OK, but not if I include it. I need to have ISERROR so my cells aren't populated with "#VALUE!" or any other error indicators when the values aren't found.

Anybody have the answer?

Thanks,
Randy
Reply With Quote
  #2 (permalink)  
Old August 18th, 2006, 05:48 AM
Authorized User
 
Join Date: Mar 2006
Location: London, , United Kingdom.
Posts: 73
Thanks: 0
Thanked 0 Times in 0 Posts
Default

unfortunatly it may be due to this http://support.microsoft.com/kb/213181/EN-US/

Reply With Quote
  #3 (permalink)  
Old August 18th, 2006, 01:33 PM
Registered User
 
Join Date: Jul 2004
Location: , MO, USA.
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks, jrogers! That's the problem. I'll have to figure a way to get the data another way or use no more than 255 characters!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Unable so assign value to .Lookin Property Colster Excel VBA 1 August 24th, 2007 03:16 PM
Get Set Property value being lost asn187 ASP.NET 2.0 Professional 1 April 19th, 2007 03:09 PM
Set Listbox Selected property DaDeViL VB How-To 7 October 4th, 2006 04:04 PM
Set accountExpires property r_ganesh76 C# 0 August 9th, 2006 01:16 AM
Unable to set image or cursor property, Ch 12. VictorVictor BOOK: Beginning CSS: Cascading Style Sheets for Web Design ISBN: 978-0-7645-7642-3 5 April 26th, 2006 10:49 AM



All times are GMT -4. The time now is 01:49 AM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.