> Question about graphics use in MetaCard.
>
> Our current CBT effort has resulted in a 12mb MetaCard stack.
> The majority of the 12mb is graphics (bmps & gifs).
>
> Is it possible to not import the images into the stack and modify our
> stack directory to have a 'images' sub-directory where we can keep all
> the images? Or, do I have to import all the graphics into the stack?
>
> The problem becomes the path statement. If I don't import the graphic to
> the stack, it puts a path statement in for the graphic. This is fine for
> development purposes, but when we move our final 'runtime' to the
> machine it will be on, that path statement errors out, because it does
> not exist on the delivery machine.
>
> This particular 'lesson' we just completed is one of the smallest ones,
> so we must be able to separate the images from the stack.
>
> Has anyone else run into this problem? Or, am I approaching it wrong?
You can set the "fileName" property of the image to a relative path
(e.g., just the filename itself with no leading path). It will then
look for the image starting at the current directory (you have to be
careful not to set the "directory" property if you do this).
You could also keep a list of all the images used in your stack (e.g.,
in a custom property) and then reset the fileName property to a new
full path in a preOpenStack handler.
Regards,
Scott
> --
> v/r,
> Don Barnhart
> barney@visicom.com (work) VisiCom Laboratories, Inc.
> 904-438-9400 41 N. Jefferson St. Suite 100
> http://www.gulf.net/~barnhart Pensacola, FL 32501
> barnhart@gulf.net (home)
>
***************************************************************
Scott Raney raney@metacard.com http://www.metacard.com
Tcl and ksh: syntactic gymnastics
MetaCard: it does what you think