View Single Post
01-31-12, 11:31 AM   #6
Grimsin
A Molten Giant
 
Grimsin's Avatar
AddOn Author - Click to view addons
Join Date: Sep 2006
Posts: 990
Originally Posted by Waky View Post
I'm pretty sure you can do something along the lines of:

Code:
if frameName then
-- Code to be executed if it exists
end
If I'm not mistaken

If that does nothing you could just to the nil check

Code:
if (frameName~=nil) then
-- Code to be executed if it exists
end
The first method i know does not work... that only works for addon names. You could do a check to see if an addon is loaded via if name then but does not work for frames that do not exist. Ill try the if framename == nil then do such and such or vice verse ~=

Last night i already went with a method not listed here at all... since what im trying to do is run my UI with files missing and i want to have one file in the UI check to see if frames from the other file are available and run them if they are or dont if they are not. What i ended up doing is just having the file create a variable when it loads and have the other file check for the variable. Most likely not an efficient method and if i can get either of the above to work im going to do that.
__________________
"Are we there yet?"

GrimUI
[SIGPIC][/SIGPIC]

Last edited by Grimsin : 01-31-12 at 11:34 AM.
  Reply With Quote