[Date Prev][Date Next] [Thread Prev][Thread Next]
[Date Index] [Thread Index] [New search]

Re: automatic alerts




I would probably use a user variable instead. I would call it "DocAlert" and
put the message to display as its definition. This script contains a
NotePostOpenDoc event, which runs automatically whenever a document is
opened. If the document contains a variable called "DocAlert" the script
displays its definition in a message box. This way, you can customize the
message for each document, if necessary. Documents that don't contain a
DocAlert variable will not display any message at all.

// Runs when a document is opened.
Event NotePostOpenDoc
// Test for the DocAlert variable
  Get Object Type(VarFmt) Name('DocAlert')
    NewVar(vDocAlert);
// If it exists, display its definition.
  If vDocAlert
    MsgBox vDocAlert.Fmt Mode(Warn);
  EndIf
EndEvent

Rick Quatro
Carmen Publishing
716 659-8267
rquatro@rochester.rr.com
http://www.frameexpert.com

> > I'd like to have an alert automatically appear when a writer opens a
> > certain file (file A). The alert would remind him that he needs to
update
> > file B if he adds something to file A.
>
> Sounds like something you might be able to do with a FrameScript.
> I don't know FS, but here's an algorithm idea...
>
> on FileOpen
>   if numberOfSiblingFiles > 0 then  /* there are related files */
>     {
>        display "WARNING: When this file is updated, the following
>                 file(s) must also be updated:"
>          for i = 1 to numberOfSiblingFiles
>            readline siblingFileName   /* name of file that must be updated
> */
>            displayline siblingFileName
>          next i
>      }
>   else display "No sibling files exist."
>
> You would need to specify the number and names of the sibling files so
that
> FrameScript could interpret them.... maybe something on a reference page?
> (Maybe siblingFileName is in a hypertext marker?)
>
> Can anyone who actually knows FrameScript and understands hypertext
markers
> elaborate on this?
>
> HTH,
> Ananda Stevens
> ananda.stevens@windriver.com



** To unsubscribe, send a message to majordomo@omsys.com **
** with "unsubscribe framers" (no quotes) in the body.   **