473,387 Members | 1,844 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Problems whit JavaScript

Hi friends!
I have a problem
i have a textbox in aspx webform:
in the load event :
txtNombre.Attributes.Add("onblur", "CambiarMayusculas(' txtNombre')")

i have a javascript function :

function CambiarMayusculas(elemento1) {var
elem=document.getElementById(elemento1); if (elem.value!="")
elem.value.Text.toUpperCase(); }

but never run

Thank

Victor
Nov 19 '05 #1
3 984
What never runs? CambiarMayusculas? It looks ok. May be there is something
important that you don't mention.

Eliyahu

"VKTOP" <va******@editoraperu.com.pe> wrote in message
news:Oc**************@TK2MSFTNGP14.phx.gbl...
Hi friends!
I have a problem
i have a textbox in aspx webform:
in the load event :
txtNombre.Attributes.Add("onblur", "CambiarMayusculas(' txtNombre')")

i have a javascript function :

function CambiarMayusculas(elemento1) {var
elem=document.getElementById(elemento1); if (elem.value!="")
elem.value.Text.toUpperCase(); }

but never run

Thank

Victor

Nov 19 '05 #2
Hi Eliyahu, thank for response
ok

this :
function CambiarMayusculas(elemento1) {
var elem=document.getElementById(elemento1);
if (elem.value!="")
elem.value.Text.toUpperCase();
} ---------No run
this :
function CambiarMayusculas() {
var elem=document.getElementById('txtNombre');
if (elem.value!="")
elem.value.Text.toUpperCase();
} -------- that ok and run

Why?

Thank for your help

Victor

"Eliyahu Goldin" <re*************@monarchmed.com> wrote in message
news:Or**************@tk2msftngp13.phx.gbl...
What never runs? CambiarMayusculas? It looks ok. May be there is something
important that you don't mention.

Eliyahu

"VKTOP" <va******@editoraperu.com.pe> wrote in message
news:Oc**************@TK2MSFTNGP14.phx.gbl...
Hi friends!
I have a problem
i have a textbox in aspx webform:
in the load event :
txtNombre.Attributes.Add("onblur", "CambiarMayusculas(' txtNombre')")

i have a javascript function :

function CambiarMayusculas(elemento1) {var
elem=document.getElementById(elemento1); if (elem.value!="")
elem.value.Text.toUpperCase(); }

but never run

Thank

Victor


Nov 19 '05 #3
The way i do Javascripts is to insert them in the aspx page itself using
HTML editing mode, this works just fine sofar and even when adding
attributes from the server side like in your example do not disturb the
javascript i added in the designer.

have you checked if the onblur="...." appears at all in the rendered HTML ?
(view source from the browser)

Bart.

"VKTOP" <va******@editoraperu.com.pe> wrote in message
news:Oc**************@TK2MSFTNGP14.phx.gbl...
Hi friends!
I have a problem
i have a textbox in aspx webform:
in the load event :
txtNombre.Attributes.Add("onblur", "CambiarMayusculas(' txtNombre')")

i have a javascript function :

function CambiarMayusculas(elemento1) {var
elem=document.getElementById(elemento1); if (elem.value!="")
elem.value.Text.toUpperCase(); }

but never run

Thank

Victor

Nov 19 '05 #4

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

Similar topics

1
by: Admir Hod?ic via AccessMonster.com | last post by:
I use some old fashion program whit DBF files and now i step by step moving thth to acces. Problem occurs when i try to link DBF tables whit MEMO FILED wich requvest file whit ''name''.ftp extension...
2
by: saeed rezaei | last post by:
hi i am saeed rezaei srezaii2000@yahoo.com who is knowh how i can changing the excel cells backcolor. now i can working whit excel but still i cant change the backcolor of cells.
1
by: news.wanadoo.nl | last post by:
Hi, I have found whit google this form in this group. But i'n not good in javascript :(. I try and error normal but i only error now :P Whit i now want to now how can i get access to the vars...
15
by: sflynn | last post by:
I've just created a new program in Visual Studio 2005, Visual Basic. I can publish, install, and run the program just fine as long as the user is a member of the "Domain Admins" group. My problem...
3
by: Espen | last post by:
Code: <SCRIPT language="JavaScript"> Rente = "5,9"; Rente2 = parseFloat(Rente.replace(",",".")/100); document.write(Rente2 + '<br>'); Rente = "4,9";
2
by: J4CK4L | last post by:
Hi everyone, I've just created a function in a header file that accept a string and parse but the prototipe of the function return me an exception: #include <stdio.h> #include <string.h> int...
14
by: Wouter | last post by:
Hi, I try to make the follow. I want that i can click on a text link and that then a link wil be copyed in a input form box (<input type="text" name="img_url" />). I have google-ed about how...
2
by: azgar | last post by:
Hello, i Want now how lock or block an User on Active Directory using the DirectoryEntry component or another way in .Net. Thanks
12
by: viki1967 | last post by:
Good afternoon to everyone. I write this page htm with JavaScript code: <script language="javascript" type="text/javascript"> <!-- function parseNumber(val) {
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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
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
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...

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.