Home
Get Started
Learn
Downloads
AJAX
MVC
Community
Wiki
Forums
Sign in
|
Join
Home
›
ASP.NET Forums
›
Search
Search
You searched for the word(s): userid:728109
More Search Options
RSS Available
Matching Posts
Re: Failed to show message box upon validation
Anyone can help out?
Posted to
Web Forms
(Forum)
by
ryanlcs
on 10/23/2009
Re: Failed to show message box upon validation
[quote user="manoj0682"] link I provided in that its using null .... have you tried that .... [/quote] I tried that too initially, but it gives an error saying : BC30822: 'null' is not declared. 'Null' constant is no longer supported; use 'System.DBNull' instead. I am using VS2008, .Net 3.5, will this caused the confusion?
Posted to
Web Forms
(Forum)
by
ryanlcs
on 10/22/2009
Re: Failed to show message box upon validation
[quote user="manoj0682"] If you are using UpdatePanel, in that case ClientScript won't work. ScriptManager.RegisterStartupScript(Me.Page, Me.GetType, "alert", "alert('test');", True) if you are using ClientScript ClientScript.RegisterStartupScript( Me.GetType , "alert", "alert('test');", True) [/quote] Got it worked out. Thanks. I got another issue here, after the validation done, I need a message box indicating "Are you sure
Posted to
Web Forms
(Forum)
by
ryanlcs
on 10/21/2009
Re: Failed to show message box upon validation
[quote user="manoj0682"] You can use OnClientClick event of button eg onClientClick="return validate();" in javascript side function Validate() { ///do your validation here if (window.confirm( "Are you sure to proceed" ) == false) return false; else return true; if (window.confirm(msg) == false) return false; } [/quote] Hi Currently the validation is done in code behind file and not thru the javascript. So, is it possible to apply the OnClientClick event to this situation
Posted to
Web Forms
(Forum)
by
ryanlcs
on 10/21/2009
Re: Failed to show message box upon validation
I found this code which proven to be useful, but I hit an error on this block of code: <script language="javascript" type="text/javascript"> function confirmSend() { var ret = confirm("Are you sure to proceed?"); if(ret == true) { setTimeout("<% = Page.ClientScript.GetPostBackEventReference(btnDummy, system.dbnull, true) %>", 0); } } </script> Error message: BC30691: 'dbnull' is a type in 'System' and cannot be used as an expression
Posted to
Web Forms
(Forum)
by
ryanlcs
on 10/21/2009
Re: Failed to show message box upon validation
[quote user="manoj0682"] not sure due to case sensitive just try this one System.DBNull instead of system.dbnull [/quote] Is not the case-sensitive issue.
Posted to
Web Forms
(Forum)
by
ryanlcs
on 10/21/2009
Failed to show message box upon validation
Hi I have a validation code, whenever the validation failed, I wanted to show the message box: Public Sub cmdSend_Click(ByVal sender As Object, ByVal e As System.EventArgs) cmdSend.Attributes.Remove("OnClick") If Not IsNumeric(txtText.Text) Then errorCheck = True errorMsg = "Please fill in the with numbers!" txtText.Focus() cmdSend.Attributes.Add("OnClick", "showError()") txtText.BackColor = Drawing.Color.Yellow Exit Sub End If End Sub This is what I have done
Posted to
Web Forms
(Forum)
by
ryanlcs
on 10/20/2009
Re: Failed to show message box upon validation
I had try this out: Public Sub cmdSend_Click(ByVal sender As Object, ByVal e As System.EventArgs) If Not IsNumeric(txtText.Text) Then errorCheck = True txtText.Focus() txtText.BackColor = Drawing.Color.Yellow lblMsg.Text = "Please fill in the Hypo column with numbers!" ClientScript.RegisterClientScriptBlock(GetType(Page), "myscript", "alert('test')", True) Exit Sub End If End Sub But the message does not show up. Anyone can help?
Posted to
Web Forms
(Forum)
by
ryanlcs
on 10/20/2009
Re: Find Control not working under AJAX
[quote user="kipo"] Why do you even use FindControl() - this will work just fine: view plain copy to clipboard print ? Tab0txtEmp1.Enabled = False Tab0txtEmp1.Enabled = False [/quote] Ya, I know this works find, but I got a lot of control which I named as Tab0txtEmp1 Tab0txtEmp2 Tab0txtEmp3 Tab0txtEmp4 .... so, I would prefer to use a loop to search for the control and manipulate thru the loop. Thanks.
Posted to
ASP.NET AJAX Discussion and Suggestions
(Forum)
by
ryanlcs
on 10/19/2009
Find Control not working under AJAX
Hi I got the following form declaration: <form id="form1" runat="server"> <asp:ScriptManager ID="ScriptManager1" runat="server"> </asp:ScriptManager> <div> <asp:UpdatePanel ID="UpdatePanel1" runat="server"> <ContentTemplate> <cc1:TabContainer ID="TabContainer1" runat="server" ActiveTabIndex="0" Height="400px" Width="830px"> <cc1:TabPanel ID="TabPanel1"
Posted to
ASP.NET AJAX Discussion and Suggestions
(Forum)
by
ryanlcs
on 10/19/2009
Page 1 of 24 (238 items) 1
2
3
4
5
Next >
...
Last ยป
WindowsClient:
Tale of two tweets - VS beta - is it busy 70% of the time or is it brilliantly fast?
Mix Online:
Using the HTML5 Video and Audio Tag with Gestalt
WindowsClient:
Subclassing Shape (or more accurately, Path)
WindowsClient:
Having trouble deleting files? Try this
Channel 9:
Nick Baker: Xbox Architecture
TechNet Edge:
Thrive Live! Behavioral Interviewing: A behavioral answer is always the correct answer
ASP.NET:
PDC and Tech-Ed Europe Slides and Code
WindowsClient:
JScript location bar silliness
WindowsClient:
Anybody build a XAML parser in C or C++ yet?
WindowsClient:
Silverlight use, power and deployment keeps growing; so does WPF
ASP.NET:
T4CSS: A T4 Template for .Less CSS With Compression
WindowsClient:
JSON-P: An Elegant Hack
Channel 9:
Photosynth Update and New UI
Channel 9:
First Look: Streetside in Bing Maps
Channel 9:
Coding4Fun at PDC 2009
WindowsClient:
10 Must-See PDC 09 Sessions
Channel 10:
Photosynth Updated with New Release and New UI
Channel 10:
WindowsBlinds 7 Now Works with Windows 7
Channel 10:
Zune HD Launches New Colors
ASP.NET:
PDC09: ASP.NET MVC 2: Ninjas Still on Fire Black Belt Tips
Microsoft Communities
ASP.NET
Channel 8
Channel 9
Channel 10
IIS.NET
Silverlight
TechNet Edge
WindowsClient
Mix Online