Good try. I recommended that you can consider using Data Control such as GridView, ListView, and Reapter control. It is easy to use them to bind the data and display it as template in page.