jQWidgets Forums

Forum Replies Created

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts

  • arashmoeen
    Member

    Yea I understand that, but it’s strange how it just doesn’t work .. it’s a simple view, I remove all the pre generated codes by .net, then add a simple jqxbutton or even a new dataAdapter inside the document.ready and it doesn’t work… I tried loading the scripts directly into the view, bundle, shared _layout with any possible way of including the scripts but it just doesn’t seem to work 😐 I’ve no idea what I’m doing wrong because I already did use your 2.4.2 version in another mvc4 project and it just did work like a magic but for some crazy unknown reason I can’t make it work this time :\ any suggestions ?

    thanks


    arashmoeen
    Member

    I don’t know why the script tags are removed in the previous post of mine,

    @model KhoonehYab.Models.User
    @{
    ViewBag.Title = "Create";
    }
    <script src="~/Scripts/jqwidgets/jqxcore.js"></script>
    <script src="~/Scripts/jqwidgets/jqxdata.js"></script>
    <script type="text/javascript">
    $(document).ready(function () {
    var data = new $.jqx.dataAdapter([]);
    });
    </script>

    arashmoeen
    Member

    Peter even this is not working , and gives me an error “Uncaught TypeError: Cannot read property ‘dataAdapter’ of undefined” … it happens with any other jqwidget component even a simplest one jqxButton … can you please tell me what I might be doing wrong ?

    @model KhoonehYab.Models.User

    @{
    ViewBag.Title = “Create”;
    }

    $(document).ready(function () {
    var data = new $.jqx.dataAdapter([]);
    });

    Thanks


    arashmoeen
    Member

    Peter I’m not sure if this might help or not but I’ve added few alerts in jqxdata.js
    this is the beginning part of the minified version of jqxdata.js:

    alert(‘1’);
    (function (a) { alert(‘2’); a.jqx.dataAdapter = function (e, b) { alert(‘3’);this._source=e;this._options=b…

    it’s goes 1, 2 but not 3 … I really don’t know what’s missing here, now I’m pretty sure it doesn’t have anything to do with the version because I tried the older versions as well and encountered the same error it just doesn’t recognize the dataAdapter, could be the jquery? I’m really out of ideas…

    Thanks again.


    arashmoeen
    Member

    Hi Peter,

    Thanks for the fast reply and the link but I’m not using that method to get data from my controller, I’m just wondering why doesn’t it work with the new version, I used version 2.4.2 in another application and it worked perfectly with no problem although most of my functions were called outside document.ready function, I can’t really figure it out how to handle this and oh yea I wanna integrate it with knockoutjs that’s why I’m using this method.

    Thanks again for your hard work and help.

Viewing 5 posts - 1 through 5 (of 5 total)