Click here to Skip to main content
15,880,299 members
Home / Discussions / JavaScript
   

JavaScript

 
QuestionCollapsible gridview using javascript Pin
Member 1097302613-Aug-14 9:35
Member 1097302613-Aug-14 9:35 
AnswerRe: Collapsible gridview using javascript Pin
Anurag Gandhi22-Aug-14 8:56
professionalAnurag Gandhi22-Aug-14 8:56 
QuestionForum software.. Pin
Fever42012-Aug-14 5:50
Fever42012-Aug-14 5:50 
SuggestionRe: Forum software.. Pin
Richard Deeming12-Aug-14 8:55
mveRichard Deeming12-Aug-14 8:55 
QuestionRequireJS in ASP.Net Webforms Pin
Member 102920078-Aug-14 5:00
Member 102920078-Aug-14 5:00 
Questionany body convert this code( vb script) to java script Pin
boopathiraj4-Aug-14 22:22
boopathiraj4-Aug-14 22:22 
QuestionCondition Always true when checking for "undefined" in Javascript Pin
Vimalsoft(Pty) Ltd3-Aug-14 9:28
professionalVimalsoft(Pty) Ltd3-Aug-14 9:28 
AnswerRe: Condition Always true when checking for "undefined" in Javascript Pin
Blikkies3-Aug-14 22:48
professionalBlikkies3-Aug-14 22:48 
Try using a Falsy check.

The following values are always falsy:

false
0 (zero)
"" (empty string)
null
undefined
NaN (a special Number value meaning Not-a-Number!)

Your code should look like as follows:
JavaScript
if(!document.frmEntry.optMethod)
                       {
                           if (document.frmEntry.optMethod.selectedIndex == 0) {
                               strPrompt=strPrompt+'Please specify the Valuation Method\n';
                               if ( objFocus == null ) {
                                   objFocus = document.frmEntry.optMethod;
                               }
                           }
                       }

AnswerRe: Condition Always true when checking for "undefined" in Javascript Pin
Kornfeld Eliyahu Peter4-Aug-14 0:19
professionalKornfeld Eliyahu Peter4-Aug-14 0:19 
AnswerRe: Condition Always true when checking for "undefined" in Javascript Pin
Kornfeld Eliyahu Peter3-Aug-14 22:55
professionalKornfeld Eliyahu Peter3-Aug-14 22:55 
AnswerRe: Condition Always true when checking for "undefined" in Javascript Pin
Graham Breach3-Aug-14 22:56
Graham Breach3-Aug-14 22:56 
AnswerRe: Condition Always true when checking for "undefined" in Javascript Pin
Kornfeld Eliyahu Peter4-Aug-14 0:15
professionalKornfeld Eliyahu Peter4-Aug-14 0:15 
GeneralRe: Condition Always true when checking for "undefined" in Javascript Pin
Vimalsoft(Pty) Ltd4-Aug-14 5:39
professionalVimalsoft(Pty) Ltd4-Aug-14 5:39 
GeneralRe: Condition Always true when checking for "undefined" in Javascript Pin
Graham Breach4-Aug-14 9:18
Graham Breach4-Aug-14 9:18 
AnswerRe: Condition Always true when checking for "undefined" in Javascript Pin
Kornfeld Eliyahu Peter4-Aug-14 18:38
professionalKornfeld Eliyahu Peter4-Aug-14 18:38 
GeneralRe: Condition Always true when checking for "undefined" in Javascript Pin
Graham Breach4-Aug-14 22:13
Graham Breach4-Aug-14 22:13 
AnswerRe: Condition Always true when checking for "undefined" in Javascript Pin
Tushar Guru8-Sep-14 21:59
Tushar Guru8-Sep-14 21:59 
QuestionNewbie Question On jQuery Selectors Pin
Richard Andrew x641-Aug-14 17:03
professionalRichard Andrew x641-Aug-14 17:03 
AnswerRe: Newbie Question On jQuery Selectors Pin
thatraja1-Aug-14 18:09
professionalthatraja1-Aug-14 18:09 
GeneralRe: Newbie Question On jQuery Selectors Pin
Richard Andrew x641-Aug-14 18:28
professionalRichard Andrew x641-Aug-14 18:28 
QuestionGenerate geofence for route (pointA to pointB) Pin
JANANDOJAN28-Jul-14 21:19
JANANDOJAN28-Jul-14 21:19 
AnswerRe: Generate geofence for route (pointA to pointB) Pin
JANANDOJAN29-Jul-14 23:02
JANANDOJAN29-Jul-14 23:02 
GeneralRe: Generate geofence for route (pointA to pointB) Pin
Kwod128-Dec-20 11:01
Kwod128-Dec-20 11:01 
QuestionUsing json and jquery on page not working Pin
Member 1094998624-Jul-14 8:36
Member 1094998624-Jul-14 8:36 
QuestionRe: Using json and jquery on page not working Pin
ZurdoDev24-Jul-14 10:07
professionalZurdoDev24-Jul-14 10:07 

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.