Click here to Skip to main content
15,895,192 members
Home / Discussions / Web Development
   

Web Development

 
Questionvisual studio 2005 issue Pin
Shaimmaa1-Feb-07 6:02
Shaimmaa1-Feb-07 6:02 
AnswerRe: visual studio 2005 issue Pin
Christian Graus1-Feb-07 9:43
protectorChristian Graus1-Feb-07 9:43 
QuestionCMMI Pin
Member 37855611-Feb-07 5:48
Member 37855611-Feb-07 5:48 
QuestionWeb service issues Pin
Parmenio1-Feb-07 2:09
Parmenio1-Feb-07 2:09 
AnswerRe: Web service issues Pin
parsiphal1-Feb-07 3:46
parsiphal1-Feb-07 3:46 
QuestionJavascript Copy Text Pin
tech_freak1-Feb-07 1:49
tech_freak1-Feb-07 1:49 
AnswerRe: Javascript Copy Text Pin
Vasudevan Deepak Kumar1-Feb-07 3:52
Vasudevan Deepak Kumar1-Feb-07 3:52 
AnswerRe: Javascript Copy Text Pin
David Domingues1-Feb-07 5:44
David Domingues1-Feb-07 5:44 
I had that problem myself. I have a time field and when i was clicking on Hour/minutes/second, i wanted the 2 representative digit to be selected depending on the position of the click.

My code obviouly didn't work on Firefox as usual Frown | :(

I found on the web the following code to solve the problem:
function insertAtCursor(myField, myValue) 
{ 
//IE support 
if (document.selection) 
{ 
myField.focus(); 
sel = document.selection.createRange(); 
sel.text = myValue; 
sel.moveStart(’character’, -myValue.length); 
sel.select(); 
} 

//MOZILLA/NETSCAPE support 
else if (myField.selectionStart || myField.selectionStart == ‘0′) 
{ 
var startPos = myField.selectionStart; 
var endPos = myField.selectionEnd; 
myField.value = 
myField.value.substring(0, startPos) 
+ myValue 
+ myField.value.substring(endPos, myField.value.length); 
myField.selectionStart = startPos; 
myField.selectionEnd = startPos + myValue.length; 
} 


Contact me! Please feel free to visit my site

Questionddl with grid Pin
praveenanand31-Jan-07 20:00
praveenanand31-Jan-07 20:00 
AnswerRe: ddl with grid Pin
badgrs31-Jan-07 22:44
badgrs31-Jan-07 22:44 
QuestionAdd elements from one ListBox to another Pin
varshavmane31-Jan-07 18:09
varshavmane31-Jan-07 18:09 
AnswerRe: Add elements from one ListBox to another Pin
Sachin Pimpale31-Jan-07 19:03
Sachin Pimpale31-Jan-07 19:03 
GeneralRe: Add elements from one ListBox to another Pin
varshavmane31-Jan-07 19:58
varshavmane31-Jan-07 19:58 
Questiondesign and control media player Pin
gigo2k631-Jan-07 11:18
gigo2k631-Jan-07 11:18 
AnswerRe: design and control media player Pin
Bradml31-Jan-07 13:23
Bradml31-Jan-07 13:23 
AnswerRe: design and control media player Pin
Vasudevan Deepak Kumar1-Feb-07 3:53
Vasudevan Deepak Kumar1-Feb-07 3:53 
Questiondropdown menu with javascript Pin
MayyMagdy31-Jan-07 2:46
MayyMagdy31-Jan-07 2:46 
AnswerRe: dropdown menu with javascript Pin
badgrs31-Jan-07 2:55
badgrs31-Jan-07 2:55 
GeneralRe: dropdown menu with javascript Pin
MayyMagdy31-Jan-07 5:16
MayyMagdy31-Jan-07 5:16 
GeneralRe: dropdown menu with javascript Pin
badgrs31-Jan-07 6:29
badgrs31-Jan-07 6:29 
QuestionNeed help in making email client Pin
EEmaan30-Jan-07 20:10
EEmaan30-Jan-07 20:10 
AnswerRe: Need help in making email client Pin
Bradml30-Jan-07 20:44
Bradml30-Jan-07 20:44 
Questioni am in trouble because of very big ASP form Pin
ajitscorpio30-Jan-07 10:38
ajitscorpio30-Jan-07 10:38 
AnswerRe: i am in trouble because of very big ASP form Pin
Christian Graus30-Jan-07 10:55
protectorChristian Graus30-Jan-07 10:55 
GeneralRe: i am in trouble because of very big ASP form Pin
Vasudevan Deepak Kumar1-Feb-07 3:55
Vasudevan Deepak Kumar1-Feb-07 3:55 

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.