PC Review


Reply
Thread Tools Rate Thread

C# Form exposed to Excel does not like CalculateAll (F9)

 
 
pinkfloydfan
Guest
Posts: n/a
 
      29th Jul 2008
Hi all

I have a very strange problem / bug here that I was wondering if
anybody had come across before.

(Using Visual C# Express 2008, .Net 3.5, Excel 2003
All public static functions are exposed (and working) in Excel via
ExcelDna)

In addition to the functionality I have got working, I have a Form
written in C# that is accessed via the CommandBar. This form takes an
input of a target cell, the value of which will depend upon the output
of one of my UDFs.

When the OK button is pressed the following occurs:
1) the various settings in the classes behind this functions are
changed one at a time by a set amount
2) the worksheet is recalculated
3) the new value in that target cell is recorded
4) reset the changed value, repeat 1) to 3) for all the settings and
output all the results elsewhere

Now comes the strange part: it all works fine as long as I have never
previously pressed F9 or Ctrl-Alt-F9. Pressing Shift-F9 has no impact:
the results are displayed as expected but if I have pressed F9 any
time prior during this session of Excel, then while it appears to work
the results show no changes to the target cell's values.

Is there any reason why pressing F9 prior to running this Form (and
thereby the functionality it uses in C#) should mean that I don't see
any change in results?

I am totally stuck on this one and would really appreciate any
guidance you can give.

Thanks a lot
Lloyd
 
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
Two assholes exposed Adam Albright Windows Vista General Discussion 12 10th Jun 2008 04:37 AM
Base class members are not exposed in Excel using Web Service =?Utf-8?B?WW9K?= Microsoft Excel Programming 0 29th Jan 2007 04:05 PM
Exposed! v1.5 or An Equivalent?? Zo Freeware 10 18th Apr 2004 01:53 PM
Exposed Debbie Bullock Freeware 6 11th Dec 2003 09:00 PM
Exposed password Ruth Tucker Microsoft Access Security 0 4th Sep 2003 11:12 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 10:37 AM.