content: -- fmGUI_ObjectClick_AffectsWindow(buttonRef)
  -- Dan Shockley, NYHTC
  -- Click on an object that will open a window
  
  
  (*
  HISTORY:
  	1.0 - created
  *)
  
  
  on run
  	tell application "System Events"
  		tell process "FileMaker Pro Advanced"
  			set frontmost to true
  			set cancelButton to get first button of window 1 whose name is "Cancel"
  		end tell
  	end tell
  	
  	fmGUI_ObjectClick_AffectsWindow(cancelButton)
  end run
  
  --------------------
  -- START OF CODE
  --------------------
  
  on fmGUI_ObjectClick_AffectsWindow(buttonRef)
  	-- version 1.0
  	
  	using terms from application "System Events"
  		my clickObjectByCoords(buttonRef)
  	end using terms from
  	
  end fmGUI_ObjectClick_AffectsWindow
  
  --------------------
  -- END OF CODE
  --------------------
  
  on clickObjectByCoords(someObject)
  	tell application "htcLib" to clickObjectByCoords(someObject)
  end clickObjectByCoords
  