Take a look at this example here. It’s not exactly what you want but it might help you get a little closer…