Finding an item in a collection of types

Blitz3D Forums/Blitz3D Programming/Finding an item in a collection of types

well the developer could know the handle right off the bat if you did something like this

type Button
    field x,y
    ....
end type


function CreateButton(...)
   b.Button = new Button
   ;set the parameters

   return Handle(b)
end function

function FindButton.Button(hButton)
    b.Button = Object.Button(hButton)
    return b
end function