When does this showMessage will be shown . I have written a small program please tell me
why this showmessage is not shown and if shown where it will be shown ??
<html>
<head>
<link rel="stylesheet" type="text/css"
href="http://ajax.googleapis.com/ajax/libs/dojo/1.6/dijit/themes/claro/claro.css"/>
<script src="http://ajax.googleapis.com/ajax/libs/dojo/1.6/dojo/dojo.xd.js"
djConfig="parseOnLoad: true">
</script>
<script>
dojo.require("dijit.form.DateTextBox");
</script>
<script>
function callMe()
{
if(dijit.byId("fromDate_out").isValid())
showMessage("Selected date is fine.");
else
showMessage("Not Valid");
}
</script>
</head>
<body class="claro">
<div dojoType="dijit.form.DateTextBox" require="true" id="fromDate_out" placeHolder="From Date" onChange="dijit.byId('fromDate').constraints.max =arguments[0];" ></div>
<input type="button" onclick="callMe()"/>
</body>
</html>
Make sure that you fix the mistake
require="true", it’s supposed to berequired="true".The showMessage method will be called when you click the button. If fromDate_out does not contain a value, showMessage will be called with “Not valid” (assuming that you fixed the “require” typo above).
We do not know what showMessage is, so if you need help with it, you have to post it as well.