[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 XPask()
 Pop up as box with a question and returns answer
------------------------------------------------------------------------------

   Function:   XPask()

               This function is handy for the Yes/No messages. It pop's
               up a question, and awaits the asnwer. it uses XPalert() and
               thus supports multiple lines, title, more colors and a Mouse.

   Syntax:     XPask(cTitle,cText,lYes,cYes,cNo) --> lAnswer

   Arguments:  cTitle is the title to display.
               cText is the Text to display. it is centered in the box. Use
               the ; delimitor for more lines. lYes indicates whether Yes is
               the default choice. It defaults to No (.f.). cYes and cNo
               represent the strings for "Yes" and "No".

   Returns:    The Answer to the question...

   Usage:      Here's the source code:
               Function XPask(cTitle,cText,lYes,cYes,cNo)
               Local lAnswer
               default lYes to .f.
               default cYes to "~Y~es"
               default cNo to "~N~o"
               if lYes
                 lAnswer := (XPalert(cTitle,cText,{cYes,cNo})=1)
               else
                 lAnswer := (XPalert(cTitle,cText,{cNo,cYes})=2)
               end
               Return (lAnswer)

See Also: XPalert()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson