how to bind table values in dynamicsAX4.0 grid

hi, i am working in dynamics AX4.0 and i have one grid and one button i n my need is at run time if i click button tables values has to be shown in grid. my table name is custtable. so please any one can show me some sample code. please