Javascript Autocomplete by Tom Petrus and VC

Hi
I am using the following on my interactive report to provide a google search like autocomplete as the user enters a name, surname, date etc
This works find apart from when searching for a surname such as 'Rees' it does not bring this back but will bring back suggestions like 'Crees'. 'Freestone' etc
Same for forename when searching for 'Ian' it does not bring this back 'Ian' but brings back 'Adrian', 'Brian' etc
This only happens on certain names however searching for 'Paul', 'Steven' 'Brian' works fine
If anyone could shed any light into what's causing this it would be most helpful
function srch2(pItem, pColumn) {  
   $.post('wwv_flow.show',
          {"p_request"          : 'APXWGT',
          "p_widget_action"     : 'FILTER',
          "p_widget_action_mod" : 'ADD',
          "p_widget_mod"        : 'ACTION',
          "p_widget_name"       : 'worksheet',
          "p_flow_id"           : $v('pFlowId'),
          "p_flow_step_id"      : $v('pFlowStepId'),
          "p_instance"          : $v('pInstance'),
          "x01"                 : $v('apexir_WORKSHEET_ID'),
          "x02"                 : $v('apexir_REPORT_ID'),
          "x03"                 : pColumn,
          "f01"                 : ['COLUMN', pColumn, '=', $v(pItem), null, 'minutes']
         function(data){
            //when the filter has been successfully applied the report has to be refreshed
            if(data=="true"){
               gReport.pull();
   //clear the item
   $s(pItem,'');
$(document).ready(function(){
   //hide IR toolbar
   $('#apexir_TOOLBAR').hide();
   $('#P4_AC').bind("result", function(){   
      //on selecting a value then fire the search function
      srch2(this, 'INDSNAME');
   // ac item P4_AC2
   $('#P4_AC2').bind("result", function(){   
      srch2(this, 'INDFNAME');
   // ac item YEARD
   $('#YEARD').bind("result", function(){
      srch2(this, 'NEWYEAR');
// ac item REG
   $('#REG').bind("result", function(){
      srch2(this, 'INDREG');
// ac item ENTNO
   $('#ENTNO').bind("result", function(){
      srch2(this, 'INDENT');

Hi Tom
Could it be that on the interactive report it mentions "This query returns more than 100,000 rows, please filter your data to ensure complete results."
There is no plugin its just using the two pieces of code I mentioned in the threads above
This is the original thread
https://forums.oracle.com/thread/2412281

Similar Messages

  • I recently changed from a pc to a mac book. The major issue I am having right now is getting yahoo to work properly. The major thing is autocomplete does not work and I do not know how to load my contacts to "mail".

    I recently changed from a pc to a mac book. The major issue I am having right now is getting yahoo to work properly. The major thing is autocomplete does not work and I do not know how to load my contacts to "mail". Furthermore, I cannot attach any type of documents to my emails (Yahoo says there is a problem). I suspect there is a setting somewhere, but I don't know where. Javascript is enabled, so I am out of options

    Which os are you using?
    Yahoo issues should be posted in their forums or contact Yahoo tech support.

  • Javascript to print print date and time on scanned documents

    I'm using the following code to print a message, time/date stamp, and expiry date along the right hand side of printed documents. It works fine on word docs that were printed to pdf, but when a document it scanned, it mysteriously prints the the correct line of text, but also prints an additional, identical line perpendicular to the original line.
    Any help would be most appreciated!
    // Add field to each page of form
    var inch = 72;
    for (var p = 0; p < this.numPages ; p++) {
    // create rectangle quads for field
    var aRect = this.getPageBox( {nPage: p} );
    aRect[0] = 540.0;
    aRect[1] = 0.0;
    aRect[2] = 576.0;
    aRect[3] = 792;
    var f = this.addField("PrintField" + p, "text", p, aRect)
    f.delay = false;
    f.print = true;
    f.hidden = true;
    f.delay = false;
    f.rotation = 90;
    f.textSize = 10;
    f.textFont = font.HelvB;
    f.textColor = color.red;
    f.alignment = "center";
    f.readonly = true;
    f.value = "";
    var myWillPrintScript =
    'for (var p = 0; p < this.numPages ; p++) { ' +
    'var f = this.getField("PrintField" + p); '
    + 'f.hidden = false; '
    + 'var d = new Date(); '
    + 'var expiryd = new Date(); '
    + 'var ThursdayArray = new Array(7); '
    + 'ThursdayArray[0] = 4; '
    + 'ThursdayArray[1] = 3; '
    + 'ThursdayArray[2] = 2; '
    + 'ThursdayArray[3] = 1; '
    + 'ThursdayArray[4] = 0; '
    + 'ThursdayArray[5] = 6; '
    + 'ThursdayArray[6] = 5; '
    + 'var currentday = 0;'
    + 'currentday = d.getDay(); '
    + 'expiryd.setDate(expiryd.getDate() + ThursdayArray[currentday]);'
    + 'f.value = "This is an unofficial copy of a controlled document. Print date/time: " + util.printd("dd mmm yyyy HH:MM ", d) + " Expires: "+ util.printd("dd mmm yyyy ", expiryd) + " 23:59 EST.";'
    + '}'
    var myDidPrintScript =
    'this.resetForm();'
    + 'this.dirty = false;'
    // Now set the scripts to execute on the Will/Did Print events.
    this.setAction("WillPrint", myWillPrintScript);
    this.setAction("DidPrint", myDidPrintScript);

    Very unusual, Here are some more questions to help nail down the issue.
    Are both date text lines in form fields? What are the form field names? i.e. is this an exact copy of the existing form field? What are the settings that differentiate the two fields, i.e. Rotation, etc.?
    Could the script be somehow getting run twice?
    On another note, why are you naming all of the fields differently. It looks like they all get the same info. If this is true then you could simplify the script by making them all the same name. You would not need the loop to apply the date text.
    Thom Parker
    The source for PDF Scripting Info
    www.pdfScripting.com
    The Acrobat JavaScript Reference, Use it Early and Often
    http://www.adobe.com/devnet/acrobat/

  • By mistake i deauthorize my computer to use my apple id i do want to authorise it also i purchased TOM TOM Australia and i cannot sync into my iphone 4s

    By mistake i deauthorize my computer to use my apple id i do want to authorise it again ...also i purchased TOM TOM Australia and street fighter among other applications and i cannot sync them into my iphone 4s
    please help

    After I upgraded to Mavericks I was also having this message when I tried to update. There was a previous post about this problem which offered this simple solution which worked for me:
    b0n0b0
    Re: Recently upgraded to Maverick from SnowLeopard. Unable to get updates from App store.
    Mar 15, 2014 9:05 AM (in response to Terence Devlin)
    Got it! Thanx.  What I did was go to my account, check that they had my new ID and Password which they did, then hit reset button. All fixed.

  • HTML-DB OAE Javascript to close current window and open a new window

    Hi everybody,
    We work with 1.6.
    What we want is to close the current window and open a new window with the URL mentionned in the window.open('http://www.cf.qc/pls/portal/PORTAL.....,'newwindow').
    The new window opening fires only once although we call it many times.
    Our javascript is:
    function closeTest()
    { alert('closeTest');
    if('&REQUEST.'=='QUITTER2'){     
    w = window.self;
    w.opener = w;
    w.close();
    window.open('http://www.cf.qc/pls/portal/PORTAL.home','newwindow','toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,resizable=yes');
    We call it on our application attributes :
    OnLoad="closeTest()"
    Thanks. Bye.

    Try this on for size:
    I have included two functions.
    windowRebuild() - opens a new window, maximizes it based on the screen size, removes all toolbars, and then closes the old window.
    myLocation(appName, pageName) - builds a url referencing an HTMLDB application, specfic to what server you are currently on. Very useful when you have an application on 3 different servers(dev, test, prod servers), you wouldn't want the server name hardcoded if you plan to export the app to another server.
    Also, you need to be careful when using &APP_ID. I am not completely certain how that is resolved at runtime, but I've found it only works when the javascript is in the HTML Header of a page and not stored in the template of the page.
    <script language="JavaScript1.1" type="text/javascript">
      This functions is for internal application use.
      Examples of myLocation:
      url = myLocation('&APP_ID.', 'APP_PUBLIC_PAGE');
      url = myLocation('MY_APP_ALIAS', 'MY_PAGE_ALIAS');
      url = myLocation('184', '10');
    function myLocation(myApp, myPage){
      var myHost = location.host;
      var newURL;
      newURL = 'http://'+myHost+'/pls/htmldb/f?p='+myApp.toString()+':'+myPage.toString();
      return newURL;
    /*  Function windowRebuild()
    *   This function will open a new window and close the old window.
    *   This function will also maximize the new window and remove all toolbars.
    function windowRebuild(){
       if(window.name != 'myAppWin'){
        var url = myLocation('&APP_ID.', 'PAGE_ALIAS');
        var myWin = window.open(url,'myAppWin','toolbar=0,scrollbars=1,menubar=0,status=1,resizable=1,location=0');
        window.opener = 'x';
        window.close();
       if(window.name == 'myAppWin'){
        window.moveTo(0,0);
        window.resizeTo(screen.availWidth,screen.availHeight);
    </script>Let me know if that works or you need some more explanation.
    Chris

  • How to use javascript variable in BSP/ABAP and vice versa

    Hello Experts,
    In IC WEBCLIENT, there is a view.In the view.htm i want to fetch  the screen resolution and as per the resolution i want set the width of that view.
    1, I wrote the below  javascript to fetch the screen resolution.
       Can i use a notmal ABAP variable inside the javascript? and   If i use can i access that variable after the javascript.?
       Can i assign a javascript variable to a nrmal abap variable??
       The code sample  is like :
    Start of javascript
       if (screen,width == 1024 )
         lv_width = 500  "lv_width is an ABAP variable.
      else
        lv_width = 700
    **END OF JAVASCRIPT
       **Now i want to use lv_width  to assign to a table view attribute(Width)
    <crmc: tableview..
                    width = <%= lv_width >
    the code is not giving any error. But the problem is that lv_width is not giving the correct value, its getting initialized to initial value...
    Requesting the experts to please provide some suggestions/solution for the above issue.
    Thanks and Regards
    Sudhansu

    Hello Sudhansu,
    First of all there was a little mistake at my previous answer:
    you got lw_width = 700
    because at Server Side you have following code:
    lw_width = 500.
    lw_width = 700.
    but if you were writing your code like this:
    <%=lw_width %> = 700.
    then you will get the result that I was talking about : 0 = 700
    Sorry for the mistake
    Now for your question:
    if you want to get a value from the server and assign it to JScript variable you should write like this :
    var aaa;
    aaa = <%=lw_width %>;
    this code assign the server variable lw_width value into aaa  JScript varible.
    I'm not sure what exactly you want to do but look at this link:
    http://www.pageresource.com/jscript/jscreen.htm
    to get the idea how to get and use Screen Resolution variables at your JScript code.
    Good luck
    Eli Steklov
    Please Reward Points if it Helped

  • JQuery/Javascript not working on Firefox and Chrome

    Hi guys, I've had this Jquery/Javascript on my page for a long time. This has stopped working. If the user clicks on buttons on the Apex page, nothing happens.
    It works on IE but doesn't work on Firefox and Chrome. It used to work fine.
    Is there anything I can change to make it work on all 3 browsers?
    Firefox error console shows a syntax error at this point in the script:
    $allButtons.click(function(){
    itemChanged = false;
    var toDo = $(this).attr('data-submitval');
    eval(toDo);
    Please can someone help?
    This is the full script:
    <script type="text/javascript">
    //<![CDATA[
    var itemChanged = false;
    $(document).ready(function(){
    var $items = $(':input');
    var $htmlButtons = $(':button[id]');
    var $templateButtons = $(':button[class]');
    var $allButtons = $($htmlButtons).add($templateButtons);
    $items.change(function() {
    itemChanged = true;
    $templateButtons.attr('data-submitval', function(){
    return $(this).attr('onclick').toString().split('\n')[2];
    $htmlButtons.attr('data-submitval', function(){
    return this.id;
    $allButtons.removeAttr('onclick');
    $allButtons.click(function(){
    itemChanged = false;
    var toDo = $(this).attr('data-submitval');
    eval(toDo);
    $('a').click(function(event){
    if ($(this).children('img[id="P&APP_PAGE_ID._DATE_PICKER_IMG"]').length > 0) {
    event.preventDefault();
    eval($(this).attr('href'));
    window.onbeforeunload = function() {
    if (itemChanged) {
    return 'You have made changes to data on this page. If you navigate away from this page without first saving your data, the changes will be lost.';
    //]]>
    </script>
    Thanks
    Sam
    Edited by: sam on 29-Jan-2013 03:50

    JavaScript doesn't work on any site at all? If particular sites are the issue, or you get specific error messages, please let us know.
    Usually the only two ways to disable JavaScript in Firefox are:
    (1) Options dialog > Content tab<br>
    (2) NoScript add-on (or other security-related add-ons)
    Normally Safe Mode bypasses issues caused by add-on problems or non-default settings, so it's worth considering external issues.
    Does JavaScript work normally in any other browsers you have installed?

  • External Javascript not working with C# and XAML windows phone app

    I've added a WebView into my project. If I navigate to the html file that contains external javascript files they don't work. Bit if I write the javascript code hardcoded into the html file it works properly.
    Here is the html portion:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
    <html lang="en" xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta charset="utf-8" />
    <title></title>
    <script type="text/javascript" src="testjs.js"></script>
    </head>
    <body>
    <div id="abcd"></div>
    <br/>
    hello! this is a simple html block.
    </body>
    </html>
    Here is the javascript portion:
    document.getElementById("abcd").innerHTML = "New text!";
    When I open the webview it shows
    hello!
    this is a simple html block.,
    but if the javascript code worked it would show
    New
    Test! hello! this is a simple html block.
    And in the C# code the uri is called this way:
    url = onlineTestWebView.BuildLocalStreamUri("myUrl", "problem_page/test.html");
    StreamUriWinRTResolver myResolver = new StreamUriWinRTResolver();
    onlineTestWebView.NavigateToLocalStreamUri(url, myResolver);

    I assume this is because you are using NavigateToString. Please see
    http://blogs.msdn.com/b/wsdevsol/archive/2014/06/20/a-primer-on-webview-navigatetolocalstreamuri.aspx
    Matt Small - Microsoft Escalation Engineer - Forum Moderator
    If my reply answers your question, please mark this post as answered.
    NOTE: If I ask for code, please provide something that I can drop directly into a project and run (including XAML), or an actual application project. I'm trying to help a lot of people, so I don't have time to figure out weird snippets with undefined
    objects and unknown namespaces.

  • Calling a javascript function from java code and getting tha value in Java

    Hi,
    I would like to call a Java script function confirmRemove() from Java code upon meeting a condition..
    for example the code snippet is:
    if(true){
    // I want to call js confirmRemove() over here. And get the value of variable "answer" in this if block.
    <html>
    <head>
    <script type="text/javascript">
    function confirmRemove() {
         var answer = confirm("Are you sure you want to Delete?")
    </script>
    </head>
    <body>
    <form>...

    Hi,
    Back in 2003 I have used an Applet which contain java code and this java code was calling the java scripts ( different methods, DHTML etc..)
    There was a component developed by NetScape called JSObject I am not sure it there is other third party component other then the JSObject
    look at this article which shows how (based on JSObject)
    [http://java.sun.com/products/plugin/1.3/docs/jsobject.html|http://java.sun.com/products/plugin/1.3/docs/jsobject.html]
    Regards,
    Alan Meio
    London,UK

  • Javascript not woking in IE and Chrome

    Hi All,
    I have simple javascript function in my application that set focus in button. The code is below:
    <script type="text/javascript">
    function setfocs()
    $('#add_row_id').focus();
    </script>
    This function is working in Firefox only, but not working in Chrome and IE. Please tell me how to solve this?
    Thanks

    Hi,
    I have simple javascript function in my application that set focus in button. The code is below:
    <script type="text/javascript">
    function setfocs()
    $('#add_row_id').focus();
    </script>This function is working in Firefox only, but not working in Chrome and IE. Please tell me how to solve this?
    >
    Please use the &#123;code&#125; tags when posting code.
    See http://www.mkyong.com/javascript/focus-is-not-working-in-ie-solution/
    Cheers,

  • JSF web app gives javascript error - 'dojo is undefined' and 'webui is unde

    Hi,
    BACKGROUND: I have created a Netbeans 6 Visual Web Project. I have also integrated my web app with RichFaces 3.1.3. My web application can be viewed properly and correctly when i deploy it on tomcat 6.
    ARCHITECTURE: Our server configuration requires IIS to be our web server and tomcat to be our app server. Both are running on different machines. I have successfully linked up IIS 6 and tomcat 6 using the JK isapi_redirector.
    PROBLEM: However, when i connect to my app via IIS, my starting page opens but the input box components on that page are not displayed and i get several javascript errors that read - 'dojo is undefined' and 'webui is undefined'.
    Any help or advice in this matter will be greatly appreciated.
    Thanks!!!

    I managed to find a workaround. Thought i should share it with those who are faced with a similar issue.
    I found that a bug report had been placed in the past with Apache Dev. However, they had said that they would not modify their logic because the servlet container spec requires it (even though isapi_redirector is only a connector and not a container). They said that there is no way for the isapi_redirector to differentiate between /foo/WEB-INF when foo is a context and when foo is just a sub-directory of the ROOT web application. So, the general consensus was to err on the side of safety and risk blocking a few requests that are valid.
    However, this causes a serious issue for those using NetBeans JSF Visual Web Projects. Hence, I created my own flavour of isapi_redirector by modifying the code such that this check is not performed and leaving the onus of checking on Tomcat.
    For those who are interested, the simplest way to go about this would be to force the function uri_is_web_inf (in jk_isapi_plugin.c ) to always return FALSE.

  • Weird javascript issues in google-chrome and awesome-wm

    I'm having a specific and annoying problem running google-chrome 12.0.742.100-1 and awesome 3.4.9-1.  When I use Gmail, the popup chat and tasks window placement is totally fscked up.  The windows appear in random places and are hanging off the side of the page, so that I cannot focus them or use them.
    Wondering if this is related to awesome + chrome because I do not experience this in Gnome or chromium.  This has afflicted that last couple of google-chrome installations for me.  I suppose it could also be a Gmail-specific javascript bug.

    Why use the closed source chrome, when the open source chromium works? (and doesn't link against 4 year old libs etc)

  • How can I share autocomplete lists between sheets and/or files?

    I'm drafting up a P&L spreadsheet in which I keep lists of categories, vendors, etc. I'd like to keep separate sheets for each month; the problem is that once I start a new sheet, Numbers seems to "forget" the vendor names, and I have to reenter the entire name again instead of the first three letters or so... I think for obvious reasons I don't want to put a whole year of order records on a single sheet ;-)
    Is there a way to preserve or export lists of field values so that they can be shared between sheets (or even files?)

    Appreciate the answer Wayne, although it wasn't the one I wanted to read... I had already embedded a hidden list in *every* table in each sheet; needless to say it didn't improve the performance one bit.
    Turns out that the lists aren't shared between tables either (same heading, same column) that I used to create expandable categories. Would be a nice feature to recognize a column heading and propagate the autocomplete lists, and maybe even be able to link these across tables, sheets *and* files!
    Probably too late for iWork '12 ('13, '14?) , but I filed an enhancement request to be able to refer to "file foo, sheet C, table 3" column contents.
    Mike

  • Javascript future in Webdynpro (JAVA and ABAP)

    Hi WebDyn Pro's,
    I see many sophisticated capabilities enabled inside Webdynpro for JAVA from use of Javascript.  Further, in many cases, Javascript provides the only solution for the requirements!
    From this forum, I think I hear that Javascript capabilities may be disallowed in future WebDynpro releases by SAP. 
    I have 3 questions related to this:
    1. Why would SAP want to disallow usage of Javascript inside WebDynpro applications?  What is the harm?
    2. Does SAP think that customers should be able to provide these same capabilities without use of Javascript?
    3. Will this same Javascript limitation exist in WebDynpro for ABAP?
    Thanks,
    Kevin

    "Many sophesticated capabilities enabled inside Webdynpro for JAVA from use of Javascript." - that is true
    1. It is to have a standard for development inside, and outside SAP. Otherwise developers will use ... who knows what they will develop... and there have been quality problems in projects that SAP has to deliver - SAP has 30,000 employees, any of whome can develop in their free time. With the current framework, all these issues have been taken into consideration.
    2. SAP and the Webdynpro development team in Walldorf will continue to enhance the webdynpro framework in the forseeable future. There is an alternative if you want to use Javascript. Please use Java Dyn Pages for unlimited java script coding. This can be seen in Portal Development Manual. http://help.sap.com/saphelp_nw04/helpdata/en/fd/01f34026d70b06e10000000a155106/content.htm
    3. Yes it will apply in ABAP. WebDynpro is the common framework that is used for both ABAP and Java. It Java/ABAP independent "so" to say. But it works better with Java right now than ABAP.
    Sumit.

  • Javascript not working in Safari and Firefox

    in stead of rendering the html generated by javascript, the html code itself is displayed in both Safari and Firefox.
    The strange thing is that this is only for one of my accounts. This account was transferred using the migration tool from my previous computer, where I also had this problem.
    A brand new generated user account does not show this problem.

    HI,
    In the affected account...
    From the Safari Menu Bar click Safari/Preferences then select the Security tab.
    Make sure: Enable plug-ins and Enable Java and Enable JavaScript are selected.
    Since you are running Snow Leopard, make sure Safari is running in 32-bit mode, not 64. Right or control click the Safari icon in the Applications folder, then click: Get Info In the Get Info window click the black disclosure triangle next to General so it faces down. Select 32 bit mode. Also, (in that same window) *make sure Safari is NOT running in Rosetta.*
    Relaunch Safari.
    Carolyn

Maybe you are looking for