How to detect that ADF page has completely loaded with OpenScript

In Selenium tests I use AdfPage.isSynchronizedWithServer to detect whether an ADF page has completely loaded. I attempted to do the same with OpenScript by doing something like:
boolean loading = true;
while (loading) {
String[] result = web.document("/web:window[@title='*']/web:document[@index='0']").executeJsFunction("AdfPage.PAGE.isSynchronizedWithServer()", null);
if (null != result && result.length > 0 && "true".equalsIgnoreCase(result[0])) {
loading = false;
} else {
think(5.0);
unfortunately this fails with
ERROR [1] Error in section Run at line unknown. An unexpected exception occurred in the script. Script section: Run. Caused by: Exception occured.
java.lang.Exception:
    at oracle.oats.scripting.modules.webdom.api.elements.DOMDocument.executeJsFunction(DOMDocument.java:1043)
Anyone know how to call ADF JS from OpenScript or alternatively what is the recommended way to make sure that the ADF page has loaded completely ?

Hi,
when user logged in set a attribute in the session using
sess.setAttribute("var","value");
Now in ur JSP get this attribute if its null then ur session has expired an send the user to login page.
sess = requset.getSession(false);
String/Object  value = sess.getAttribute("var");
if(value==null)
//send it to Login page
}

Similar Messages

  • Everytime I load a page or open a new tab everything freezes until that new page has completely loaded(i do not have the switch proxy add-on)

    That is exactly what is happening if you have more questions send me an e-mail.
    == This happened ==
    Every time Firefox opened
    == 1 month-ish

    You only see items on the about:newtab page if the history is enabled and the browsing cache is working (stores thumbnails).
    *Tools > Options > Privacy > Firefox will: "Use custom settings for history"
    *http://kb.mozillazine.org/Viewing_the_browsing_history_-_Firefox
    You can check the current cache usage on the about:cache page and in Tools > Options > Advanced > Network > Offline Storage.

  • How to detect when a page is in view with jQuery or javaScript?

    Is there a way a detect when a page is in view? Currently it seems that my document ready function is being called when the page is the next or previous page as well as the current page. Seems that this gets called twice... is there a reliable way to detect this?

    I ran into this alot. first thing is that when you are looking at a particular page, DPS is caching the pages around it, all around it, so it caches the top, right, bottom and left pages, which will launch things and play videos and what not.
    Here's the workaround for getting it to only launch when in view. set the autoplay time (I assume this is for a "webcontent overlay") to .125 seconds. it will start the clock only when the page (tile) is in view.
    don't know if theres an easier way, but that's how I do it and it works.

  • How to detect that Illustrator.Application is fully loaded (VB)

    Does anyone have a trick that they use to determine that the app is fully loaded? Is there a method available that I might be missing? I manage most of the time but I'd like to get this problem trapped. Looking for a method available in the Illustrator Scripting API preferably. Within VB Try/Catch isn't working in this instance...
    Thank you!   -TT
    (CC2014, VB.NET on WIndows 8.1.)

    So after a bit more investigation and understanding (and some sleep), I came up with some VB code to resolve my dilemma. Here's the code:
    Truth be told, my biggest problem was self-inflicted, as I somehow had the VS UI set to throw exceptions even on handled exceptions, leaving pretty much no one to blame but myself. :-( 
    imagecollection wrote:
    i Should do more with vb as it has more external potential then JS.
    let us know how you go.  
    Qwertyfly... -- thanks for your reply here. I truly hope that you do more in VB, as it gets pretty lonely here on this forum. :-)  Please let me know if you ever decide to get involved with VB. I'd be happy to help get you started. :-)
    -TT

  • How to verify that the user has changed table row data before db update

    Hi all,
    Iam using Oracle ADF with EJBs.
    I have a single selection table that displays rows of data returned from a function of my data control.
    The columns of my table are editable so that the user can change the data. The user selects a row, changes the data in one or more columns of the row and saves the data by means of a submit button. The code in the submit button, identifies the row of the corresponding iterator that the user clicked on and updates the data in the database (using the 'mergeEntity' function of the EntityManager)
    Before saving the data, I want to put some logic to check whether the user has actually changed some data to avoid unnecessary updates in the database . But for this I need a technique to detect that the user has indeed changed some data in the table row.
    One technique I have been using so far was to isolate the iterator row of the table and then query the corresponding row in the database table and compare their values.
    Except from dummy, this technique is not efficient if the table contains many rows.
    Moreover, in my case I have observed that on successive updates on the same row , the query on the database returns the new values (user changed values) and not the actual values contained in the database table. This means that when the user updates an iterator row the cached data affect also the results of the SELECT statement from the actual database table!!! Isn't this strange ?
    Can somebody propose me a neat method to detect when the user has changed the the data of an iterator row ?

    Hey Alan,
    The below solution seems overly complicated to me and can not be implemented without a custom screen and/or the use of JavaScript. Also, if your main concern is that a user may accidentally loose all their data because they closed the browser window or the session times out before they hit the save button then this solution does not help you.
    There are a couple of simpler approaches you can take here:
    # If the use of JavaScript is permissible you can hook into the windows 'onUnload' event, and pop-up a message box which gives the user the opportunity to cancel closing the window and save their case if they haven't already.
    # Implement an autosave feature by hooking into one of events provided by web determinations. A simple (but rather naive) way of doing this would be to hook into the OnRenderScreenEvent and call save on the interview session every time the event fires. This guarantees that all the data the user has submitted will aways automatically be saved, thereby removing the need to make sure the user manually saves their data before closing the browser.
    Automatically making Web Determinations close a browser window has to be done using JavaScript. However, doing so means that a) it won't work for people who turn off JavaScript, which is commonly done for accessibility reasons b) you'll likely run afoul of the browser's security mechanism (they generally won't let you close a window that you didn't open and some really don't like you doing that at all).
    Thanks,
    Kristy

  • Hello I am having problems viewing areas of a pdf...it's a form fillable pdf that someone else has completed and saved..I'm able to view all but the areas that have been filled in.. any info would help

    Hello I am having problems viewing areas of a pdf...it's a form fillable pdf that someone else has completed and saved..I'm able to view all but the areas that have been filled in.. any info would help

    Hi Bob, I just tried your suggestion, but the interactive PDF is in spreads by default, no way to change the setting. When I choose to view by single page in Acrobat, it displays a single spread.
    When I choose to view by spreads, it displays 4 pages, two spreads. That's the topic of this whole discussion, I believe. I do own CS 6 at home, however my employer supplied me with CS 5.5. And I have very little, if any, influence on purchasing.
    So, I have no good way to make an interactive PDF (with differing recto/verso headers and footers), that is accessible and shows the correct header/footer. It's either single pages (with one header/footer), or recto/verso headers/footers but PDF only as a spread, as well as I can tell.
    Unless you know something else I can do...
    Best, Marilyn

  • I  have a Mac Pro running OS X 10.8.2. Frequently the system fails detect a CD. Doesn't seem to make a difference if it contains music or is blank. I am unable to eject the CD. The system just doesn't recognize that a CD has been loaded.

    I  have a Mac Pro running OS X 10.8.2. Frequently the system fails detect a CD. Doesn't seem to make a difference if it contains music or is blank. I am unable to eject the CD. The system just doesn't recognize that a CD has been loaded.

    Step one, boot the new MBA into recovery mode (CMD+R on startup), launch Disk Utility, wipe the HD, and restore the OS. On reboot, use the Setup Assistant to do the migration. Details in Pondini's Setup New Mac guide.

  • How indesign detects that the images have been modified

    Hello,
    My problem is that all my images links are seen modified (yellow triangle) while the images don't have been modified.
    The modified dates are the same.
    All my images are on a unix server and indesign is used on Mac.
    How indesign detects that the images have been modified ?

    Thank you for your answer.
    When you say the time stamp you talk about the modification date in the box link info ?
    Because this date is the same on the image and in indesign and when I update the image this date doesn't change.
    the only informations that change when I update the links are the import date and the state (modified become ok)

  • Can you programatically detect that a form has been called by another form?

    Can you programatically detect that a form has been called by another form using Open_Form?
    When closing a form I want to do one thing if it was opened stand-alone and another thing if it was called using Open_Form by another form.
    Thanks in advance.

    Maybe, Tony, also
    GET_APPLICATION_PROPERTY built-in ; it can
    be used to retrieve information about the calling (parent) and called
    form (child).
    The following example describes a way to perform a query on the child form
    using a value from the parent form; if the form is a child form, it first
    executes a query, otherwise the form goes into insert mode automatically.
              WHEN-NEW-FORM-INSTANCE
              ======================
              BEGIN
                   :GLOBAL.APP_NAME := GET_APPLICATION_PROPERTY(CALLING_FORM);
                   IF :GLOBAL.APP_NAME IS NOT NULL THEN
                        EXECUTE_QUERY;
                   END IF;
              END;Regards

  • How can detect that cdrom drive were opened and closed?

    How can detect that cdrom drive were opened and closed?

    I'm sure there are more elegant and complicated ways to accomplish this using Windows SDK function calls to kernel32.dll or something extravagant like that, but if you want the bare-bones easy way to check if the CD-ROM tray is currently opened, then simply use System Exec to query the CD-ROM drive from the command line. One example of this is shown below.
    Use the command line function cmd /c d:, where d: is your CD-ROM drive. If the Standard Error output from System Exec.vi is "The device is not ready." followed by a carraige return and line feed, then voila, your CD-ROM drive is open. If not, it's closed. Anyone have a better idea? I'm sure one exists...
    Message Edited by Jarrod S. on 02-16-2006 12:23 PM
    Jarrod S.
    National Instruments
    Attachments:
    CDROM_Check.JPG ‏22 KB

  • I have a macbook pro with a broken video card. How do ensure that my data is completely erased before I sell it ?

    I have a macbook pro with a broken video card. How do ensure that my data is completely erased before I sell it ? Thanks

    1. Connect it to a monitor.
    2. Replace the hard drive.

  • How can I scan multiple pages to one file with MG 7120

    My printer does not have ADF. How can I scan multiple pages to one file on my MG 7120?

    Hi albabynyr,
    There is a program that comes with the printer called the IJ Scan Utility that can assist you with scanning multiple pages into a single file.  To scan using the IJ Scan Utility, please follow these steps:
    1. Start IJ Scan Utility by going to your Start menu, then selecting All Programs, then Canon Utilities, then  IJ Scan Utility (folder), then IJ Scan Utility (program).
    2. In the Canon IJ Scan Utility window that opens, click SETTINGS.... in the bottom right of the window. The Settings dialog box appears.
    3. Click the DOCUMENT SCAN option on the left pane of the window.
    4. In the right pane of the window, locate the SELECT SOURCE field and select the DOCUMENT option.
    5. Set the color mode, document size, and scanning resolution as required in the rest of the fields shown in the window. Click DOCUMENT SCAN ORIENTATION SETTINGS... to specify the orientation of the documents to be scanned.
    6. In the SAVE SETTINGS section of the window, you will select the save format and location of the document you are about to scan.
    a.) In the FILE NAME field, specify the name you would like to give the file. By default the filename will begin with IMG; you can remove IMG and change it to whatever you would like to name the file.
    b.) In the DATA FORMAT field, use the drop-down arrow to select the PDF (Multiple Pages) option.
    c.) In the SAVE IN field, please navigate to the area where you would like the file to be saved once it is scanned in. By default, the file will be saved in the DOCUMENTS folder.
    7. Once all settings have been selected, click the OK button at the bottom of the SETTINGS (DOCUMENT SCAN) window. The IJ Scan Utility main screen appears.
    8. Click the DOCUMENT button. Scanning starts. After a page has scanned, the screen to continue or end scanning appears. If you have more pages to scan, place the next page on the platen and click Scan.  Do this each time a page has completed scanning.  After the last page has been scanned, click Exit. Scanned images are saved in previously selected folder location specified in the SETTINGS... window. Click the CANCEL button to cancel scanning if needed during scanning.
    Hope this helps!
    This didn't answer your question or issue? Please call or email us at one of the methods on the Contact Us page for further assistance.
    Did this answer your question? Please click the Accept as Solution button so that others may find the answer as well.

  • Verify that this class has been marked with the @Entity annotation

    Hi,
    We have a App level shared lib which does all the JPA related query for an app. And each app can utilize the share lib to get the JPA related query to be done.
    For scoping the JPA between App . We have created EMF for each app.
    When one app run and does any JPA related action it works fine , but when we try to run second app we are seeing the following error when trying to do JPA specific action .
    the @Entity annotation.
    [2012-05-23T04:08:16.839-07:00] [WC_Spaces] [ERROR] [] [oracle.webcenter.spaces] [tid: [ACTIVE].ExecuteThread: '3' for queue: 'weblogic.kernel.Default (self-tuning)'] [ecid: 5825b814-2931-4ad5-8dc3-3e18f66992b7-00000004,0] [APP: webcenterCustom] [[
    java.lang.IllegalArgumentException: Unknown entity bean class: class oracle.webcenter.spaces.internal.repository.WcSpaceHeader, please verify that this class has been marked with the @Entity annotation.
    at org.eclipse.persistence.internal.jpa.EntityManagerImpl.find(EntityManagerImpl.java:648)
    at org.eclipse.persistence.internal.jpa.EntityManagerImpl.find(EntityManagerImpl.java:532)
    at oracle.webcenter.spaces.internal.repository.SpaceRepositoryUtils.refreshSpaceRows(SpaceRepositoryUtils.java:1791)
    Where WcSpaceHeader is an Entity.
    For creating emf per App this is the code
    private static EntityManagerFactory getEntityManagerFactory()
    String appName=Utility.getApplicationName();
    EntityManagerFactory emf=sEntityMgrFactory.get(appName);
    if(emf==null)
    emf=Persistence.createEntityManagerFactory("SpacesReposPUnit");
    sEntityMgrFactory.put(appName,emf);
    SpacesConstants.LOGGER.info("Caching" +
    "EMF for " +appName);  
    return emf;
    My persistence.xml
    <?xml version="1.0" encoding="US-ASCII" ?>
    <persistence xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd"
    version="1.0" xmlns="http://java.sun.com/xml/ns/persistence">
    <persistence-unit name="SpacesReposPUnit" transaction-type="RESOURCE_LOCAL">
    <provider>
    org.eclipse.persistence.jpa.PersistenceProvider
    </provider>
    <class>oracle.webcenter.spaces.internal.repository.WcSpaceHeader</class>
    <class>oracle.webcenter.spaces.internal.repository.WcSpaceUsrDetail</class>
    <class>oracle.webcenter.framework.service.jpa.WcCommonXlationEntity</class>
    <class>oracle.webcenter.spaces.internal.repository.WCNavigationActivity</class>
    <properties>
    <property name="eclipselink.session.customizer"
    value="oracle.webcenter.spaces.internal.repository.SpacesEclipselinkSessionCustomizer"/>
    </properties>
    </persistence-unit>
    </persistence>
    One more problem i am seeing in this is that . When i create an EM from EMF (which is diff for diff app) and doing some query i am getting a class cast Exception.
    (self-tuning)'] [ecid: 5825b814-2931-4ad5-8dc3-3e18f66992b7-00000004,0] [APP: webcenterCustom] [[
    java.lang.IllegalArgumentException: Unknown entity bean class: class oracle.webcenter.spaces.internal.repository.WcSpaceHeader, please verify that this class has been marked with the @Entity annotation.
    at org.eclipse.persistence.internal.jpa.EntityManagerImpl.find(EntityManagerImpl.java:648)
    at org.eclipse.persistence.internal.jpa.EntityManagerImpl.find(EntityManagerImpl.java:532)

    This is a class loader issue, somehow you have deployed the same classes in two places, so have two different versions of the classes.
    How, exactly have you deployed things, where are your domain classes?
    The issues is most likely that,
    Persistence.createEntityManagerFactory("SpacesReposPUnit");
    will always return the same factory once it has been deployed.
    If you pass a properties map to createEntityManagerFactory and set the property "eclipselink.session-name" to a unique value, then you should get a new factory.

  • How can I view 2 pages on Ipad 3 with retina?

    How can I view 2 pages on Ipad 3 with retina?

    For viewing PDF I use PDF Pen. It's awesome though some consider the app pricey. PDF expert is another one.
    Sometimes it depends on the book you are viewing. If its a PDF it will not show 2 pages that I am aware of.

  • I downloaded lion but it wont install, it says that the software has been tampered with. But i downloaded from the app store.

    I downloaded lion but it wont install, it says that the software has been tampered with. But i downloaded from the app store.

    I have been through the same process three times now. The downloaded file is 4.07GB. I deleted it and re-downloaded and I get the same error.

Maybe you are looking for

  • Neo2 Platnum - memory ratio issues, please help!

    hey all very strang stuff... just got a 3200+ winchester .90 CPU, its nice. also have 2x twinx corsair 3200 non LL ram. idea: I had in mind that since my ram doesnt OC very well (220 max) I was going to get the neo2 and play with the FSB and set the

  • Deployment profiles problems in 9.0.3.3

    create a deployment profile as "Business Components EJB Session Bean" and click OK. a xxx.bcdeploy file was created successfully. Later on go back to this file, right click and choose "Settings" to edit the deployment profile but found ALL the applic

  • PR Auto close after PO

    Dear All.                    Any standard configuration is there to close PR after PO creation. if available please provide the config steps Regards Kumar.

  • Problem using clone stamp tool

    I have a composition which I created from prem pro dynamic link. There is only one layer in my composition (a .mov clip) which I have removed an unwanted item from using the clone stamp tool however the item is still showing in my comp and therefore

  • How to create dataslices IP with abap

    Dear Experts, I need to CREATE dataslices in IP via abap but don't really know how to do it, any FM that I can use? Hope somebody can help me... Thanks !