xlAsyncReturn example

Jul 24, 2011 at 10:32 AM

Interesting project...

Do you have an coding example of how to register an 'xlAsyncReturn' function?

Many thanks...

Jul 24, 2011 at 12:14 PM
Edited Jul 24, 2011 at 1:19 PM

Do now. Thanks for asking. You will need to check out the latest revision from the trunk to get it for now. See xll\test\asynch.cpp. http://nxll.codeplex.com/SourceControl/changeset/view/9181#139508

Jul 24, 2011 at 4:22 PM

Thanks for the super-fast turnaround.  BTW, how often do the the setup and project download files get rebuilt - is it nightly?

Jul 24, 2011 at 4:51 PM

You're welcome. The release mechanism is ad hoc. You can use subversion directly if you want to put that under your control.

The setup includes everything you need to debug the source, but I would encourage you to do a svn checkout and regular updates if you can handle a little entropy.

BTW, I learned that I should not be using ExitThread in a C++ dll that links to the static CRT. Just return 0 and the C++ runtime will take care of things. I've updated async.cpp to do that.

Jul 26, 2011 at 11:25 PM

A single instance of '=XLL.ECHOA(RAND())' - works just fine - but if I add the same function to more than one cell - I immediately get the following error:  

Unhandled exception at 0x765ab9bc in EXCEL.EXE: Microsoft C++ exception: std::runtime_error at memory location 0x0be6fbb0..

Can you reproduce this error at your end?

Jul 27, 2011 at 4:53 AM

Yes. Can you add this to the Issue Tracker tab? I will fix this, but haven't figured out whether or not codeplex allows this by default.

Jul 27, 2011 at 5:10 PM

Fixed. You will need to update from the svn repository or download the zip bundle. Will do more testing and then release to setup.zip.