FormView Buttons

S

shapper

Hello,

I created a FormView at runtime and implemented Insert, Edit and Item
templates through a Class (Implements ITemplate).

Since all my templates are the same, i.e., there are no differences
between them I just used the same class for all.

Can I do this?

And in my ITemplate I created 3 buttons: Insert, Update, Edit and
Cancel.

How can I make the buttons work with FormView?

And how do I have to manual hide or show the buttons depending on
FormView mode?

Thanks,

Miguel
 
N

nothingsoriginalontheinternet

You can use the CommandName property of the buttons to make them
insert, update, edit, and cancel. Just set it to one of those as
strings. You can handle the PreRender event of the buttons to
determine if the mode of the containing FormView should contain each,
and set the Visible property appropriately.

-Mike Placentra II
 

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

Similar Threads


Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top