473,508 Members | 2,213 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Displaying the message in ASP.Net application.....

In my ASP.Net application, validation rule demands that user has to select
one of the option buton(...WebControls.RadioButton).
I am doing these kind of validations in the server side when the user clicks
on the update button(...webControls.Button). My problem is how to display
this message to the end user. In a traditional desktop apllication i can
display the message usig message functions or modal forms. How to inform the
user that the validations got failed ?
Cris Rock
Nov 18 '05 #1
4 2287
If you want to produce a message in a modal dialog, use client-side
JavaScript function window.alert (...). Alternatively, you can allocate an
invisible area for messages on your web form and make it visible on server
side when you want to display a message.

Eliyahu

"Cris Rock" <Ro****@yahoo.com> wrote in message
news:ek**************@TK2MSFTNGP11.phx.gbl...
In my ASP.Net application, validation rule demands that user has to select
one of the option buton(...WebControls.RadioButton).
I am doing these kind of validations in the server side when the user clicks on the update button(...webControls.Button). My problem is how to display
this message to the end user. In a traditional desktop apllication i can
display the message usig message functions or modal forms. How to inform the user that the validations got failed ?
Cris Rock

Nov 18 '05 #2
ben
hi Cris,
I m not sure i understood ur issue correctly, but i think u wanna
display a message box on the client? if yes......i had the same issue
and the code i used is as follows

Response.Write("<script>window.alert('Your message here')</script>");

HTH,
Ben

"Cris Rock" <Ro****@yahoo.com> wrote in message news:<ek**************@TK2MSFTNGP11.phx.gbl>...
In my ASP.Net application, validation rule demands that user has to select
one of the option buton(...WebControls.RadioButton).
I am doing these kind of validations in the server side when the user clicks
on the update button(...webControls.Button). My problem is how to display
this message to the end user. In a traditional desktop apllication i can
display the message usig message functions or modal forms. How to inform the
user that the validations got failed ?
Cris Rock

Nov 18 '05 #3
Cris, Its easy to do it RequiredFieldValidation Control. However if you
want to do a validation on the server side and display a message... your
best option is to set a client side variable with a message to be
displayed in the Onload of a page and then have a client side jscript
function that displays this message in an alert
Hope that helps

Cris Rock wrote:
In my ASP.Net application, validation rule demands that user has to select
one of the option buton(...WebControls.RadioButton).
I am doing these kind of validations in the server side when the user clicks
on the update button(...webControls.Button). My problem is how to display
this message to the end user. In a traditional desktop apllication i can
display the message usig message functions or modal forms. How to inform the
user that the validations got failed ?
Cris Rock


--
Regards,
Dilip Krishnan
dilipkrish at msn. com
Nov 18 '05 #4
Ben,
Thanks for the solution.
I slightly modified the syntax.
Here it is....
Response.Write("<script>window.alert('your message here')</script>;")

The poblem here is, after the message, the rendered page will have ";"
character at the top of the page.
any thought on this ?
I appreciate your earlier thoughts on this.
Cris

"ben" <sk****@yahoo.com> wrote in message
news:ba**************************@posting.google.c om...
hi Cris,
I m not sure i understood ur issue correctly, but i think u wanna
display a message box on the client? if yes......i had the same issue
and the code i used is as follows

Response.Write("<script>window.alert('Your message here')</script>");

HTH,
Ben

"Cris Rock" <Ro****@yahoo.com> wrote in message

news:<ek**************@TK2MSFTNGP11.phx.gbl>...
In my ASP.Net application, validation rule demands that user has to select one of the option buton(...WebControls.RadioButton).
I am doing these kind of validations in the server side when the user clicks on the update button(...webControls.Button). My problem is how to display this message to the end user. In a traditional desktop apllication i can
display the message usig message functions or modal forms. How to inform the user that the validations got failed ?
Cris Rock

Nov 18 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
2251
by: Yoshitha | last post by:
hi I have datalist control in my ASP.NET application the problem here is i have used a textbox with multiline true propertly when i enter data like "fdjsfhjksdhfjsdfhsdjhfsdfhsdjfhsd...
3
3688
by: Cybertof | last post by:
Hello, I have a strange behavior. On a MyForm form, i have a button with this code ----> MessageBox.Show("hello"); When i start the project with this single form ----> Application.Run(new...
5
7788
by: Tomaz Koritnik | last post by:
Hi I have many short HTML files stored in a binary stream storage to display descriptions for various items in application. HTML would be display inside application using some .NET control or...
3
1924
by: Macca | last post by:
Hi, I am writing a C# application that needs a lot of calibration data. In a previous C++ application, i used a text file which displayed the various calibration data, between 25 and 40...
2
4313
by: RAJ | last post by:
In our multi-tier application, we have several ASP.NET user controls which will update the same data source provided by middle tier logic. In this particular scenario we have one user control...
1
1216
by: Yoshitha | last post by:
Hi I have datalist control in my ASP.NET application the problem here is i have used a textbox with multiline true propertly when i enter data like "fdjsfhjksdhfjsdfhsdjhfsdfhsdjfhsd...
4
3474
by: Kivanc Toker | last post by:
Hi, I've got a problem with displaying texts with turkish characters. There is a website administration system, which is developed using ASP (VBScript) and ADO. This system is being used for...
3
5800
by: CD | last post by:
An application is logging faxes sent in SQL2000 image column type. I have found code on the net but what it is doing is prompting to save to local which is fine for single page image. Not good...
14
9453
by: Brad | last post by:
I have a .net 2.0 web application project that creates a pdf file, saves the pdf to disk (crystal reports does this part), and then my code reads the pdf file and writes it to the httpresponse ...
4
2663
by: redpears007 | last post by:
Hi Again, Throwing this one out to you again as i am not getting anywhere and can find little to no information out there. I am currently displaying images (Jpegs) in access via the routine...
0
7132
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7336
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7401
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
5640
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
3211
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
3196
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1568
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
773
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
432
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.