2
votes

I am new to IBM worklight.I have created a application using Dojo mobile,Dragged and dropped the widgets into Rich Page Editor but when I run the app or check the result in preview,the widgets are not getting displayed

3
Is there any error log available? What device/environment are you testing in? Do have a code sample of what was generated that we could inspect? There's not much information here for us to work with to help you. - Nick Roth
Thanks Nick.But don't know what was the problem,attempted with 2-3 new projects and it displayed the view in preview and looks like this is problem in worklight - parag
Have you tried just making a simple HelloWorld type of app without adding any widgets? Have you tried manually creating these widigets instead of using drag-and-drop to add them? - Nick Roth

3 Answers

1
votes

Technically it shouldn't create any issue unless until something goes wrong, try to open the browser console, there must be something fishy which creating the issue.

If possible share the code to debug the issue otherwise it's tough to provide any pointers without having use case.

1
votes

Open your mobile app in a JavaScript Debug Environment (Firebug) and look for errors!!!

It could also be possible that the dojo.parser is not running. You can trigger that manually by doing the following:

Configure your application that dojo-parser wont get invoked automatically.

<script type="text/javascript" src="dojo/dojo.js"
    data-dojo-config="parseOnLoad: false">
</script>

Trigger parser after dom-ready event got fired.

require(["dojo/parser", "dojo/ready"], function(parser, ready){
    ready(function(){
        parser.parse();
    });
});
0
votes

In dojo, it won't render in the preview (not correctly if it does). Try to download the Android SDK and run it on the emulator. I have had the same issue with the browser simulator and Dojo mobile in a few apps. I don't use it often, but I haven seen the issue.