Click here to Skip to main content
15,891,951 members
Home / Discussions / Web Development
   

Web Development

 
QuestionReference error! Pin
nclauder21-Jan-07 22:27
nclauder21-Jan-07 22:27 
AnswerRe: Reference error! Pin
Bradml21-Jan-07 22:34
Bradml21-Jan-07 22:34 
GeneralRe: Reference error! Pin
nclauder21-Jan-07 22:42
nclauder21-Jan-07 22:42 
QuestionLooking for known Web services.... Pin
Yanshof20-Jan-07 10:40
Yanshof20-Jan-07 10:40 
AnswerRe: Looking for known Web services.... Pin
Bradml20-Jan-07 20:23
Bradml20-Jan-07 20:23 
QuestionWebsite Search Bar Pin
Graphic Jam19-Jan-07 18:02
Graphic Jam19-Jan-07 18:02 
AnswerRe: Website Search Bar Pin
Bradml19-Jan-07 18:24
Bradml19-Jan-07 18:24 
Questionjavascript click button Pin
eggsovereasy19-Jan-07 4:11
eggsovereasy19-Jan-07 4:11 
I'm having a lot of trouble getting this bit of javascript to work:

<asp:TextBox ID="tbNew" runat="server" onkeydown="
	if (event.keyCode == 13)
	{
	        document.getElementById('ctl00_ContentPlaceHolder1_slItems_btnAdd').click();
		document.getElementById('ctl00_ContentPlaceHolder1_slItems_tbNew').focus();
	}
	return false;
">
</asp:TextBox>


I want the user to be about to type text into a text box, hit enter and have what they typed added to a list box. All this is inside an AJAX updatepanel. Right now when you type in the text box no characters are placed in the text box, but when you press enter the appropriate button is pressed, but it does not refocus on the text box. Any idea why I can't type anything into the box and how do I move focus back to the text box? Also is there an easier way to refer to runat=server controls in javascript then to go to view source and find the big ugly id that gets generated?

btw, where it says "removed" it is supposed to say onkeydown, but CP changes it for some reason.
AnswerRe: javascript click button Pin
Guffa19-Jan-07 7:09
Guffa19-Jan-07 7:09 
GeneralRe: javascript click button Pin
eggsovereasy19-Jan-07 10:36
eggsovereasy19-Jan-07 10:36 
AnswerRe: javascript click button Pin
Guffa19-Jan-07 12:16
Guffa19-Jan-07 12:16 
AnswerRe: javascript click button Pin
RichardGrimmer20-Jan-07 5:42
RichardGrimmer20-Jan-07 5:42 
AnswerRe: tap control Pin
Christian Graus18-Jan-07 22:03
protectorChristian Graus18-Jan-07 22:03 
JokeRe: tap control Pin
DavidNohejl18-Jan-07 23:26
DavidNohejl18-Jan-07 23:26 
QuestionDisable Right Click, Problem Javascript Code Pin
varshavmane18-Jan-07 18:11
varshavmane18-Jan-07 18:11 
AnswerRe: Disable Right Click, Problem Javascript Code Pin
Shog919-Jan-07 7:15
sitebuilderShog919-Jan-07 7:15 
QuestionDHTML and DropDownLists Pin
Leo Smith18-Jan-07 15:08
Leo Smith18-Jan-07 15:08 
AnswerRe: DHTML and DropDownLists Pin
Christian Graus18-Jan-07 18:32
protectorChristian Graus18-Jan-07 18:32 
GeneralRe: DHTML and DropDownLists Pin
Leo Smith19-Jan-07 2:33
Leo Smith19-Jan-07 2:33 
GeneralRe: DHTML and DropDownLists Pin
RichardGrimmer19-Jan-07 6:48
RichardGrimmer19-Jan-07 6:48 
GeneralRe: DHTML and DropDownLists Pin
Leo Smith19-Jan-07 9:26
Leo Smith19-Jan-07 9:26 
QuestionFirefox Extensions Pin
Richard Andrew x6418-Jan-07 14:54
professionalRichard Andrew x6418-Jan-07 14:54 
QuestionChange activex security for htm client side Pin
Will6618-Jan-07 13:51
Will6618-Jan-07 13:51 
AnswerRe: Change activex security for htm client side Pin
Will6618-Jan-07 13:54
Will6618-Jan-07 13:54 
QuestionApache serving files with query strings in their name Pin
Paul Watson18-Jan-07 12:23
sitebuilderPaul Watson18-Jan-07 12:23 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.