VXCMD_Client_Classic_MC

Chris Sheffield cm_sheffield at yahoo.com
Wed Feb 18 08:30:25 CST 2004


Ken,

What I've done is use the startup handler to check a
couple different things to determine whether to use
standalone or network.  It sets the externals of my
main stack accordingly.  Granted this doesn't work in
the IDE, but it works great for the built app.  It
does require the use of some kind of preferences or
configuration file obviously.  But that way I don't
have to have two separate accessor stacks.

Chris Sheffield
Read Naturally

--- Ken Ray <kray at sonsothunder.com> wrote:
> > Ken, the entry points into externals are
> normalized per API. The 
> > resource name is just an external binder. Try it
> out. Rename 
> > Valentina to Valentina2. Any call to valentina
> will fail. But if you 
> > change your transcripts to use valentina2, they
> should work fine 
> > again. Or so they should :)
> 
> Well, perhaps that works with Classic or Carbon, but
> it doesn't work
> with Mach-O. The reason is that the binding happens
> not as resources
> inside the resource fork of our app, but as DLLs
> that get linked to with
> the "externals" property.
> 
> So the "local" Valentina external is called
> "VXCMD_Macho_MC" and the
> "server" external is called "VXCMD_Client_Macho_MC".
> Both of them get
> calls through the function name "Valentina". So if I
> link both externals
> to the same MC stack, when I call on Valentina(...),
> which external gets
> used? In my experience, MC will pick one over the
> other (I think it goes
> by alphabetical order), but regardless, I can't link
> both externals into
> the same stack. 
> 
> So in my app right now, I have two separate stacks,
> each one linked to
> its own external, and then a login dialog in our
> product determines
> whether the user wants to access a local DB or a
> server-based DB. And
> *then* I connect to the proper stack and are able to
> use the right
> external. But it's a bit of a pain...
> 
> > Ruslan, having to use a different valentina call
> for local and server 
> > activities may actually be a good approach for
> coding.
> > 
> > get valentina ("SqlSelect",dbName,query)
> > get valentina_server ("SqlSelect",dbName,query)
> > 
> > This way it is easy to keep track which code works
> locally and which 
> > works remotely, particularly for programs that
> support both modes in 
> > parallel. While most Valentina functions are the
> same, they are not 
> > exactly the same and server has more of them. It
> is also easy to 
> > switch from local to remote and vice versa.
> 
> I totally agree. :-)
> 
> Ken Ray
> Sons of Thunder Software
> Email: kray at sonsothunder.com
> Web Site: http://www.sonsothunder.com/ 
> 
> 
> _______________________________________________
> Valentina mailing list
> Valentina at lists.macserve.net
> http://lists.macserve.net/mailman/listinfo/valentina

=====
Chris Sheffield
Read Naturally
www.readnaturally.com

__________________________________
Do you Yahoo!?
Yahoo! Mail SpamGuard - Read only the mail you want.
http://antispam.yahoo.com/tools


More information about the Valentina mailing list