Win98 loses path
Thomas J McGrath III
3mcgrath at adelphia.net
Wed Jan 7 11:19:38 EST 2004
I hope someone can help me on this one. I designed a CD to run on Mac
OS9/OSX and Windows 2000/XP. But a lot of users are telling me they
have Win 98 and although some of the CD works there is a rather big
problem on 98. The following scripts do work in 2000 and XP but not in
98. I put the development "fix" in so it can work from the location of
my images folder.
The problem is in the relative path that displays my images.
In my main stack I reference - media/Slide10.png - which is in my media
folder with my final build. (These images do show up when referenced in
the property inspector as ' media/Slide10.png ' etc. ) Then I have
buttons over this image that open a substack based upon what the slide
states. When the substack opens I then have this script to load what
ever images are in a corresponding folder for this substack. (These
images don't show up in 98 but do on all the other platforms listed
below)
So if card one in main stack has a button that opens substack "31i"
then I have a sub folder named "31i" and in it I have my png slide
images.
Well the images do not appear in 98 but do work in 2000 and XP home and
XP Pro. They work fine in OS9 and OSX (3.x).
What could be different about the defaultFolder in 98? Does anyone know?
This script is in my card script in each substack.
- snip-
global the_path, totalimages, currentimage, theimages -- theimages
holds the list of images in the folder
if the environment is "Development" then
set the itemdel to "/"
get the effective filename of this stack
delete item -1 of it
put it & "/media/31i/" into the_path -- folder "31i" has the images
in my "media" folder
put the directory into altdir
set the directory to the_path
put the files into theimages
set the directory to altdir
else
put the directory into altdir
put defaultFolder & "/media/31i/" into the_path
set the directory to the_path
put the files into theimages
set the directory to altdir
end if
This is in my openCard script:
-snip-
set the filename of image "slide" to the_path & line currentimage of
theimages
this script is in my next button -- I have similar scripts in my
Previous button and "home" button.
-snip-
global the_path, totalimages, currentimage, theimages
if currentimage < totalimages then
put currentimage + 1 into currentimage
else
put 1 into currentimage
end if
lock screen
set the filename of image "slide" to (the_path & line currentimage of
theimages)
Macintosh PowerBook G-4 OSX 10.3.1, OS 9.2.2, 1.25 GHz, 512MB RAM, Rev
2.1.2
Advanced Media Group
Thomas J McGrath III • 2003 • 3mcgrath at adelphia.net
220 Drake Road, Bethel Park, PA 15102
More information about the use-livecode
mailing list