comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: EGAD! A common block question.......
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: EGAD! A common block question....... [message #30883] Thu, 23 May 2002 09:00 Go to previous message
Pavel A. Romashkin is currently offline  Pavel A. Romashkin
Messages: 531
Registered: November 2000
Senior Member
paul wrote:
>
> I realize common blocks are kind of a nasty subject around here,
> anyway, I'm a newbie to this whole IDL thing, so here is my
> question.......

Allright, caught cheating. How'd you know that common blocks are nasty
if you were so new to IDL and this group? :-)
Anyway, like David said, there's nothing wrong with commons. There may
be a lot of inefficiency though with how one uses them :-)

> I have multiple widget based tools that need to share properties
> (mostly directories and such), my first thought was to create a common
> block that holds a hashtable. Upon initialization, properties are
> read from a file and set in the common block. Also I wanted each tool
> to be able to set its own properties into the common block, therefore,
> the hashtable can grow with each tool initialization. This process
> seems to work fine in the development environment, but not in the
> runtime environment. Any suggestions? Comments? Alternatives?

Again, in this sort of environment one thing I can suggest is trying not
to use common blocks for storing properties of widgets. Use a State
structure. If you are feel like you are up to it, use a State object or
a static shared pointer - if your widgets contain a lot of data to be shared.
Use common block only to pass information about *where* that State is,
not *what* it is.
Good luck,
Pavel
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: give me any advice on volume visualization
Next Topic: Re: suppressing carriage return in PRINT

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Thu Oct 09 03:31:59 PDT 2025

Total time taken to generate the page: 0.87931 seconds