Thursday, March 29, 2012
Newbie: How to start
I have a html page with a form. How can I start turning this into an asp.net
page to including validation and submit processing?
Thanks
Regards
YahyaHey,
Well first things first. Create a web project if you are using Visual
Studio. If not .. you will need to work a bit more and create a virtual
directory and an aspx page. Similar to a normal html page but with lot of
extra tags... Get yourself a good asp.net book.
Now copy the html body and paste it in the aspx file. When you double a html
object like button or image it will be converted to equivalent web control
Have fun learning.. its fun..
Hermit Dave
"John" <john@.nospam.infovis.co.uk> wrote in message
news:%23neTBVQvDHA.2464@.TK2MSFTNGP12.phx.gbl...
> Hi
> I have a html page with a form. How can I start turning this into an
asp.net
> page to including validation and submit processing?
> Thanks
> Regards
>
> Yahya
Newbie: JavaScript validation on <Asp:CheckBox click
I am very new to ASP.Net 2, and stuck with a problem.
How can I execute a client side JavaScript function on CheckBox click.
I am able to execute function at server, But I don't know how to validate at
client side before going to server.
This code is within a GridView
<ItemTemplate>
<asp:CheckBox ID="CheckBox1" runat="server"
Checked='<%# Bind("OpenConnection") %> '
Enabled="True"
OnCheckedChanged="OpenConnection_Clicked" AutoPostBack="True" />
</ItemTemplate>
When I put onClick="Javascript:FunctionName" within the tag, it says:
Validation (ASP.Net): Attribute'onclick' is not a valid attribute for
element 'CheckBox'.
Please help me.
I'll appreciate your help.
Thanks, RobIt looks like button would better suit the purpose - usually when you want t
o
perform an action (as you do with AutoPostBack="true") a button or a link is
the way to go, and you could use OnClientClick property to inject your
javascript
HTH
"Rob" wrote:
> It might be a simple question.
> I am very new to ASP.Net 2, and stuck with a problem.
> How can I execute a client side JavaScript function on CheckBox click.
> I am able to execute function at server, But I don't know how to validate
at
> client side before going to server.
>
> This code is within a GridView
> <ItemTemplate>
> <asp:CheckBox ID="CheckBox1" runat="server"
> Checked='<%# Bind("OpenConnection") %> '
> Enabled="True"
> OnCheckedChanged="OpenConnection_Clicked" AutoPostBack="True" />
> </ItemTemplate>
> When I put onClick="java script:FunctionName" within the tag, it says:
> Validation (ASP.Net): Attribute'onclick' is not a valid attribute for
> element 'CheckBox'.
> Please help me.
> I'll appreciate your help.
> Thanks, Rob
>
>
Newbie: JavaScript validation on <Asp:CheckBox click
I am very new to ASP.Net 2, and stuck with a problem.
How can I execute a client side JavaScript function on CheckBox click.
I am able to execute function at server, But I don't know how to validate at
client side before going to server.
This code is within a GridView
<ItemTemplate>
<asp:CheckBox ID="CheckBox1" runat="server"
Checked='<%# Bind("OpenConnection") %'
Enabled="True"
OnCheckedChanged="OpenConnection_Clicked" AutoPostBack="True" />
</ItemTemplate>
When I put onClick="javascript:FunctionName" within the tag, it says:
Validation (ASP.Net): Attribute'onclick' is not a valid attribute for
element 'CheckBox'.
Please help me.
I'll appreciate your help.
Thanks, RobIt looks like button would better suit the purpose - usually when you want to
perform an action (as you do with AutoPostBack="true") a button or a link is
the way to go, and you could use OnClientClick property to inject your
javascript
HTH
"Rob" wrote:
Quote:
Originally Posted by
It might be a simple question.
I am very new to ASP.Net 2, and stuck with a problem.
How can I execute a client side JavaScript function on CheckBox click.
I am able to execute function at server, But I don't know how to validate at
client side before going to server.
>
>
This code is within a GridView
<ItemTemplate>
<asp:CheckBox ID="CheckBox1" runat="server"
Checked='<%# Bind("OpenConnection") %'
Enabled="True"
OnCheckedChanged="OpenConnection_Clicked" AutoPostBack="True" />
</ItemTemplate>
>
When I put onClick="javascript:FunctionName" within the tag, it says:
Validation (ASP.Net): Attribute'onclick' is not a valid attribute for
element 'CheckBox'.
>
Please help me.
I'll appreciate your help.
>
Thanks, Rob
>
>
>