setting location of ask/answer dailogs in win/mac via code

Jan Schenkel janschenkel at yahoo.com
Mon Sep 27 14:48:26 EDT 2004


--- Meitnik at aol.com wrote:
> hi
> 
> ok, we have ssl, thanks; but how about a few simple
> things like setting the 
> location of ask/answer. until thats done, so how
> does one do it without having 
> to make one's own ask/answer critters?
> 
> Thanks
> Andrew
> 

Hi Andrew,

In my projects I use a frontScript like :
--
on preOpenStack
  if the short name of the target \
     is among the items of "Ask,Answer" then
    set the location of the target to the screenLoc
  end if
  pass preOpenStack
end preOpenStack
--

The above will center the Ask and Answer dialog boxes,
but you could add handlers to change the loc and save
it in a local variable of the frontscript. Example :
--
local sDialogLocationsA
on Andrew_SetDialogLocation pDialogName, pLocation
  put pLocation into sDialogLocationsA[pDialogName]
end Andrew_SetDialogLocation

on preOpenStack
  put the short name of the target into tName
  if tName is among the items of "Ask,Answer" then
    set the location of the target to \
        sDialogLocations[tName]
  end if
  pass preOpenStack
end preOpenStack
--

Hope this helped,

Jan Schenkel.  

=====
"As we grow older, we grow both wiser and more foolish at the same time."  (La Rochefoucauld)


		
__________________________________
Do you Yahoo!?
Read only the mail you want - Yahoo! Mail SpamGuard.
http://promotions.yahoo.com/new_mail 


More information about the use-livecode mailing list