How to load Rez resource dynamically?

Hi, please can anyone help me how to load dynamically resource?

Normally I would do something like this: animation = new WatchUi.AnimationLayer(Rez.Drawables.resourcxy, {:locX=>0, :locY=>0});

But I would like to pass the resource ID (Rez.Drawables.resourcxy) as an input parameter (e.g. from my database) and then load it based on that.

I tried something like this: View.findDrawableById("TimeLabel") , but it does not work (I guess I call it incorrectly, or this is not even working for my solutions).

Thanks!

Top Replies

All Replies