IBM Worklight 6.1 - Failed re-generating the iPhone native folder
Try the following:
- Close Eclipse
- Locate your temp folder (Windows, OS X, Linux)
- Delete the
wlBuildResources
folder - Open Eclipse
- Re-build
IBM Worklight 6.1 - Settings page not disappearing
Make sure to Product > Clean the project in Xcode after the re-building in Eclipse.
If this somehow did not help, then:
Delete the app from the device / reset the iOS Simulator and re-run, then it will disappear. This is "cache residue" in the OS.
IBM Worklight - does not re-generate iphone .zip in iphone enviroment's package folder
Starting Worklight 6.2, the package folder that used to exist under the iphone folder has been removed.
If you'd like to create a zip of your generated Xcode project (= the iphone\native folder after you select Run As > Run on Worklight Development Server), find the native folder in your file system and zip it yourself.
You can find the native folder's location by right-clicking on it in Eclipse and select Properties.
IBM Worklight 6.1 - How to add custom written native code from Eclipse to Xcode?
If you delete the native folder, then any user-files you've placed in it will be deleted as well. When building the application again after deleting the native folder Worklight can only re-generate the Worklight-files, not user-files...
Your files are your responsibility.
Thoughts:
You can place the class files (the .m and .h files) in the
iphone\nativeResoures\Classes
folder (create thisClasses
folder). Now upon every build in Worklight Studio the class files will be copied from theiphone\nativeResources\Classes
folder to theiphone\native\Classes
folder. So this is a sort of a back-up in case you delete the native folder.But note! Copying via nativeResources or manually placing the class files in the
iphone\native\Classes
folder in Eclipse, is not enough. Eclipse does not know how to reference your class files in the Xcode project. This is something you must do in Xcode so that they will be referenced in the project's .pbxproj file.Eclipse cannot do this for you and I would not recommend on doing this referencing manually.
This is also explained in the "Adding native functionality to hybrid application with Apache Cordova plugin" training module provided in the IBM Worklight Getting Started training materials.
If you develop in Mac, then you can open the .xcodeproj file (located in the native folder) from the Eclipse workspace after you build the project; this means that any changes you will do in Xcode will be part of your project in Eclipse (because you are working on the same files)... So this too is a way to ease on development.
But be careful if you do this while also using the nativeResources approach, because then you will lose your changes in Xcode upon build in Eclipse.
You can use both of these approaches if you act carefully. Always backup your class files to the nativeResources folder before building in Eclipse after changing the .m or .h files in Xcode.
You are working with 2 IDEs, so you need to juggle...
IBM Worklight 6.1 - Unable to deploy upgraded project
Unfortunately this currently works for me.
- In Worklight 6.0.0.1 I've created a new Worklight project and application with the Android environment, built and deployed it
- I then exported the Worklight project as a .zip file
- In Worklight 6.1.0 I've imported the above .zipped project, built and deployed it
- Ran the generated Android project in the Android emulator
This was with a blank new app; it's possible yours is more intricate than that.
Suggestions:
- Delete the native folder and re-build and deploy.
- Make sure to back-up any native Java classes and other artifacts you may have previously added to the native folder.
- Provide your Worklight project (the original from 6.0.0.x) in a Dropbox download link for analysis...
Worklight 6.1 - All Build fails and gives java.lang.NullPointerException
Try the following:
- Delete the native folder
- Close Eclipse
- Locate your temp folder (Windows, OS X)
- Delete the
wlBuildResources
folder - Open Eclipse
- Re-build
If you have native code in your native\ folder, you can do the following for Android (and similarly for iOS):
- copy android\native\res\xml\config.xml to android\nativeResources\res\xml folder (if the folder doesn't exist, create it)
- copy android\native\src\com\your-app-name\*.java files to android\nativeResources\src\com\your-app-name folder (if the folder doesn't exist, create it)
- copy android\native\AndroidManifest.xml to android\nativeResources folder
This way you do not need to fear removing the native folder; upon build time the files will be copied to their location in the native folder.
Related Topics
How to Control Avassetwriter to Write at the Correct Fps
Optional Binding Succeeds If It Shouldn'T
How to Ensure to Run Some Code on Same Background Thread
Alert When New Version of iOS App Is Available
Fonts Not Displaying in Interface Builder
Apple Watch - Only Getting Data If App on Phone Is Active
How to Change a Swiftui Color to Uicolor
Finding Distance Between Cllocationcoordinate2D Points
How to Add Custom Text in Nsdateformatter's Format String
How to Customise Uislider Height
How to Add Text, Shape and Signature in Photo Markup with Pencil Kit