View Full Version : KB: Creating CD-ROM Browsing Windows

10-03-2003, 11:23 AM
<HTML> <HEAD> <TITLE>AutoPlay Media Studio 5.0 Knowledge Base</TITLE> </HEAD> <BODY> <h3>Creating CD-ROM Browsing Windows</h3> <b>Document ID: IR10076</b> <hr> The information in this article applies to: <ul> <li>AutoPlay Media Studio 5.0 Standard Edition</li> <li>AutoPlay Media Studio 5.0 Professional Edition</li> </ul> <hr> <h3>SUMMARY</h3> <p>This article describes how to create CD-ROM browsing windows.</p> <h3>DISCUSSION</h3> <p>In AutoPlay Media Studio 5.0, it is possible to open a folder on a user's machine, either within your project, or in an external window (the same as double-clicking on a folder on your desktop). It is also possible to open a folder in explore view (the same as using windows explorer).</p> <ul> <li>Opening a folder within your project: (Pro Edition Only):<br> <br> <ol> <li>Create a web object, and name it Web1.<br> <br> </li> <li>Call the action Web.LoadURL:<br> <code>Web.LoadURL("Web1", "C:\\");<br></code> If the user does not have Internet Explorer 4.0 or later as their default browser, the folder view will be html, not windows based.<br> <br> </li> </ol></li> <li> Opening a folder in an external window:<br> <br> <ol><li> Call the action File.Open: <br><code> File.Open("C:\\", "", SW_SHOWNORMAL);<br> <br> </code> </li></ol></li> <li> Opening a folder in an explorer window:<br> <br> <ol><li> Call the action File.ExploreFolder:<br> <code> File.ExploreFolder("C:\\", SW_SHOWNORMAL);</code> <br> To browse the CD-Rom from your autoplay application, use _SourceFolder as the path to browse/open.<br></li></ol></li></ul> <h3>MORE INFORMATION</h3> <p>For more information please see the following topics in the AutoPlay Media Studio 5.0 help file:</p> <ul> <li><b>Program Reference | Actions | File | File.Open</b></li> <li><b>Program Reference | Actions | File | File.ExploreFolder</b></li> <li><b>Program Reference | Actions | Web | Web.LoadURL</b></li> </ul> <p>KEYWORDS: AutoPlay Media Studio 5.0, CD Rom, Browse, Window </p> <hr> <FONT SIZE=1> Last reviewed: October 3, 2003<br> Copyright 2003 <A HREF="http://www.indigorose.com" target="blank">Indigo Rose Corporation</a>. All rights reserved.<br> </FONT> </BODY> </HTML>

The Phantom
10-12-2004, 01:44 PM
I have found most users have problems viewing the CD ROM contents.

Opening a folder in an external window:

Call the action File.Open:

Yours: File.Open("C:\\", "", SW_SHOWNORMAL);
I Use: File.Open(_SourceFolder, SW_SHOWNORMAL);

Opening a folder in an explorer window:

Call the action File.ExploreFolder:

Yours: File.ExploreFolder("C:\\", SW_SHOWNORMAL);
I Use: File.ExploreFolder(_SourceFolder, SW_SHOWNORMAL);

To browse the CD-Rom from your autoplay application, use _SourceFolder as the path to browse/open.

However I still am having problems with viewing the ROM from within a project window. Nothing seems to work with this one.

10-21-2004, 02:55 PM

That's a good point about using the _SourceFolder (or _SourceDrive) variable, instead of "C:\\". I simply wanted to show how to open an explorer window, but it is important to note that rarely, if ever will "C:\\" reference a cd-rom drive.

With regards to viewing the CD-ROM from within a project window . . . do you mean using Web.LoadURL to load the contents into a web object?

I've attached a sample project that uses both _SourceDrive and _SourceFolder combined with a web object. Let me know if that works for you, or if i'm missing the bigger picture.