View Single Post
07-26-17, 08:17 PM   #6
Layback_
An Onyxian Warder
Join Date: Feb 2016
Posts: 358
One more question!

What would be the best way to get access (or get reference) to first member frame of the group?

I'm currently doing it this way.

Lua Code:
  1. -- string comparison to see if the current frame is the first member frame of the group
  2. -- e.g. MyUI_Raid1UnitButton1
  3. if E:StringEndsWith(frame:GetName(), "1") then
  4.     -- get parent
  5.     local group = frame:GetParent();
  6. end

This would work fine, but I am curious if there is any better solution to achieve this.

Last edited by Layback_ : 07-26-17 at 08:21 PM.
  Reply With Quote