Re: Interaction with office programs

From: Thane Hubbell (thaneh_at_softwaresimple.com)
Date: 12/26/03


Date: 26 Dec 2003 06:24:31 -0800

thaneh@softwaresimple.com (Thane Hubbell) wrote in message news:<bfdfc3e8.0312251718.34bf7245@posting.google.com>...
> "Peter E.C. Dashwood" <dashwood@enternet.co.nz> wrote in message news:<3fea0b98_4@news.athenanews.com>...
> > "Thane Hubbell" <thaneh@softwaresimple.com> wrote in message
> > news:bfdfc3e8.0312241258.f9538cd@posting.google.com...
> > >
> > > There are some differences between the versions for NT vs 9x you need
> > > to be aware of - the limited 64K object pool under 9x.
> > >
> > I have been using this stuff for years and was NOT aware of this
> > "limitation".
> >
> > What makes you think that a user "needs to be aware" of it, Thane?
> >
> > How does it manifest itself as a problem and under what circumstances?
> >
> > Pete.
>
> Please see this link:
>
> http://support.microsoft.com/?kbid=247412
>
> And then specifically this text:
>
> Transferring data cell by cell can be a perfectly acceptable approach
> if the amount of data is small. You have the flexibility to place data
> anywhere in the workbook and can format the cells conditionally at run
> time. However, this approach is not recommended if you have a large
> amount of data to transfer to an Excel workbook. Each Range object
> that you acquire at run time results in an interface request so that
> transferring data in this manner can be slow. Additionally, Microsoft
> Windows 95 and Windows 98 have a 64K limitation on interface requests.
> If you reach or exceed this 64k limit on interface requests, the
> Automation server (Excel) might stop responding or you might receive
> errors indicating low memory. This limitation for Windows 95 and
> Windows 98 is discussed in the following Knowledge Base article:
> 216400 PRB: Cross-Process COM Automation Can Hang Client Application
> on Win95/98
>
>
> And the link to that article is:
>
> http://support.microsoft.com/default.aspx?scid=kb;EN-US;216400
>
> The specific manifestation - and it's ugly:
>
> SYMPTOMS
> When automating an out-of-process COM server from a client
> application, if the client code enters a tight loop or makes extensive
> requests for obtaining new interfaces, the client application might
> hang during an automation call, requiring the user to terminate the
> process abnormally. Once hung, any COM request involving a marshaled
> interface fails. A reboot is required to clear the problem.
>
> The problem only occurs on Windows 95 and Windows 98 systems.
>
> **** This is certainly something any programmer should be aware of.

One additional follow up tip. Use the Release method against any
selection object you obtain when you are finished. In fact, use the
Release method for each interface (object reference) obtained when you
are finished. I found through experience that under Windows 9x this
limitation can be reached without being in a tight loop but instead
just by not releasing references no longer used. I do not *KNOW* that
Fujitsu calls the Release method if the reference is set to Null.
Since Fujitsu COBOL does know that the object is an OLE object - it
might.



Relevant Pages

  • Re: 7.0 wishlist?
    ... The "auto-implement" is intended mainly for the odd situation where an existing class you can't edit fits some interface and you're willing to take responsibility for it if it turns out not to actually adhere to the contract, and try using it where that interface type is expected. ... If reference declarations started showing up with the odd asterisk, bang, or other punctuation mark on it, but never primitive declarations, people would probably be able to guess what was going on, on the basis of "what other binary flag might be set on references but not primitives and would be really useful besides can be/cannot be null?" ... the compiler cannot prove by static analysis that the RHS isn't null might be a good idea. ... Object foo, bar; ...
    (comp.lang.java.programmer)
  • Re: Anders Hejlsberg comment on immutable objects
    ... >explicit interface implementation exists is so an interface name can class ... Improper implicit conversions constitute a nasty ... >> With value types, the variable's value is the object, not a reference ... Consider the affects of our different views on a const ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Nautilus in FC2 opens too many windows when browsing
    ... > I hardly ever use Nautilus, I prefer CLI, so I haven't followed it's ... > Windows would think that opening a million windows would be a good thing. ... > Instead they went back to a primitive Windoze style interface. ... contents view pane in "explore" mode in addition to the "open" mode which is ...
    (alt.os.linux.redhat)
  • Re: please try this program (generic resolution)
    ... of the specific interfaces of a generic interface that has that name and ... either is in the scoping unit in which the reference appears or is made ... And now in my example I misspelled ENISOC. ... external fun ...
    (comp.lang.fortran)
  • Re: Using early-bound interface on a late-bound object
    ... > the compiler determines which interfaces to use, ... > supports the declared interface. ... >> help if someone can point me to some authoritative document or reference ... within customer shops when they mirrored this 'division' to keep their ...
    (microsoft.public.vb.general.discussion)