Hi,
Uses: VS.NET 2003, VB.NET, Windows xp
I've written an apsx web page through vb.net. In that I've mentioned a
procedure(Serve r Side). Now I want to call it through Jscript.
The reason behind is about validations. There are some text to enter in one
text box. So once the user has entered the text, it will check whether the
text is null, if not it will call that server side procedure I've mentioned
in aspx page.
I'm wondering how can I call it. One guy in the news group said to use the
following:
1. __doPostBack(.. .);
2. document.forms[0].submit();
3. document.getEle mentById(<Some asp control's client ID>).click();
however it wasn't specific and I didn't understod how to use it. Using codes
to illustrate the solution will be much worthy here.
Thank you,
--
Mohammed Hifni Shahzard Nazeer,
JB Securities Pvt. Ltd.,
Colombo. 2 1345
Hifni Shahzard wrote: Hi, Uses: VS.NET 2003, VB.NET, Windows xp
I've written an apsx web page through vb.net. In that I've mentioned a procedure(Serve r Side). Now I want to call it through Jscript.
The reason behind is about validations. There are some text to enter in one text box. So once the user has entered the text, it will check whether the text is null, if not it will call that server side procedure I've mentioned in aspx page.
I'm wondering how can I call it. One guy in the news group said to use the following:
1. __doPostBack(.. .); 2. document.forms[0].submit(); 3. document.getEle mentById(<Some asp control's client ID>).click();
however it wasn't specific and I didn't understod how to use it. Using codes to illustrate the solution will be much worthy here.
Thank you,
If you want validation, use a CustomValidator . You could provide some
client-side javascript, but that's not required. You are after the server-side
event. There you can do your validation.
Hans Kesting
You can use the AJAX.NET libraries to asynchronously do a server side method
call easily through javascript.
Go here http://ajax.schwarz-interactive.de/c...e/default.aspx for
examples and downloadable libraries and code.
--
- Paul Glavich
MVP ASP.NET http://weblogs.asp.net/pglavich
ASPInsiders member - http://www.aspinsiders.com
"Hans Kesting" <ne***********@ spamgourmet.com > wrote in message
news:%2******** **********@TK2M SFTNGP10.phx.gb l... Hifni Shahzard wrote: Hi, Uses: VS.NET 2003, VB.NET, Windows xp
I've written an apsx web page through vb.net. In that I've mentioned a procedure(Serve r Side). Now I want to call it through Jscript.
The reason behind is about validations. There are some text to enter in one text box. So once the user has entered the text, it will check whether the text is null, if not it will call that server side procedure I've mentioned in aspx page.
I'm wondering how can I call it. One guy in the news group said to use the following:
1. __doPostBack(.. .); 2. document.forms[0].submit(); 3. document.getEle mentById(<Some asp control's client ID>).click();
however it wasn't specific and I didn't understod how to use it. Using codes to illustrate the solution will be much worthy here.
Thank you,
If you want validation, use a CustomValidator . You could provide some client-side javascript, but that's not required. You are after the server-side event. There you can do your validation.
Hans Kesting
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: David Shorthouse |
last post by:
Hey folks,
Not an off-topic posting.....since I was shot-down in an earlier
post...this one's legit.
How do I go about calling a server-side vbscript within a client-side
javascript function? What I have is a page heavy on the javascript that has
a number of functions, one of which is to begin a visual countdown with an
onclick and also open an asp page containing the server-side vbscript, which
initiates a wake-on-lan call. I had no...
|
by: Benny |
last post by:
Hello all,
How can i call a server side function (in .aspx.cs) from a client side
(in .aspx) using javascript?
thanks,
benny
*** Sent via Developersdex http://www.developersdex.com ***
|
by: Reetu |
last post by:
Hi All,
I have an html button on .aspx page.
<INPUT class="sbttn" id="btnComplete0" onclick="onComplete
()" type="button" value="Mark Completed"
name="btnComplete0">
When the user clicks on the html button the OnComplete
function is called.
|
by: usl2222 |
last post by:
Hi folks,
I appreciate any assistance in the following problem:
I have a form with a bunch of dynamic controls on it. All the controls
are dynamically generated on a server, including all the validators.
The user enters the data, presses OK. My OK button is dynamically
generated as well, with some code-behind logic in
|
by: Ohad Young |
last post by:
Hi,
I have a frameset page that contains two frames:
1. the first frame, an aspx page, contains a menu for navigating in the
website.
2. the second frame contains content, pdf, html or other aspx files
The problem is that the menu activates a server-side methods when the user
clicks on one of the menu items.
However, from the server side I cannot control in which frame the content
will appears, it will always be in the menu frame...
| |
by: Roger |
last post by:
Is this possible??
client side:
<script language="jscript">
function hello() {
window.alert("HELLO!");
}
</script>
|
by: AFN |
last post by:
I was just dropped into someone else's code (isn't that always so fun?).
I can't figure out why a custom validation control's server event function
is executing. There is nothing (that I see) in page_load, or elsewhere,
that says page.validate, no control says "causesvalidation=true", and the
AutoEventWireup is set to false. So I would think that the control's
server event function would NOT execute, but it does execute right after...
|
by: lanem |
last post by:
I want to call a server-side function, like a button's click event, from a
client-side JavaScript function. How do I do that? Thanks.
|
by: John Chan |
last post by:
Hi,
Im doing a maintenance application in ajax and coldfusion at work on IE6
exclusively. I have a save button on each form and i have to do various
validations server side and on client side when the user clicks save i.e
check that user exists in table, check users password is the same as
password in table, check password is valid, check that logged in user is a
super user etc etc to get the correct error message. Different forms may or...
|
by: Simon |
last post by:
I heard that we could do that by using AJAX. Could anybody share how to do
it? Thanks.
|
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
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 last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
| |
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
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 we have to send another system
| |