Dynamic button at bottom of asp page

R

Randy

Hello All,
I'm trying to figure out how to position a dynamic button at the bottom of
an aspx page. I'm able to get the dynamic button to show up on the aspx page
(doing it in c# in the .cs file)
after I populate a table, but I'm trying to make the button position be at
the bottom of the page...after a dynamically sized table...at the botton of
the page.
Is there a way to do this? Would it be done in the asp code or on the c#
side?

Thanks
 
S

Steve C. Orr [MVP, MCSD]

First of all, you should be using FlowLayout mode for the PageLayout
property of your page. This will allow your page to automatically adjust to
the datagrid no matter what its size. (After changing the pageLayout
property you should delete the controls and add them again to the page to
ensure the absolute positioning styles are removed, or you can remove those
styles from the ASPX manually.)
Then, below the datagrid add a PlaceHolder control.
Then from your codebehind, when you decide you want to add the button, put
code like this:

PlaceHolder1.Controls.Add(MyButton)
 
R

Randy

Steve,
Thanks for the help. That is exactly what I was talking about. That
completely solved my problem. I never knew about FlowLayout. Thanks so much
for your help.

Randy
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,534
Members
45,007
Latest member
OrderFitnessKetoCapsules

Latest Threads

Top