spacer

Webref WebRef   Sitemap · Experts · Tools · Services · Newsletters · About i.com

home / experts / javascript / column48


Using JavaScript in HomeSite 4.0, Part I

Developer News
Microsoft Shows Off Silverlight 4, IE9 Plans
Metasploit Expands Vulnerability Test Framework
HyperCard Reborn?

The Application Object's Methods, Part IV

HTMLGetTitle(filename)String

Returns the title (<TITLE>returned value</TITLE>) of a given HTML document. The filename parameter must reflect a local file.

InputBox(caption, prompt, default)String

Displays a dialog box with a caption (caption), a prompt (prompt), and a default vaule (default). This method returns the user's input. The following code:

app.InputBox("Math Lesson", "460 + 40:", "???")

generates the following box:

An Input Box

IsFileOpen(fullPath)Boolean

Returns true if the given file (fullPath) is open, false otherwise. For example, if the file "E:\Tomer\column48\appmet1.html" is open, the following statement returns -1, a true value:

app.IsFileOpen("E:\\Tomer\\column48\\appmet1.html");

For some reason, HomeSite often uses -1 to specify a true value, rather than 1. However, since all integers, except 0, evaluate to true when used in a conditional expression, this isn't a problem.

IsFileModified(fullPath)Boolean

Returns -1 if the given file (fullPath) is open and has been modified since its last save, or 0 otherwise. or example, if the file "E:\Tomer\column48\appmet1.html" is open, the following statement returns -1, a true value:

app.IsFileModified("E:\\Tomer\\column48\\appmet1.html");

http://www.internet.com

Produced by Yehuda Shiran and Tomer Shiran

internet.commediabistro.comJusttechjobs.comGraphics.com

Search:

WebMediaBrands Corporate Info

Legal Notices, Licensing, Permissions, Privacy Policy.
Advertise | Newsletters | Shopping | E-mail Offers | Freelance Jobs

webref The latest from WebReference.com Browse >
Rolling Out Your Own HTML Application Version Control · HTML 5: Client-side Storage · Working with Ajax Server Extensions
Sitemap · Experts · Tools · Services · Email a Colleague · Contact FREE Newsletters 
 The latest from internet.com
Wi-Fi Product Watch, November 2009 · Chip Market Recovering From '08 Collapse · Low-Cost Tools to Kickstart Your New Business


Created: September 13, 1999
Revised: September 13, 1999

URL: http://www.webreference.com/js/column48/appmet4.html