Javascript API $x_uptill problem

Hi people,
I have a little boring problem...
Simply I made this function in order to hide & show a page element with it's label
function ApplyVisible(obj, Visible){
var lblobj = html_GetElement(obj);
labels = document.getElementsByTagName("LABEL")
for(var i = 0; i < labels.length; i++){
if(labels.getAttribute("for") == lblobj.id){
var lbl = labels[i];
break;
var td = $x_UpTill(obj, 'TD');
if ($x_UpTill(obj, 'FIELDSET'))
var fieldset = $x_UpTill(obj, 'FIELDSET');
but the function $x_UpTill raise an exception when an upper node element with FIELDSET tag does not exists
E is null
http://myhost:myport/i/javascript/apex_3_1.js
Line 1
What I'm wrong?
Thanks all
Claudio

Hello,
>> I don't want to hide all table row
APEX uses tables to layout items. Each item is comprised of two table cells – one for the item label, and one for the input part (element in APEX terms). So, if you want to hide a single item (label and element) on your page, which reside on a single form row, the JavaScript function I mentioned is the one to use. If you have more than one item on the form row, you’ll need different approach, depends on your exact layout. In this case, $x_UpTill() will probably not be relevant, because you’ll be looking for sibling nodes, and not parent ones.
And to your original JavaScript code. It’s very hard to debug a code without see the actual page and item layouts, so I’ll speak in general.
First, the ‘fieldset’ tag doesn’t wrap the label part of the item, only the element part, so cascading up to it, will not hide the label.
Second, the ‘label’ tag is not used with all the items, even not with all the items that wrapped with ‘fieldset’. For example, a date picker item includes ‘fieldset’ but not ‘label’. In your code, you are retrieving all the ‘label’ tags, but for many items on your page, it might return null.
If you want something more specific, you should post an example on apex.oracle.com.
Regards,
Arie.
Please remember to mark appropriate posts as correct/helpful. For the long run, it will benefit us all.

Similar Messages

  • Map Builder JavaScript API

    Hello everybody,
    I'm a student who is currently working with Oracle for the first time. I developed an Web mapping application by using Oracle XE Database (10g), Oracle Map Viewer and corresponding Map Builder (the latest version). I choose the JavaScript API for the implementation of this application.
    The reason for this post is one particular problem that I encountered. I want to extract the X and Y coordinates (which are naturally stored as SDO_GEOMETRY in my database) for certain features that are visible in my map window (this features belong to themebasedFOIs). I know that the x and y coordinates (and other attribs) are easily accessible for the JavaScript Client if the coordinates are stored in own columns (additionally to the information stored in the SDO_GEOMETRY) ... but that is not the case!
    I searched the JavaScript API, the Internet, this forum and it took me a long time ... but I didn't come across any possiblity to manage this. So does anybody who reads this post see a possibility to get my X and Y coordinates from my HTML application that is build with JavaScript API???
    I will be very thankful for any advices and/or hints... :-)
    With regards

    hi, we don't return the geometry back to the client unless the foi is a point.

  • External use of Javascript API

    Hello All,
    I was wondering two things.
    1 - What is the file that contains the javascript API functions.
    2 - Could one use this outside the realm of APEX. --> I have a desktop application which connects to APEX and does a whole bunch of things. I have have however run into a problem. CLOBS. In apex I can use $S , but outside of APEX, what would be the equivalent.
    I know this is a shot in the dark, but well knowing does nto hurt.
    Thanks
    Jan

    1) These files can be found in /i/javascript
    $s for instance is found in apex_4_1.js
    2) Depends on the function. You can use these js files to track down exactly how Apex actions these tasks (I do this sometimes to learn a little more javascript), but if it ultimately talks to the db, then obviously you can't use that out of context.

  • Shockwave 11 Javascript API

    I'm seeking any information regarding the javascript API for
    Shockwave 11. Does it exist? Is there documentation?
    I've seen one example using a javascript to control the
    shockwave player created for 8.5 at famous3D website, but it
    appears to be broken now with version 11. I've been having a
    serious problem with the Shockwave ActiveX Control since upgrading
    to 11. I'm hoping the Javascript API could be a potential
    workaround.
    Any info would be greatly appreciated! Thanks in
    advance!

    _PlayerOne_,
    No, I haven't made any progress on this. I can confirm that
    it happens also in Director 11 and Director MX 2004. Director 11 is
    a currently supported product and yet it experiences the same
    error. I have also posted this to the director forums but no
    response there. I have also explored calling it from Swing in Java,
    same effect. Calling it in a Power Point presentation with Visual
    Basic also causes it to crash.
    I got the "compatibility player" portion to load but it
    didn't have any effect on this issue.
    No solution has presented itself. Currently, I am advising
    our company and our customers to revert to the 10.3.0.24 version
    and to avoid installing the 11.0.0.429 version until it gets fixed.
    Unfortunately, this means Vista performance is poor but luckily our
    customers haven't moved entirely to Vista.

  • Javascript API - Selection Refresh

    I'm building a command with JSFL to run through the list of
    objects in a frame one at a time and turn them into symbols. The
    purpose is to automate making any text boxes into symbols with the
    text string for it's name, however, I also want to be able to name
    bitmap images in the frame as well, so I have an XML-UI Panel pop
    up when/if it's necessary to name each bitmap.
    So far it works perfectly, but for one thing: the screen
    doesn't refresh the selection until after the first panel pops up
    and a name is inserted. This is a problem because I don't know
    which bitmap (if there's more than one) I'm naming, because all
    items on in the frame are selected. After that first panel pop-up,
    the selection refreshes appropriately, highlighting the objects one
    at a time as I need to name them - it's just that first panel that
    doens't work.
    Here's the code I have so far:
    D = fl.getDocumentDOM();
    SEL = D.selection;
    MSEL = new Array();
    for (i=0;i<SEL.length;i++){
    if (SEL
    .elementType == "text"){
    MSEL[0]=SEL;
    D.selectNone();
    D.selection = MSEL;
    var myText = "t|"+D.selection[0].getTextString(0, 15);
    D.convertToSymbol("movie clip", myText, "top left");
    } else if (SEL
    .elementType == "instance"){
    if (SEL.instanceType == "bitmap"){
    MSEL[0]=SEL
    D.selectNone();
    D.selection = MSEL;
    var result = D.xmlPanel("file:///C:/.../blah.xml");
    if (result.dismiss == "accept"){
    gName = "g|"+result.bN; // bN is the UI-Panel input variable
    to name the bitmap
    D.convertToSymbol("movie clip", gName, "top left");

    Andrew,
    we started working on the JavaScript API for Oracle Forms 11. We have a spec, which is a good way to start and I am confident that we will see this feature coming.
    Frank

  • Javascript API and server-generated URLs

    I'm creating a Shopify site for a client and part of the site is a complex Adobe Edge Animate animation. Shopify uses server-generated paths to files. My animation uses images and audio.
    It looks like the animation sets a base path set in the Publish settings then it sets everything itself in the Javascript runtime and associated files. With Shopify, I end up with image URLs that are like this one: "cdn//path//image.gif?234324". I don't have a absolute path with an absolute file name.
    Does anyone know of a way I can put these specific unique server-generated paths to the files needed for my animation in the files for my animation? Basically, can I customize and control the entire URL to all the files needed for my animation?
    I see how I can put any URL for assets in the edge.js file. My bigger problem, I think, is being able to customize the URLs for the edge.js and edgeActions.js files.
    If anyone has any ideas, I'd really, really appreciate it!

    I am getting close on this!  I'm hoping someone can help me figure out the last step.
    I am using an iframe and sandbox method to load the swf video player like this:
    <iframe id="playerFrame" src="player.html" sandboxRoot="http://localhost/air/" documentRoot="app:/"></iframe>
    So now the JavaScript API for the player actually works in player.html.   The BIG problem is that the videos are downloaded to the app-storage directory.  Well, based on AIR security, the iframe (non-application sandbox) content cannot access the application storage directory.  So now only videos that are in the app:/ location will load.  Unfortunately, this application downloads video from a central server and places them in the application storage directory.  Security also will not allow me to download to the app directory.  So I am in an endless circle!
    I can't use the API if I am in the application sandbox because there is no domain (sandboxRoot) available.
    The API works in the non-application sandbox, but I can't access the downloadable content.
    What am I missing here?  Surely, people have needed to interact with a SWF file using JavaScript and load dynamic content at the same time.

  • Local Javascript API and AIR

    I'm having a hard time describing this problem, but I'll try...
    Is there anything I can do to allow Adobe AIR to load a JavaScript API to interact with JW Player (longtailvideo.com)?  The API already exists, and I can port my AIR code over to an HTML page on my server and it works fine.   Longtail support boards say that the API will not load locally (either locally on a folder OR "locally" in an AIR app).  They said it is a restriction of Flash.  Is this correct?  I did put my HTML files on my desktop and the API did NOT load.  It only seems to load when I put it on my server and run it on a domain.
    I assume this is somehow related to security. JavaScipt cannot interact with Flash unless it is on a domain?  Is that correct?
    I can get the player to load and play video just fine in AIR.  However, the API never loads, so I cannot interact with it.
    This is the last piece of a very LONG project I have been working on, so any help would be greatly appreciated!    Is it possible to get AIR to "pretend" it is on a URL?  I tried referencing files with app:/, and that had no impact.

    I am getting close on this!  I'm hoping someone can help me figure out the last step.
    I am using an iframe and sandbox method to load the swf video player like this:
    <iframe id="playerFrame" src="player.html" sandboxRoot="http://localhost/air/" documentRoot="app:/"></iframe>
    So now the JavaScript API for the player actually works in player.html.   The BIG problem is that the videos are downloaded to the app-storage directory.  Well, based on AIR security, the iframe (non-application sandbox) content cannot access the application storage directory.  So now only videos that are in the app:/ location will load.  Unfortunately, this application downloads video from a central server and places them in the application storage directory.  Security also will not allow me to download to the app directory.  So I am in an endless circle!
    I can't use the API if I am in the application sandbox because there is no domain (sandboxRoot) available.
    The API works in the non-application sandbox, but I can't access the downloadable content.
    What am I missing here?  Surely, people have needed to interact with a SWF file using JavaScript and load dynamic content at the same time.

  • Fullscreen javascript api in edge?

    Hey Edge Animater! I don't get the fullscreen javascript api to work. I want to make a button to view pictures in complete fullscreen.
    So I use it's click function and paste the code from (How to Use the HTML5 Full-Screen API (Again) - SitePoint)
    var i = document.getElementById("myimage");
    // go full-screen
    if (i.requestFullscreen) {
        i.requestFullscreen();
    } else if (i.webkitRequestFullscreen) {
        i.webkitRequestFullscreen();
    } else if (i.mozRequestFullScreen) {
        i.mozRequestFullScreen();
    } else if (i.msRequestFullscreen) {
        i.msRequestFullscreen();
    inside, but it won't work.
    Anyone had the same problem or sees my failure?
    Some guy in the forum already asked about the right usage of the fullscreen api but no anweser!
    Peace Jill

    Yes, the plan is to add this feature in Oracle Forms 11
    Frank

  • Displaying a theme-based FOI layer as a whole image with javascript API v2

    Hi,
    I have looked the Oracle maps V2 tutorial developed in mvdemo.war application provided with Oracle Mapviewer v11.1.1.7. I have looked how to use theme-based FOI layers and I have not found how to set the "whole image" property for these layers. This feature is present in javascript API V1 and it greatly improves application performance. Our applications use this property very often.
    Is this property present in javascript API V2 but not documented?
    If it's not present, do you know if it will be?
    How can we show a layer with many geometry features and obtain the same performance we have now with the whole image property?
    Thanks,
    Arturo

    Hi,
    since this is a very crucial feature for us I'm very interested in that functionality as well. Is there a comparable functionality in the V2 API or will it be available in feature releases?
    Thanks
    Dominik

  • PDF embedding & Acrobat's JavaScript API

    Hello,
    I have two questions.
    I currently using Safari 1.3.2 and Acrobat Reader 7.0.9 to test an PDF document embedded in a Web page. In Safari 1.3.2 I get a "This operation is not allowed" warning when the HTML object element and the embed element are encountered.
    I have also tested it in Safari 3.0 on Windows, with plug-ins enabled in the Preferences and Acrobat Reader 8 installed. The PDF file is not shown and no warning is given either.
    So, does Safari 2.0 support embedding PDF files at all?
    My other question is, assuming Safari does support PDF embedding, whether it is possible to interface from an HTML page to the Acrobat plug-in via Acrobat's JavaScript API. In IE this is a simple as getting the object element by id and for example, invoking its Print() method. Is this possible in Safari?
    Thank you in advance,
    Adal Fraile

    Hello,
    I have two questions.
    I currently using Safari 1.3.2 and Acrobat Reader 7.0.9 to test an PDF document embedded in a Web page. In Safari 1.3.2 I get a "This operation is not allowed" warning when the HTML object element and the embed element are encountered.
    I have also tested it in Safari 3.0 on Windows, with plug-ins enabled in the Preferences and Acrobat Reader 8 installed. The PDF file is not shown and no warning is given either.
    So, does Safari 2.0 support embedding PDF files at all?
    My other question is, assuming Safari does support PDF embedding, whether it is possible to interface from an HTML page to the Acrobat plug-in via Acrobat's JavaScript API. In IE this is a simple as getting the object element by id and for example, invoking its Print() method. Is this possible in Safari?
    Thank you in advance,
    Adal Fraile

  • How to add a polygon to mapviewer using Javascript API

    Hi,
    I am using JavaScript API for the MapViewer.
    Using redlining tool, my application allows user to draw polygon onto the map.
    I would like to have union, difference and intersect tools. I know the back end logic can be done using using JTS or SDO_Union, SDO_difference, and SDO_intersection. but how do i display the result polygon on the map? Note that I am not going to store the polygon in the database.
    Thanks for any ideas.

    Hi,
    If I understand well you are using Oracle Maps. User do some redlining, then you somehow makes FOI polygons. Then you get the coordinates of the polygons and send them to the back-end where you can use spatial functions and get the coordinates of the new polygon.
    You can store those coordinates in i.e. hidden input field on page (if you use JSF it is very simple) and then use JavaScript to parse them and Oracle Maps API to create new FOI polygon and add it to mapviewer object. One disadvantage of this concept is that reloading of page (submit) is necessary.
    Branislav

  • How can i use  a adf javascript api

    hi
    can i use the adf javascript api for creating the AdfRichInputText .is there any producer
    to create the AdfRichTextInputText in javascript .plz guide me
    Thanks and Regard
    Message was edited by:
    Prapan Sol

    Hi,
    the ADF JavaScript API is not meant for you to create JSF components on the fly. For this you please use teh ADF Facesserver side components.
    The RichInputText component is defined by a pair of components, the AdfRichInputText and its Peer component. I don't know what your usecase is, but my impression is you are looking at it from the wrong end
    Frank

  • Getting error when updating the JavaScript API for Office and manifest schema files in your Visual Studio project from version 1.0 to 1.1

    Hi,
    I`m getting error message like "None of the apps in your project can be activated in the target. The manifest file of one or more apps contain API sets or Office applications that are not supported by
    the target Office client. To debug those apps, update manifest files to exclude any unsupported API sets or Office applications, and then start the project again. Alternatively, you can debug your apps by using Office 365 as a target." when when
    updating the JavaScript API for Office and manifest schema files in your Visual Studio project from version 1.0 to 1.1 in manifest file though i have added host elements.
    any help in this regard is highly appreciated
    Thanks,
    Santosh Sutar  

    Hi Satosh Sutar,
    Based on the description, you got the error message when you update the apps from version 1.0 to 1.1.
    From the error message, it seems the menifest include some settings no allowed in the new version. Would you mind sharing more detail about how you update the project?
    And here is an article about updating apps for Office and menifest schema files in the project for your reference:
    How to: Update the JavaScript API for Office and manifest schema files in your Visual Studio project from version 1.0 to 1.1
    Regards & Fei
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Is it possible to change out of the box Callout content for already existing library using some javascript API ?

    Is it possible to change out of the box Callout content (change DOM elements) for already existing library using some javascript API?
     API ?

    Hi,
    We can use CSS and jQuery to achieve it.
    Please add the following code into the Content Editor Web Part.
    <style type="text/css">
    .js-callout-content{
    display:none;
    .js-callout-mainElement span{
    display:none;
    .js-callout-mainElement{
    border-width:0px;
    </style>
    <script src="http://code.jquery.com/jquery-1.10.2.min.js" type="text/javascript"></script>
    <script type="text/javascript">
    $(function () {
    $("a[title='Open Menu']").click(function(){
    setTimeout(function(){
    $(".js-callout-body .js-callout-bodySection").eq(0).html("<span>Test</span>");
    $(".js-callout-mainElement span").show();
    $(".js-callout-content").show();
    $(".js-callout-mainElement").css("border-width","1px");
    },1000);
    </script>
    Result:
    Best Regards
    Dennis Guo
    TechNet Community Support

  • How to trigger the automated row fetch process and open modal window by javascript api?

    Hi,
    I would like to click the one row of column of IR report, to open the modal window of current page.  <----------------it is ok. I can use "javascript:openModal('windowID')"  to do it.
    There is one form in this modal window, Meanwhile, I would like to pass column data to this form.    <--------------------- it is ok also. I can use " $s('P7_ID','column_value');" to do it.
    But I don't know how to trigger the "automated row fetch" process of this form to retrieve other field's value in this form.   
    I tried to use following 2 ways. But failed.
    First method:
    add one ajax process of "automated row fetch" in "page processing" block, named "get_fetch_data"
    when click IR column , call "openModal", and call  "apex.server.process ( "get_fetch_data", {}, { success: function( pData ) { }  } );"  , I tried to call above ajax process to refresh form. It is failed.
    Second method:
    add one process of  "automated row fetch" in "page rendering" block, named "get_fetch_data"
    when click IR column, call javascript api "apex.submit" to submit current page , then call "openModal".
    such as :  javascript:apex.submit({request:'MODIFY',set:{'P7_ID': #ID#}}); openModal('trade');
    But it is failed also. the modal page is showed firstly. then page refresh. but modal window will not open again.
    I am not sure if my thinking is right. Could you please provide any suggestion?
    Thanks in advance,
    Ping

    Hi Ping,
    You can try to set the session state of your modal page's primary key before opening the modal page. Use one dynamic action (on click of IR row) with two true actions. First one to set session state of modal page pk, second on to open modal page.
    Or you can add the modal page url as link in your report by extending your query:
    select ...
    ,         apex_util.prepare_url( 'f?p='||:APP_ID||':7:'||:APP_SESSION||'::'||:DEBUG||':7:P7_ID'||COLUMN_VALUE ) as link
    from ...
    This will give you the url of the modal page, with set primary key.
    Regards,
    Vincent Deelen
    http://vincentdeelen.blogspot.com

Maybe you are looking for