Friday, May 24, 2013

JHeadstart - Forms2ADF migration

This post will be showing how to install Jheadstart extension in jdev and how to use forms2adf generator tool which comes with Jheadstart to convert oracle forms to ADF Screens.

Below is the file consisting of Oracle forms ,Schema and Xml's converted from oracle forms which are used in this tutorial.

Tutorial Files Download

Install Oracle JHeadstart Using “Check for Updates”

Note: In order to install full version of Jheadstart having forms2adf generator tool, one must be connected to oracle intranet while performing following steps.
Oracle JHeadstart is an Oracle JDeveloper extension (or "plug-in") that you install using JDeveloper's "Check for Updates" functionality.

Run the "Check for Updates" wizard
With JDeveloper 11.1.2 running, choose Help | Check for Updates... from the main menu. Click (Next>)on the Welcome page of the Check for Updates dialog.

Select the Source for Extensions
Ensure that you have selected the Open Source and Partners Extensions update center, then click (Next >).



Select the Oracle JHeadstart Version Extension to Install
Enter jh in the search field, and choose the Oracle JHeadstart .
Jdev will ask to restart. Click ok and jdev will restart with message that Jheadstart is successfully installed.


 Forms2ADF Conversion
First we will create a normal Fusion Web Application as shown in below screenshot.

Now we have a normal fusion web application. Next step is to run Forms2ADF generator and convert Oracle Forms to ADF BC. Follow the below steps.Click new and select forms2adf convertor like below.



Click next and click browse on next screen for selecting .fmb or .xml files to convert into ADFBC.


 After selecting files, screen will look like below:

Leave the default setting in next page as below and click next.


Now we need to give the DB connection of the schema being accessed by oracle forms.


 So DB Connection is created below. Click ok


We now have a connection to the schema used by oracle forms. Click OK and Next .

 On the next page leave the package names as it is and click next.


On next screen, provide the view controller project name and do next.



 Click finish on the summary screen.


 Now let’s see the output of Forms2ADF Generator.

We can see the ADF BC generated in Model Project. So now we are done with ADF BC. Now let’s generate the View Layer with the power of Jheadstart. Let’s make view project Jheadstart enabled. Right click on view project and click “Enable Jheadstart on this project”.


 So now Jheadstart is enabled on the project.Now follow the below step to synchronize the service in BC to view layer.

 Now click the button shown in screenshot below and press ok after it.

 Now we will generate the view layer. Right click on view project and click generate as follows.
 This will generate all the task flows, JSFF, templates etc required by view layer.



 Now just save the view controller project and run it on local WLS.


Following is the output of the Oracle Forms which are converted into ADF Screens.






