Quantcast
WoWInterface - View Single Post - Access frame by name
View Single Post
09-03-17, 03:10 PM   #3
Kanegasi
A Molten Giant
 
Kanegasi's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2007
Posts: 500
You said you were using it, right? The close button has a name, it's $parentClose, so it would be whatever you named your frame with Close at the end.

Lua Code:
  1. local myDialogFrame = CreateFrame("frame", "myDialogName", UIParent, "UIPanelDialogTemplate")
  2.  
  3. myDialogNameClose:SetScript("OnClick", function()
  4.     -- whatever
  5. end)
  Reply With Quote