DXHTML gantt won't load when launched on IIS 7

When I launch the site on IIS 7 the dxhtml scripts throw an error. It’s working in DEV mode. The paths are relative as well not absolute. Any advice?

in dxhtmlgantt line 1

Uncaught TypeError: Cannot set property 'innerHTML' of null at Object.n._init_html_area (dxhtmlgantt:1) at Object.n._reinit (dxhtmlgantt:1) at Object.n.init (dxhtmlgantt:1) at n.value (dxhtmlganttservices:1) at n.value (dxhtmlganttservices:1) at Object.<anonymous> (hondaAjax.js:91) at c (jquery:1) at Object.fireWith [as resolveWith] (jquery:1) at b (jquery:1) at XMLHttpRequest.<anonymous> (jquery:1)

Hello.

Does it work without data loading?
It seems like the problem is in gantt initialization.
Are you sure that you’ve send correct parameter to gantt.init function. Possibly this block doesn’t exist when you’re trying to initialize gantt.
See article: docs.dhtmlx.com/gantt/api__gantt_init.html
If it still doesn’t work for you, could you provide some demo where issue can be reproduced or link to problematic page?

Hi,
the error stack trace starts with XHR request, can you check the response body of that ajax request?
Gantt itself is completely client-side component, all logic is done with JS in a browser and is completely indifferent to the web server that is used to serve html/js/css to browser.
Things that could work differently depending on server are backend handlers for data loading and saving, which probably cause issue in your case.
Checking the response body should give you an error description (you may need to disable customErrors in web config). Quite often it’s the database connection - when you run app on IIS, it will be launched by IIS user which may not have permissions that your user account have, e.g. if you’re attaching database file in your connection string - in most cases it won’t work by default.

Sten,

that seems to be the issue, let me try to refactor the code a little and I will post an example.

Does it work without data loading?

No.

It won’t reach my gantt.initFunction. The dxhtmlgantt.js isn’t loading at all. It’s throwing an error at this._obj=newTypeOf(t); I could see that t = “gantt_here” but this._obj is null. Show this be loaded before jquery?

After hours of searching I found out that none of my JavaScript files were being packaged when I published the app. Inside of of my scripts folder was empty. I had to delete all of my .jsx files and then recreate them.