Dear all,
I must be missing something... I just can't get a simple ig:datapicker to work!I have aspx page without master page and tried to follow different tutorials or help file guidelines, but just can't get it to work.
With the Infragistics.loader.js, i always got some error in another js file.
Could someone give me a live example by attaching it to this post?
Thank you in advance!
Hi Kelvin Liu,
Here is an example using loader instantiating 2 igDatePickers with different width. You need just to replace references with your own location.
<head>
<meta charset="UTF-8">
<script src="../../scripts/modernizr.min.js"></script>
<script src="../../scripts/jquery.min.js"></script>
<script src="../../scripts/jquery-ui.min.js"></script>
<script src="http://localhost/ig_ui12.2/js/infragistics.loader.js" type="text/javascript"></script>
<script>
$.ig.loader({
scriptPath: 'http://localhost/ig_ui12.2/js/',
cssPath: 'http://localhost/ig_ui12.2/css/',
resources: 'igShared,igEditors,igValidator'
});
$.ig.loader(function () {
$('#datePicker').igDatePicker({ width: "220px" });
$("#datepicker1").igDatePicker({ width: "200px" });
</script>
</head>
<body>
<input id="datePicker" type="text" /> <br />
<input id="datepicker1" type="text" />
</body>
Thanks,
Dear Todor Paskalev,
I still have a question... while i can run this example in a html page, I wonder how it goes for an aspx page?
Could you please help me on this one too?
HI Kelvin,
It will be fast if you send me your solution archived, so I can help you faster.
Here it is :
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="exampleDatePicker.aspx.cs" Inherits="exampleDatePicker" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><head runat="server"> <title></title>
<script type="text/javascript" src="../js/modernizr.min.js"></script> <script type="text/javascript" src="Scripts/jquery-1.4.1.js" type="text/javascript"></script> <script type="text/javascript" src="../js/jquery-ui.min.js"></script> <script type="text/javascript" src="../../js/infragistics.loader.js"></script>
<script type="text/javascript">
$.ig.loader({ scriptPath: '../..//js/', cssPath: '../..//css/', resources: 'igEditors' });
$.ig.loader(function () { $('#datePicker').igDatePicker({ width: "220px" }); });
</script></head><body> <form id="form1" runat="server"> <div> <input id="datePicker" type="text" /> </div> </form> </body></html>
Got error : Unable to get value of the property 'loader': object is null or undefined...
Hi Kelvin,
Have you tried change these:
scriptPath: '../..//js/',
cssPath: '../..//css/',
into this:
scriptPath: '../../js/',
cssPath: '../../css/',
Hello Todor,
sorry for the late reaction to your message. I kinda lost focus... things came across.
I'll try it as soon as possible!
Thank you again for your help!