Problem with passing parameters to an applet?

Hello

I have a page of the apex which is a popup page. I am passing the parameters of the cmdlet and then to read in my java code.

Here's my applet code
<SCRIPT>
  function getStatus(retStatus) {
    $s("P3_MESSAGE", ''||retStatus||'')
  }
</SCRIPT>
<APPLET ARCHIVE="/i/bin/offline_load.zip" CODE="offline_load.class"  STATUSMSG WIDTH=0 HEIGHT=0> 
<PARAM name="username" value="&APP_USER.">
<PARAM name="dbuser" value="&P3_DBUSER.">
<PARAM name="dbpassword" value="&P3_DBPASSWORD.">
<PARAM name="dbserver" value="&P0_DBSERVER.">
<PARAM name="dbport" value="&P3_DBPORT.">
<PARAM name="dbsid" value="&P3_DBSID.">
</APPLET>
P3_DBUSER, P3_DBPASSWORD, etc. are all defined on the page zero elements also hidden and protected

My applet code
public void init() {

    CallableStatement load_stmt = null;
    String userName = this.getParameter("username");
    String dbUser = this.getParameter("dbuser");
    String dbPass = this.getParameter("dbpassword");
    String dbServer = this.getParameter("dbserver");
    String dbPort = this.getParameter("dbport");
    String dbSid = this.getParameter("dbsid");

    try {
        
      System.out.println("init(): loading OracleDriver for applet created at " + created.toString());
      Class.forName("oracle.jdbc.driver.OracleDriver");
      System.out.println("init(): getting connection");
      conn = DriverManager.getConnection("jdbc:oracle:thin:@" + dbServer + ":" + dbPort + ":" + dbSid, dbUser, dbPass);
         
    } // end try
The strange thing is that I got this job twice then it stops unexpectedly just work when I make a change to the java applet code.
And the changes have absolutely nothing to do with the code above, it can be anything is the first, I added the error handling
to another part and the second, I modified a stored procedure call.
Anyone have any idea why this might happen as it drives me completely crazy :(

Thanks in advance

Hello

In your init() code, you have a "try" block - you have a 'Finally' block to close the connection? Something like:

finally {
  try {
    conn.close();
  }
  catch (Exception ignore) {
  }
}

If you have reached the limit of the number of connections open available?

Your code looks OK I can see (based on examples at: http://www.orafaq.com/wiki/JDBC)

In addition, in your new have pieces of code, you added try/catch/finally blocks? Is the compilation of code completely (IE, no warning)? Have you added new imports that could conflict with existing code such that you have to characterize completely the existing objects/classes (for example, you have now two DriverManager class or CallableStatement objects)?

Andy

Tags: Database

Similar Questions

  • Problem with passing parameters to an HTTPService on buttonclick within the grid

    I have a DataGrid where I use ItemRenderers to render components such as buttons n Images within the grid. Now, I need to pass parameters to an HTTPService on click of a button. If the button is directly on the form (not in the grid), is easy to call HTTPService. But given that the button is in a grid, it is not able to resolve the HTTPService and so I can't call the HTTPService on ' click on ' event of the button.

    I would like to know if anyone can help.

    You should probably use click = "outerDocument.myClickHandler ()" "

    The outerDocument allows you to access the methods outside of the rendering engine.

    If this post has answered your question or helped, please mark it as such.

  • Problems with passing parameters to a dynamic theme

    Hello experts,

    I have been struggling with this for days now and can't seem to understand what is happening here. I don't think that it is difficult to understand and I don't know I'm not the only one who came through it, I just feel like I'm missing something.

    In short - I have a predefined theme called TEST_DYNAMIC_THEME_NEW2. Its styling rules are as follows:
     
    <?xml version="1.0" standalone="yes"?>
    <styling_rules caching="NONE">
        <rule>
            <features style="C.RED"> select geom, :1 FROM TRACT_CURRENT_GEO </features>
      </rule>
    </styling_rules>
    I try of course to pass a parameter to this theme, representing a column name. Maybe this is not possible, but I don't know why not.

    The error message that I do not get in Firebug is as follows:
    <?xml version="1.0" encoding="UTF-8" ?> <oms_error> MAPVIEWER-06009: Error processing an FOI request.
    Root cause:SQLException: ORA-01722: invalid number
    </oms_error>
    On the other hand, when I'm in mapbuilder and I saw the theme it works fine. He asks for a parameter value for: 1, I give him a column name, and a large red card is displayed in the preview screen (this is what I want to see [at least for now]).

    Ideas, people?


    Thank you all very much for your time,

    John

    The binding settings should be used for parameter values in your query condition. It is not intended to define column names in your selection list.
    Although it seems to have worked for you in MapBuilder, there is no guarantee that you will get good results with the server of the FAITH.

  • Problem of passing parameters to commandLink in a column

    Hello.

    I use JDeveloper 11.1.1.7.0

    I have this problem and I do not understand what I am doing wrong.

    I have a table like this:

    <af:table value="#{bindings.myView.collectionModel}"
                var="row"
                rows="#{bindings.myView.rangeSize}"
                emptyText="#{bindings.myView.viewable ? 'No data to display.' : 'Access Denied.'}"
                fetchSize="#{bindings.myView.rangeSize}"
                rowBandingInterval="0"
                binding="#{backingBeanScope.myBean.t1}"
                id="t1" 
                rowSelection="single"
                contentDelivery="immediate">
        <af:column sortProperty="#{bindings.myView.hints.PrId.name}"
                   sortable="false"
                   headerText="Nro. Proc."
                   id="c2" width="50">
          <af:outputText value="#{row.PrId}" id="ot5"/>
        </af:column>
        <af:column id="c8" headerText="Check" align="center" width="70">
          <af:commandLink text="rowCheck" id="cl1" partialSubmit="true">
            <f:attribute name="rowKey" value="#{row.rowKey}"/>
    
            <af:serverListener type="serverAction" method="#{backingBeanScope.myBean.linkEvaluacionServerAction}"/>
            <af:clientListener type="action" method="clientAction"/>
          </af:commandLink>
        </af:column>
    </af:table>
    

    After a lot of tests, serverListener + clientListener is the only way to run code after clicking on the link. I don't know why, but actionListener in the link doesn't work the first time. The second time and so on, actionListener doesn't not fire.

    My problem is how to pass rowKey parameter to the linkEvaluacionServerAction method:

      public void linkEvaluacionServerAction(ClientEvent ce){
        Object key1 = ce.getComponent().getAttributes().get("rowKey");
    
         // actions with key1
    }
    

    I don't know why, but the link rowKey attribute takes the value associated with the first time I clicked on a link.

    The second and so on, key1 null values

    How can I solve this? Any help is very appreciated.

    Concerning

    Well, I think (yet) the approach and solve it in this way:

    
                      
                    
    

    Setting of setCurrentRowWithKey is #{row.rowKeyStr}

    In my linkEvaluacionAction method I do additional checks.

    I hope this helps. Concerning

  • Problem with passing the values in a report to the other

    Hello

    I am Agnes, I have developed 2 reports. Summary of the first high level, Mithraeum is detailed. First report is developed using Union (4 union), I have 4 columns. The report generates data. I used the Navigation option on customer column to go to the second report. In the second report with filter I use the easier option. Due to a problem, the customer value of the first report is failed per second. The second report is getting generated for all customers.

    Normally, I have used this option to navigate through other reports and which works very well. I even tested with Union, it works. This time is to give some difficulties.

    Please, let me know what goes wrong.

    Thanks for the help.

    If your Union pivot source then by a simple navigation that you can not pass clicked value to the second report.

    With the help of GoNaV you can pass the selected value source union pivot report to the non-Union target report. If the target report is also union pivot, then it won't pass filters using GoNav.Not sure that because someone talked about a few days back that with the help of GoNav possible to pass the value of a union pivot query to pivot anothet union report.

    Kind regards
    Sandeep

  • problems with passing of Pagemaker in InDesign

    Hello

    I'll try to make my problem as understandable as possible.

    I work in a company that made their catalog with Pagemaker, is a very small company, so no real expertiese in PM or ID.

    I know that many will crinch when they hear this, but we use links from excellent to h.

    These links are used to change the language of the catalog. The basic idea is that the catalog is roughly the same in all languages and its only small amounts of text that changes depending on the language (most are numbers).

    So we have a spreadsheet with x columns where each column represents one language, each line represents a different textline. We also have a master column which is related to h. This gives us the ability to change the language of the catalog just in sticky columns of different language in the main column and update of PM.

    Most of you can probably see where this is going.

    Design support links to excel, it seems. So I was wondering if anyone has an idea that could help us to transfer our catalog ID in a smooth manner and maby at the same time give us ideas how to improve our how to change the language, without too many problems.

    Any help is much appreciated

    Thanks in advance

    Simon

    'Links' are really related, or are incorporated. PM wanted to incorporate default things (and it's really important to change the images to embedded to linked in Manager link in PM before converting in ID). Since used PM really strange OLE routines for spreadsheets, I'm not sure they will result as real links for ID. You may be stuck.

    Converting PM documents is really hit or miss, depending on the structure of the PM. Some will be almost perfect, other useless, but you should always count on doing some work in ID.

  • Problem with pass - and - play

    Hi I'm doing a simple web with 4 buttons. And I did the respective links with gotoAndPlay in as3. Everything works fine, but when I click the last button, the btn 4 and then want to go to the btn 3 it does not work. It works only when I want to go button 01:56, but 4-1. Why is this? Here is the code:

    Stop();
    Btn1.addEventListener (MouseEvent.Click, funcion1);

    function funcion1(evt:MouseEvent):void {}
    gotoAndPlay (10);
    };

    btn2.addEventListener (MouseEvent.Click, funcion2);

    function funcion2(evt:MouseEvent):void {}
    gotoAndPlay (20);
    };

    btn3.addEventListener (MouseEvent.Click, funcion3);

    function funcion3(evt:MouseEvent):void {}
    gotoAndPlay (30);
    };

    btn4.addEventListener (MouseEvent.Click, funcion4);

    function funcion4(evt:MouseEvent):void {}
    gotoAndPlay (40);
    };

    PD: I'm sure that all buttons have the instance name in all frames (10, 20, 30, 40)

    What image are you adding the button event listeners? I start from frame 1. Whenever you put a keyframe on the timeline you are essentially new instantiating the movieclip on this layer and you can't expect that an event listener that you added previously will still apply after the new keyframe. There are a lot of different ways to solve this problem. In your case the simplest would be to on each key frame, remove the button event listeners (in the case where they are there, avoiding memory leaks) and then add them again. Not the best approach, but it should work.

    HTH.

    -Randy

  • Hello I have a little problem with pass values pop-up

    I want to transmit values when the user click on current line, then see the menu right click popup is displayed.

    I need help after the code. Because it does not pass the current row values, it passes all values in the database. I thought that the filter does not work.

    First of all, I added Bind Variables named VarEnqID and criteria named GetbyIDCriteria on my view object.

    Second, I created picture objects and interfaces of object classes and display code of the method of the object class:

    Public Sub setSearch1C (String input)

    {

    ViewCriteria vc = getViewCriteria ("GetByIDCriteria");

    vc.resetCriteria ();

    setVarEnqID (input);

    setVarEnqId2 (input);

    applyViewCriteria (vc);

    executeQuery();

    }

    Thirdly, I drag setSearch1C of data control and make context menu right click Add attribute named Id to links, and then click code value.

    My criteria did not work so I decided to him another way. I dragged the data control display object to bring up and created the unalterable form adf. Then everything would be OK.

  • Problem with initialization parameters of the source of the CAD system

    Hello
    I have created a container, initialized the system settings source in CAD ($INITIAL_EXTRACT_DATE = 01/01/2008, $LAST_EXTRACT_DATE = 01/01/2008) and performance 'Human resources 11.5.10' plan transaction. One of the tasks (SDE_ORA_PayrollFact) was performed too long. When I analyzed the log file I saw SQL code with strange condition:
    where w_payroll_f.last_update_date > = 1700/01/01...

    In a mapplet there was a SQL override in condition:
    where w_payroll_f.last_update_date > = $$ LAST_EXTRACT_DATE

    So where the parameter $LAST_EXTRACT_DATE value was taken?

    Several other in the settings SDE_ORA_PayrollFact.txt $INITIAL_EXTRACT_DATE = 01/01/1970, $LAST_EXTRACT_DATE file = null.
    Please, explain the DAC and Informatica algorithm for initialization of the settings!

    How can I set these settings to get the desired result, $LAST_EXTRACT_DATE = 01/01/2008?
    That the level of the initialization parameter has the highest priority?
    Best regards.

    Published by: Alina HS on 15.09.2008 23:15

    Alina,
    You seem to have taken the right steps. You have created a custom container (as it should) and have customized the values there.
    However, I have a strange feeling that your execution plan is not looking at your custom container. Look at the subject areas associated with the title of your implementation plan. They should be referred to your custom container. If this isn't the case, yet its reading of the values out of the OTB one.

    If this is the case, associate your custom container for the EP SAs AND re - build the EP.

    As the LAST_EXTRACT_DT is concerned, it is a setting that DAC would provide before calling infa workflows. If you charge for the first time, it will be null. In incremental mode, you will see the value as seen in the Setup-> data sources-> tab Update Dates.

    However, when this particular value (the internal representation of this value DAC) is zero, the DAC server should be running the command of full load. Inspect the execution history and ensure that full load control is one that is running. If so, its worth looking into the sql session substitute and/or the map itself to see how this parameter is used.

    I hope this helps!

    Published by: user743400 on Sep 16, 2008 11:28

  • Quiz results: problem with Pass Message and background Image

    Hello

    I use v1 and I had a question on the quiz results page. I input a Message goes in the quiz Manager, but not the entire message appears on the Quiz results page. It seems to be cut. Y at - it something I need to do to ensure that everything is displayed or Captivate allowed me to enter a long message in the Quiz Manager, but not display it on the screen of Quiz results.

    Also, if I choose a background image it seems to appear on the upper left of the results window. Is there a way I can place this image to appear where I would that he on the results page?

    Thanks in advance!

    Hi Julie88,

    First of all, for the long message, your observation is correct. Captivate has allowed to enter long message Quiz Manager, but its actually impossible to view it in the SWF file.

    Second, for the image, unfortuantely you can't do Captivate 1. Captivate 2 comes gives you this option. Infact in Captivate 2, you can view the result do drag in the Editor pane and change it as you wish.

    Thank you

  • How to run and pass parameters to the exe file in the txt file.

    Hello

    I am facing problem with passing parameters in the .exe file, which is run by labview.firstly that I have script .txt with the settings that I have to go to the .exe file. This .exe file is also a software, and this script is written for her. And now I have to create program in labview which should satisfy the following points.

    1. I have to use a button named "Run script". If I pressed the button, it should open the browser where I can choose the script .txt file.

    2 .exe application is expected open(Path already chossen).

    3. After passing the .exe application settings should be closed.

    4 and labview should now update its parameter

    I just open using Exce.vi .exe file, but I didn't get any idea to do more than this.can someone please help me?

    Thanks norbert. CAN I love it? What should I change now? VI attached below...

  • Passing parameters in Director. Is this possible? Experience with Multipoint?

    I use Director for a series of educational applications. I have a single projector (start) where students can click on their name. When a name is selected, Startup Spotlight consults a database to determine which educational projector is expected to be launched. Based on the results in the database, I use the call of baRunProgram boyfriend to start the appropriate Director projector. Right now, I use a text file to record the student's progress in their work their way through the educational projector. All this works fine for a single user on a single computer.

    However, I am having a problem with a customer who uses Microsoft Multipoint. Using Multipoint, there are several students running the program to start in the same place. Therefore, the text file progress of all students instead of one student's progress. Startup Spotlight knows what student is active but the individual educational Spotlight do not currently have this information. I could identify a single student to the education projector passing a parameter. First of all, is it possible? If so, how could he do?

    Abstract of the passage of a parameter, is there another method that might work to accomplish the same thing?

    Everyone works in a Multipoint environment? I am interested in other experiences with Multipoint.

    You can pass parameters to a projector on the command line, but only at the launch of it. Check the documentation for "line of command" and also the function of baCommandArgs() of Buddy API

  • Problem with the passage of several parameters to a function

    Dear Experts,

    I have a strange problem while trying to pass parameters to a function in Csharp:

    On my database, I have a function like

    Mary of function (varchar2 parameter1, parameter 2 varchar2) return {number}
    ........
    }

    I want to write a csharp function that can perform these functions with different numbers and types of settings and always returns a number (see below).
    My problem is, I always pass that one parameter, the second parameter is not reach the database function, although I can see
    all parameters within the structure of the OracleCommand (dbcommand) object in the debugger.
    Can you give me a tip why my function does not work?


    Best regards

    Desperately Daniel



    It is my function:



    public override int insertDataSetwithReturn (String ProcCall, parameters of the ArrayList, ArrayList ParameterTypes, ArrayList ParameterNames)
    {

    int ReturnValue = 0;

    try {}
    Verification of conformity of the Arraylength
    If (!) (Parameters.Count) == ParameterTypes.Count)) {}
    wrong input! TODO!


    }



    MyDBConnection DBConnection = new DBConnectionORA();
    DBPOOL.getConnection (of the myDBConnection);
    OracleConnection myOracleConnection;
    myDBConnection.getConnectionout (of the myOracleConnection);

    DbCommand OracleCommand = new OracleCommand (ProcCall, myOracleConnection);
    dbCommand.CommandType = CommandType.StoredProcedure;

    Die nun aus der Parameterliste Columns setting.

    for (int ParameterCounter = 0; ParameterCounter < Parameters.Count; ParameterCounter++)
    {


    OracleParameter myParameter = new OracleParameter();
    myParameter.ParameterName = (String) ParameterNames [ParameterCounter];
    myParameter.OracleDbType = convertdotNetVariableTypesToDBVariableTypes ((String) [ParameterCounter] ParameterTypes);
    myParameter.Direction = ParameterDirection.Input;
    myParameter.Value = parameters [ParameterCounter];
    dbCommand.Parameters.Add (myParameter);
    }

    ReturnParameter OracleParameter = new OracleParameter();
    returnParameter.ParameterName = "ref_ret";
    returnParameter.OracleDbType = OracleDbType.Int16;
    returnParameter.Direction = ParameterDirection.ReturnValue;
    dbCommand.Parameters.Add (returnParameter);


    dbCommand.ExecuteNonQuery ();

    }


    catch (System.Exception e)
    {
    String MessageStr;
    MessageStr = "Error insertDataSet (DBConnection_ORA insertDataSet)." +
    Output +.
    e.get_Message () + "." +
    Output;
    MessageBox.Show (MessageStr, "Error in getArrayListfromProcedureNIP",
    MessageBoxButtons.OK, MessageBoxIcon.Exclamation);

    } //catch

    return ReturnValue;
    }

    Published by: danielwetzler on December 15, 2010 16:23

    Hello

    Can you give exactly the error generated by the application?

    You can try to overthrow the invocation of the parameters. This means that, try to invoke the returnValue parameter first and then the others (in settings) in the same order as you stated them in your stored procedure.

    in PLSQL, you have,
    Create or replace function (parm1 parm2 parm3 OUT varchar2, varchar2 IN IN varchar2)

    In your application, you must first write:
    blah blah blah parm3.direction = parm3.returnvalue

    and then
    blah blah blah parm1.direction = parm1.input
    blah blah blah parm2.direction = parm2.input

    Hope this helps you
    Walid

  • Pass parameters with a function that is a parameter to another function.  Is this possible?

    Hello

    I have some difficulty to pass parameters to a function that is passed as a parameter.  In the code for my application I am instantiating this class five times: they are buttons in a menu.  In this category, I had an onRelease handler that does a number of things when a button is released, which is to call a function defined in the level of enforcement of the code.  My problem is that I don't know how to send parameters to the functions.

    In my StandardButton class I:

    class StandardButton extends MovieClip
    {
         
         /* define properties */
         private var selected:Boolean = false;
         public  var btnMenu:MovieClip = null;
         public  var execFunc:Function;
         
         /* define constructor */
         public function StandardButton()
         {
              trace("Standard UI button created: " + this);
              this.onRelease = releaseHandler;
         }
         
         /* define methods */
         public function releaseHandler()
         {
              if (selected) {
                   
                   //this["bg"].gotoAndStop("normal");
                   //selected = false;
                   
              } else {
                   
                   //show the normal state of all other buttons in the menu set
                   for (var i:Number = 0; i < btnMenu.btnList.length; i++)
                   {
                        this._parent[btnMenu.btnList[i]].bg.gotoAndStop("normal");
                        this._parent[btnMenu.btnList[i]].selected = false;
                   }
                   
                   //show the select state of the button
                   this["bg"].gotoAndStop("select");
                   
                   //execute the function attached to this button
                   execFunc();
                   
                   //set the selected boolean for the current button
                   selected = true;
                   
              }
         }
         
         
         /* define accessors */
         public function set execFunction(instructions:Function)
         {
              execFunc = instructions;
         }
         
         public function set buttonMenu(menu:MovieClip)
         {
              btnMenu = menu;
         }
         
    }
    

    In my application .fla file, I have this

    //This is the function that will be executed when the user presses the button
    function autoModeHandler (param:String) {
         
              trace("You pressed the " + param + " button");
              
                                  
    }
    
    init();
    
    masterContainer.menuContainer.Auto.execFunction = Delegate.create(this, autoModeHandler);
    

    The function is successfully "sent" to the class of StandardButton, but without any parameters.  How can I send parameters for the instance of the class with the way I had it built.  Any help is greatly appreciated!

    Thank you for your time and help!

    You can pass parameters as you're passing that work.  you just need an instance of StandardBtn.

  • Problem with the published parameters between the movement of FCPX

    Hello

    I have a little problem with the settings published between the movement at FCPX.

    For some reason, the published parameters have different values within FCPX in movement.

    For example, in motion, a parameter is - 187.04 and in FCPX is-0,19. What are the parameters of position for CSOS.

    If I try to change this setting in FCPX, the application crashes after 10 seconds or less.

    No idea what is causing the problem? I re-edited the effect several times, same result. The software that I use is FCPX 10.2.2 and 10.2 of the Motion.

    MOTION

    FINAL CUT X

    Thank you.

    The values that you have published on the move have been compared to this project that you created. The values shown in FCPX are "consistent" with any project that you create. Often, you will see the center screen is 0.5, 0.5. Left and below are 0, right and up are 1.0. Or you could see Center of 0.0 and a range between - 0.5 and 0.5. Sometimes, you will see the numbers on the scale of some sort of percentage (vertical values will be 0-100 [%] and the horizontal will be based on the aspect of the project, for example, horizontal will be between 0 and 177.7778 for a project of 1920 x 1080, etc..) It will depend on the type of object and the parameters associated with what you posted.

    If you want to "correct" values in FCPX, you will probably need to rig settings, otherwise, just live with it.

    For what is * why * your model crashes FCPX, that will be another reason and not the difference in the numbers. So, can we get more information on the model?

    To use specific fonts?

    You publish alterations settings?

    Anything out of the ordinary?

Maybe you are looking for

  • Find bookmarks, urls and history double

    On Mac, Firefox version 14.0.1, which is the best add-on/app to find bookmarks, URLS and double-story? Thank you!

  • CAMERA BUGS AND ISSUES - please report them in this thread. REPORTS ONLY PLEASE.

    If you have had an accident unexplained camera or a bug please report it here in this one single thread. By reporting any camera hangs in one place and not in separate threads, as well as information on the configuration of the camera and aboved we h

  • 'Creative cloud' is working on a new admin account but not not in old account admin

    Hey community,. As my "Adobe Creative Cloud" was no longer working (not able to connect) on my old admin account. Adobe told me to create a new admin on 'El Capitan' account. Working on the new creative cloud account. (Adobe told me that there is a c

  • A specific problem with increment in a while loop

    Hello I'm pretty new to labview, I would be grateful if someone could help me out on this one. I am currently implementing a sweep of the tension, providing a starting Point, point stop and step size. I put in place using a point of loop, where a shi

  • Detect key locking

    Hello I need to detect if the user presses the locking button on the upper left of the BB (is a 8900 "BOLD"). I read in a post that it is not a specific listener but is possible to detect implementation of a MemoryCleanerListener because like RIM say