This thread was migrated from an old forum. It may contain information that are no longer valid. For further assistance, please post a new question or open a support ticket from the Customer Support portal.
Hi, did Kony support to import a xml-based android layout that created in Android Studio ? i Have create a layout that consist of text, button, and other elements. I wonder if that kony support to read my xml so i don't need to re-create those element in kony workspace.
Thank you for replying. What you share is creating a custom widget. I don't think that it is necessary to re-create a widget using kony custom widgets, because i think will take much time if i have many widgets and activity in my native Android. I resolve this by using FFI and calling "intent" function via "integrate third party --> custom library"
I am using AAR as library, before inject that AAR to kony, i create this function in my native android java file :
public static void wrapperKony (){
intent = new Intent(KonyMain.getAppContext(), MainActivity.class);
KonyMain.getAppContext().startActivity(intent);
}
where MainActivity.class is my class that consist of onCreate function. Since onCreate function task in Android Studio is to render all element in a xml layout, calling Intent that refer to MainActivity theoretically will render all element and it's styling + function. So i did that.
I call that wrapperKony function via FFI and put it in my Kony, and everything works as i want. Interestingly, calling an android activity which consisting a constraint layout in it's xml will lead apps to force close. But when it comes to Linear Layout or Relative layout, it run smoothly as if i run via native android studio. So far i didn't find another faulty with this methods.