Converting button events etc to ASP.NET MVC
Posted
by Sophie88
on Stack Overflow
See other posts from Stack Overflow
or by Sophie88
Published on 2010-04-26T13:37:00Z
Indexed on
2010/04/26
13:43 UTC
Read the original article
Hit count: 143
c#
|asp.net-mvc
Given an asp.net webform page which does something like
asp.net
<asp:textbox id="txtA" runat="server" />
<asp:textbox id="txtB" runat="server" />
<asp:button id="btnAddTogether" runat="server" text="Go" onclick="btn_Click"/>
<asp:textbox id="txtResult" runat="server" />
code behind
protected void btn_Click(...)
{
txtResult.Text = txtA.Text + txtB.Text;
}
How would I convert this to ASP.NET MVC. It's a pretty trivial example, but I'm not sure about how to change my way of thinking.
© Stack Overflow or respective owner