26 comments:

  1. Hi Rohan,

    Nice blog.

    Can you specify the limitations of JHeadStart?
    And how about pl/sql?

    Regards,
    Deepak

    ReplyDelete
  2. Hi Deepak,

    Jheadstart forms2adf has lot of limitations. It does not convert Pl/SQL logic fully.

    Check out below link by Steven

    https://forums.oracle.com/message/10736083#10736083

    Thanks
    Rohan

    ReplyDelete
  3. Hi Deepak,

    Jheadstart forms2adf has lot of limitations. It does not convert Pl/SQL logic fully.

    Check out below link by Steven

    https://forums.oracle.com/message/10736083#10736083

    Thanks
    Rohan

    ReplyDelete
  4. Hi Rohan,

    I have some queries are you still active on this Blog?

    Thanks,
    Riaz

    ReplyDelete
  5. Yes I am and will be always active here :)
    Please tell me !

    ReplyDelete
  6. Hi Rohan,

    I am new to JHeadStart. We are in a process of migrating Oracle 10g forms to ADF. When I have tried to migrate a sample form which i designed , Forms2ADF tool could able to build an ADF application.But this was not true in the case of a complex form. I think i might be missing some configurations which are to be done.I am in a deadlock situation, your help is deeply appreciated.

    Thank you,
    Srikanth.T

    ReplyDelete
  7. Hi,



    Are there migration issues we you use JHeadStart 11g (11.1.28) with Forms2ADF Generator for migrating Forms 10g? We are facing issues as even simple Forms 10g are not getting migarted properly when we are trying the same with JHeadStart 11g (11.1.28) with Forms2ADF Generator.After migartion UI of the ADF pages are highly misaligned Text Field with Height= 1 and Width = 15 are getting migarted as Rows= 500 and Columns=528.



    Quick response is highly appreciated.



    Thanks,
    Srikanth.T

    ReplyDelete
  8. Hi Srikanth, Are you able to convert the forms successfully? If yes, can you send me the zip of application or screenshots how they are being done.

    ReplyDelete
  9. Hi Rohan,

    Thanks for the response. After huge fight we could able to migrate the forms, but we did huge work in aligning the UI.
    One more question is, The save button in the form is not working as expected. Itw neither saves the data nor through any exception.



    Do i need to change any thing?

    Srikanth.T

    ReplyDelete
  10. Hi Srikanth. I really cannot tell why Save button is not working for you. It should work ideally. Can you send me the zip of your code so that I can look into it.?

    All the best.
    Thanks
    Rohan

    ReplyDelete
  11. Hi Rohan,

    While saving the form, an error message is popping up which is checking for date format. Even after removing the date field from JSF also the same thing is happening. Where is this validations are configured?

    Can you please help me understand whether the triggers written in the forms will be migrated to ADF by Forms2ADF generator?

    How can i share screenshot of my error?

    Thanks,
    Srikanth.T

    ReplyDelete
  12. Hi Srikant,
    General validations are still in EOs. Forms2ADF generator is just to convert Oracle Forms to ADFBC. Rest everything is same as normal ADF Application.

    Triggers will not be written when we migrate forms using Forms2ADF generator. Forms2adf generator has lot of limitations. Please look at link below.

    https://forums.oracle.com/message/10736083#10736083

    You can anytime send me an email at er.walia@gmail.com for any queries or problems.

    Thanks
    Rohan

    ReplyDelete
  13. Hi Rohan,

    After huge fight and understanding the limitations of Forms2ADF tool, we have started new development using JHeadStart.In JHeadStart how can we define the attribute type i.e textBox or checkbox.I have changed the Display Type as check box in Application Definition Editor but it is prompting for Domain. I don't have any idea of this Domain and how to associate it with the field.

    Thank you,
    Srikanth.T

    ReplyDelete
  14. Hi Rohan,

    Thanks for the usefull post. How do I connect to oracle intranet? I have a customer support account.

    Eric

    ReplyDelete
  15. Hi Eric,
    You can only connect to oracle intranet if you are oracle employee.

    Thanks
    Rohan

    ReplyDelete
    Replies
    1. Thanks for your prompt reply and a wonderfull post. Its the only userfull post that I could find on the net on migrating oracle forms to ADF.

      Unfortunately, I'm not an oracle employee. Just a consultant developing forms and reports. Currently i'm planning to migrate my clients application to ADF, Jheadstart seems to be a viable solution.

      Is there anyway for one to test the tool before acquiring the licences?

      Delete
    2. Sorry to say Eric you cannot test this tool,you can get the tool through oracle consulting.
      Thanks.

      Delete
  16. Hi Rohan,
    I have downloaded " jhs11.1.2.1.28-install" evaluation extension. It has limitation ten views and donot support FORM2ADF . I want for my practice can u help me how i can do this practice.

    ReplyDelete
  17. hello Rohan Sir,
    i am converting form6i to ADF BC and when i right
    click on viewController to select Run.
    At log window following message shown:

    Target ViewController not runnable using default target JhsCommon-beans.xml

    Plz sir help me.

    ReplyDelete
  18. Hi Rohan,
    I have been working with jHeadStart but facing some issue while forms2adf generator. Basically when form2adf generator completes(converted from fmb to xml as input), it does not creates the data control in a well fashioned manner i.e. when I click + to respective data control, they hvae only options commit & rollback rather than option for respective LOVs. Additionally the extracted xml doesn't have a proper name i.e. generated file is _extracted.xml instead of filename_extracted.xml. Moreover when I run the application it shows the plain xml of Home.jsf rather than the rendered web page. Please help me.

    ReplyDelete
  19. Hi Rohan,

    We are trying to migrate forms10G to ADF using Jheadstart 12C Evaluation copy. We are getting following error. Kindly suggest

    Reported by logger: oracle.jbo.dt.objects.JboException
    oracle.jbo.dt.objects.JboException
    oracle.jbo.dt.objects.JboException
    o.jbo.dt.objects.JboException.printStackTrace(JboException.java:87)
    o.jbo.dt.objects.JboPackage.getLocalObjectsList(JboPackage.java:812)
    o.jbo.dt.objects.JboApplication.getLocalObjectsList(JboApplication.java:4883)
    o.jbo.dt.objects.JboPackage.getObjectsList(JboPackage.java:803)
    o.jbo.dt.objects.JboApplication.getObjectsListInternal(JboApplication.java:4917)
    o.jbo.dt.objects.JboApplication.getObjectsList(JboApplication.java:4908)
    o.jbo.dt.objects.JboPackage.getChildren(JboPackage.java:855)
    o.jheadstart.dt.jmig.target.bc4j.BC4JComposer.findPackageInApplication(BC4JComposer.java:411)
    o.jheadstart.dt.jmig.target.bc4j.BC4JComposer.getPackage(BC4JComposer.java:374)
    o.jheadstart.dt.jmig.target.bc4j.BC4JComposer.registerNestedAppModule(BC4JComposer.java:442)
    o.jheadstart.dt.jmig.target.bc4j.BC4JComposer.compose(BC4JComposer.java:214)
    o.jheadstart.dt.jmig.MigrationRunnable.compose(MigrationRunnable.java:432)
    o.jheadstart.dt.jmig.MigrationRunnable.migrate(MigrationRunnable.java:282)
    o.jheadstart.dt.jmig.MigrationRunnable.run(MigrationRunnable.java:134)
    o.i.dialogs.ProgressBar.run(ProgressBar.java:961)
    j.lang.Thread.run(Thread.java:748)

    ReplyDelete
  20. Hi Rohan,

    We are trying to migrate forms11g to ADF using Jheadstart 12C Evaluation copy. We are getting following error. Kindly suggest
    Reported by logger: oracle.jbo.dt.objects.JboException
    oracle.jbo.dt.objects.JboException
    oracle.jbo.dt.objects.JboException
    o.jbo.dt.objects.JboException.printStackTrace(JboException.java:87)
    o.jbo.dt.objects.JboPackage.getLocalObjectsList(JboPackage.java:812)
    o.jbo.dt.objects.JboApplication.getLocalObjectsList(JboApplication.java:4883)
    o.jbo.dt.objects.JboPackage.getObjectsList(JboPackage.java:803)
    o.jbo.dt.objects.JboApplication.getObjectsListInternal(JboApplication.java:4917)
    o.jbo.dt.objects.JboApplication.getObjectsList(JboApplication.java:4908)
    o.jbo.dt.objects.JboPackage.getChildren(JboPackage.java:855)
    o.jheadstart.dt.jmig.target.bc4j.BC4JComposer.findPackageInApplication(BC4JComposer.java:411)
    o.jheadstart.dt.jmig.target.bc4j.BC4JComposer.getPackage(BC4JComposer.java:374)
    o.jheadstart.dt.jmig.target.bc4j.BC4JComposer.registerNestedAppModule(BC4JComposer.java:442)
    o.jheadstart.dt.jmig.target.bc4j.BC4JComposer.compose(BC4JComposer.java:214)
    o.jheadstart.dt.jmig.MigrationRunnable.compose(MigrationRunnable.java:432)
    o.jheadstart.dt.jmig.MigrationRunnable.migrate(MigrationRunnable.java:282)
    o.jheadstart.dt.jmig.MigrationRunnable.run(MigrationRunnable.java:134)
    o.i.dialogs.ProgressBar.run(ProgressBar.java:961)
    j.lang.Thread.run(Thread.java:748)

    ReplyDelete