How to validate that a single check box is checked in detail block

Hi all

I am using oracle 10 G on windows forms.

I need help on how to validate that a single checkbox is checked in the retail block. I have multiple records in the block of detail and I have checkboxes for each record in the detail block.

I have a button to select values in the detail records where the check box is checked. But I want to make sure that only one record is not more than one check.

How to validate this on a shutter release button?

Thank you

When I did this sort of thing, I create a variable of TYPE number form level and then add or subtract the variable I to check and uncheck the boxes. If the value of the variable is 1, then you know that only check box is selected. If the value is greater than 1, then you know that the user has selected more than one checkbox. You could also add the code to your trigger when-box-changed to test the variable and tell the user to uncheck selected record before selecing a new record.

Regarding the variable level of form, you can use a GLOBAL package specification, PARAMETER or program unit. I prefer to use the specification of CENTRAL unit package, because this method has a smaller memory footprint. For example, in the node of the unity of the object browser program create the following:

/* Form variables package spec */
PACKAGE Form_Vars IS
  CheckBox_Cnt     NUMBER := 0;
END;

Now in your trigger when-box-change...

BEGIN
   IF ( Form_Vars.CheckBox_Cnt = 0 ) THEN
      Form_Vars.CheckBox_Cnt  := Form_Vars.CheckBox_Cnt  + 1;
   ELSE
      /* it's assumed the value is greater than 0 */
      Message('Please uncheck selec ted record before choosing a new record.');
      RAISE Form_Trigger_Failure;
   END IF;
END;

Hope this helps,
Craig B-)

If someone useful or appropriate, please mark accordingly.

Published by: Silvere on February 3, 2011 10:15

Tags: Oracle Development

Similar Questions

  • In my XP box, I installed 2 video card that has an output of 2 x 2. So now, I have 4 monitors with my single xp box. I want to join another 2 monitors to him. How can I do? Is it possible to attach?

    In my XP box, I installed 2 video card that has an output of 2 x 2. So now, I have 4 monitors with my single xp box. I want to join another 2 monitors to him. How can I do? Is it possible to attach?

    I want to join 6 screens with a single CPU.

    Hi DebBiswas,

    You can attach as much monitor you need, but it depends on the material if it supports or plug another video on the computer card.

    If you use SLI / Crossfire, the system must support more than 2 cards.

  • By creating a form that has several text boxes to a single character on the same line, how can I get the cursor to go in the next text box automatically after inserting a character?

    By creating a form that has several text boxes to a single character on the same line, how can I get the cursor to go in the next text box automatically after inserting a character?

    Create a text field and use the option 'comb n characters.

  • Hi, I have a PDF form that has multiple check boxes. Some boxes have values (off, yes) that others have just (Yes). How can I get the value of "Off" to all of the other boxes as well. Any help is greatly appreciated.

    Hi, I have a PDF form that has multiple check boxes. Some boxes have values (off, yes) that others have just (Yes). How can I get the 'Off' the value assigned to all the other boxes as well. Any help is greatly appreciated.

    'Off' is the default value of any box when it is not checked. It can not

    be changed.

  • How to calculate values that have a checked box beside them?

    Hi people,

    I'm new to Acrobat forms and have recently completed a complicated shape of the 7 page for a client and I'm very happy with it.

    But the customer comes back with the following query:

    They want checkboxes next to a series of values and, when a checkbox is checked, he added only makes TICK value. To show what I mean, please see the image below.

    sample.jpg

    So basically, there is a field at the side left (current monthly repayments) that cuts through all the values - in my example, this amounts to $50,00. Then, there is a field on the right side (repayments monthly future) to tally only values that have a checked 'yes' box to check next to them. In my example, this would produce a score of $20.00.

    Does anyone know how this could be done?

    Thank you

    Sorry, that line must be:

    CB = getField("CashFlowCheck"_+_i).valueAsString;

  • How to validate and save the values to a combo box and two text boxes in flex4 mxml application with as3

    helllo all,.

    I'm working on the application web flex4 with as3.

    I have a doubt, I've created a mxml it has two text boxes, except the button and a combo box that is has two option as a percentage and the amount.

    my needs are I gave here.

    need 1: when I choose option amount that two text boxes does not have to be editable.when I select text tat box two percentage option will be editable.

    need 2: when I select the percentage in combox option and two text boxes are empty, and then click the button Save-> I want to display warning msg

    need 3: when I select the option amount combox and the two boxes are emptu click the button Save-> I don't want any warning messages.

    How to validate it and how to write backup for this function.

    any suggession or extract code is welcome.

    Thanks in advance,

    B.Venkatesan

    Looks like you are trying to do too much at once. Try to hang the events correctly

    The close event of the comboBox can do something like this

    protected function toggleTextEditing(event:DropDownEvent):void

    {

    If (this.optionCmb.selectedItem.label is "Percentage")

    {

    This.Text1.editable = true;

    This.Text2.editable = true;

    }

    Else if (this.optionCmb.selectedItem.label == "Number")

    {

    This.Text1.editable = false;

    This.Text2.editable = false;

    }

    }

    The button's click event can do something like

    protected function save(event:MouseEvent):void

    {

    If (this.optionCmb.selectedItem.label is "Percentage")

    {

    If (this.text1.text == "" & this.text2.text == "")

    {

    Alert.Show ("text is empty");

    return;

    }

    on the other

    {

    }

    }

    Else if (this.optionCmb.selectedItem.label == "Number")

    {

    }

    }

    If you can put in your entire code, maybe I can have a look to see if I can find something wrong with that.

    -Pramod

    http://www.flexmycode.com

  • How can I get rid of the box that appears when you start Firefox 'Restore previous Session'?

    How can I get rid of the box that appears when you start Firefox 'Restore previous Session'?

    Subject: House is the default in Firefox 4 home page - look at the address bar containing the addresses of web page - it is the container for Google search, with a 'extract container' and below these elements is the Previous Session Restore button. It's not the same homepage that previous versions of Firefox used (although it is similar in appearance), it is a 'local' page that won't load the Internet.

    Set this page as your home page, which is what Firefox 3.6 and earlier versions had for the default home page. He has Previous Session Restore button/link.

    http://www.Google.com/Firefox

  • How can I force System File Check to Skip restoring a file that I don't want in my system?

    Original title: sfc/scannow, Skip File.

    How can I force System File Check to Skip restoring a file that I don't want in my system?

    Hi LucasDeMH,

    Auditor of files (SFC) system is an automated process that replaces the missing or corrupt files in Windows.  When you run the SFC scan it is not possible to manually stop a restore file.

  • I have a 2 page PDF, but I want to divide pages and save each in a single document. How to do that without having to print and scan?

    I have a 2 page PDF, but I want to split pages and save each in a single document. How to do that without having to print and scan?

    Cannot be done with the player; you will need Acrobat for that.

    If you do not have Acrobat, and it is a unique work, you can use the 30 day trial of Acrobat Pro DC: https://www.acrobat.com/en_us/free-trial-download.html

  • How can I change the page size of a pdf document so that I can check on my iphone more clearly?

    How can I change the page size of a pdf document so that I can check on my iphone more clearly?

    This is way beyond what can be done with PDF, except by copying the text and make a new document in Word or something.

    That said, Adobe Reader on Windows may display the text AS IF the PDF file has been divided. It's the text reformatting. It may be possible in Reader for iPhone, you can try the player for ios forum.

  • How to validate checkboxes without javascript onsubmit?

    Hi all

    I have an application that has a few boxes on a form. According to the selection of the checkbox, a button redirects the user to another URL. Now what I would do. I want to create a validation process that checks to see if one of these check boxes is selected. If none is verified by the branch to another URL (or page) should not be made. Instead an error message should be displayed.

    How to validate a checkbox control to a page or item validation of levels?

    Thanks in advance,

    Best regards Markus

    Create a Validation PL/SQL function - Page level return error text:

    BEGIN
       IF :p1_checkbox_1 IS NULL AND :p1_checkbox_2 IS NULL
       THEN
          RETURN 'Error Message!';
       END IF;
    END;
    

    and that's basically it.

    Denes Kubicek
    -------------------------------------------------------------------
    http://deneskubicek.blogspot.com/
    http://www.Opal-consulting.de/training
    http://Apex.Oracle.com/pls/OTN/f?p=31517:1
    -------------------------------------------------------------------

  • All my icons are the icon of iTunes and I don't know how he got that way.

    All my icons are the icon of iTunes and I don't know how he got that way.

    Run a system restore:

    1. Restoration of the system of search in the start menu and press ENTER.
    2. A box will appear. Click on Next >.
    3. Choose a restore point from before the problem started. If the problem started more than 5 days ago, check the boxview more than 5 days restore points and choose the one you need.
    4. Click on Next >.
    5. The selected restore point is listed. If it is correct, clickFinish; If it isn't, press on <> and choose another, and then repeat this step.
    6. A box will appear asking if you are sure you want to run the system restore. If you are sure, clickYes. The process will take between 15 minutes and several hours.

    Note:
    If you receive an error during the restore, boot in safe mode, and it should work fine. (To start in safe mode, restart your PC and press F8 after the screen with the logo of the manufacturer of your PC (BIOS screen) use the arrow keys to select and enter the choice, the option ofSafe Mode .)
    from: http://teengeek.freehostingcloud.com/help/systemrestore/

    If this does not work, try changing the associated programs with each file: http://teengeek.freehostingcloud.com/tutorials/changedefaultprograms/

    teengeek.freehostingcloud.com Microsoft community contributor

  • How to validate required fields XSD by validating the BPEL activity?

    Hi all

    Is anyone aware of how to validate only requires activity validate using XSD fields. When I'm trying to validate, validation activity is taken all the input fields its not taken specific fields. Someone suggest me how to do this.

    Thanks in advance.

    Thank you

    Hari

    Hello

    I have no experience with Schematron. But I don't have an example of a xlt:

    http://xmlns.Darwin-it.nl/CDM/XSD/v1/CBM/ADarwinProjectExample"/ >

    http://xmlns.Darwin-it.nl/CDM/XSD/v1/CBM/ADarwinProjectExample"/ >

    ?>

    "xmlns:XP20 ="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.Xpath20"

    "xmlns:bpws ="http://schemas.xmlsoap.org/ws/2003/03/business-process/"

    "xmlns:BPEL ="http://docs.oasis-open.org/wsbpel/2.0/process/executable"

    "xmlns:loc ="http://xmlns.darwin-it.nl/CDM/xsd/V1/CDT/Locatie"

    "" xmlns: xsi = "http://www.w3.org/2001/XMLSchema-instance"

    "xmlns:BPM ="http://xmlns.oracle.com/bpmn20/extensions"

    "xmlns:ORA ="http://schemas.oracle.com/xpath/extension"

    "xmlns:dwnzvpm ="http://xmlns.darwin-it.nl/CDM/xsd/V1/CBM/ADarwinProjectExample"

    "xmlns:socket ="http://www.oracle.com/XSL/Transform/java/oracle.tip.adapter.socket.ProtocolTranslator"

    xmlns:svnid = "" $Id: ADarwinProjectExampleCBM.xsd 148 14:55:49Z 2013-07-$23 ""

    "xmlns:mhdr ="http://www.oracle.com/XSL/Transform/java/oracle.tip.mediator.service.common.functions.MediatorExtnFunction"

    "xmlns:oraext ="http://www.oracle.com/XSL/Transform/java/oracle.tip.pc.services.functions.ExtFunc"

    "xmlns:DVM ="http://www.oracle.com/XSL/Transform/java/oracle.tip.dvm.LookupValue"

    "xmlns:HWF ="http://xmlns.oracle.com/bpel/workflow/xpath"

    "xmlns: med ="http://schemas.oracle.com/mediator/xpath"" xmlns: xsl = "http://www.w3.org/1999/XSL/Transform"

    xmlns:IDs ="http://xmlns.oracle.com/bpel/services/IdentityService/xpath"xmlns:version = "1.0.a"

    "xmlns:XDK ="http://schemas.oracle.com/bpel/extension/xpath/function/xdk"

    "xmlns:XREF ="http://www.oracle.com/XSL/Transform/java/oracle.tip.xref.xpath.XRefXPathFunctions"

    "container ="http://www.w3.org/2001/XMLSchema"

    "xmlns:Dom ="http://xmlns.darwin-it.nl/CDM/xsd/V1/CDD/Basis/Domeinen"

    "xmlns:BPMN ="http://schemas.oracle.com/bpm/xpath"

    "xmlns:jdz ="http://xmlns.darwin-it.nl/CDM/xsd/V1/COT/SomeCase"

    "xmlns:bas ="http://xmlns.darwin-it.nl/CDM/xsd/V1/CDD/Basis/Basis"

    "xmlns:BCT ="http://xmlns.darwin-it.nl/CDM/xsd/V1/CDT/Bericht"

    "xmlns:LDAP ="http://schemas.oracle.com/xpath/extension/ldap"

    exclude-result-prefixes = "xsi xsl loc dwnzvpm svnid psn version ns0 ns1 xsd dom jdz low bct ns2 xp20 APO bpel bpm ora socket mhdr oraext dvm hwf med xdk Xref bpmn ldap ID" >

    CDM

    ADarwinProjectExampleReqCBS

    1

    ADarwinProjectExample

    FUNCERROR

    Select = "' / dwnzvpm:aDarwinProjectExampleRequestCBM / dwnzvpm:businessData / dwnzvpm:informatieverzoekNatuurlijkPersoon" / > "

    Select = "' / dwnzvpm:aDarwinProjectExampleRequestCBM / dwnzvpm:businessData / dwnzvpm:informatieverzoekNietNatuurlijkPersoon" / > "

    Select = "' / dwnzvpm:aDarwinProjectExampleRequestCBM / dwnzvpm:businessData / dwnzvpm:informatieverzoekNatuurlijkPersoon / dwnzvpm:adres" / > "

    Select = "' / dwnzvpm:aDarwinProjectExampleRequestCBM / dwnzvpm:businessData / dwnzvpm:informatieverzoekNietNatuurlijkPersoon / dwnzvpm:adres" / > "

    DWN-00005

    An application must be made for a natural or non-natural person.

    Validation error

    DWN-00006

    A Dutch address cannot be questioned based on a cityname, but only based on a citycode.

    Validation error

    I think that it is fairly easy to add additional semantic checks.

    Kind regards
    Martian

  • Is there a way out quickly a single text box in several text boxes?

    I wanted for this feature for many years, and I want to know if there may be a script that can do this

    The scenario:

    I have a text box that contains 20 names. I want 20 text boxes, each containing 1 name.

    I know how to do it manually, but I want to be able to do this super fast, IE. make the machine for me to do.

    Thank you!

    Hi all

    The answer can be found here: is there a way to quickly break a single text box in several text boxes?

    separate lines of typelayer active;

    logic, if the properties of type are uniform;

    2014, use it at your own risk.

    #target photoshop

    If (app.documents.length > 0) {}

    myDocument var = app.activeDocument;

    var theLayer = myDocument.activeLayer;

    If (theLayer.kind == LayerKind.TEXT) {}

    Download the text a dleading;

    Var theLayer.textItem.contents.split("\r = Letexte");

    try {}

    Var first = theLayer.textItem.leading;

    }

    {} catch (e)

    Var first = theLayer.textItem.size * 1,2.

    };

    Var DECALER = 0;

    work outside of the table;

    for (var m = 0; m< thetext.length;="" m++)="">

    Duplicate layer, change its content and move it;

    var theNewText = theLayer.duplicate (theLayer, ElementPlacement.PLACEBEFORE);

    theNewText.textItem.contents = theText [m];

    theNewText.translate (0, DECALER);

    change the offset;

    DECALER = DECALER + first

    }

    }

    };

  • How to validate SQL syntax in Application Engine Peoplecode

    Hello

    Can someone help me to find out How to validate SQL in Application Engine Peoplecode. I just need to validate SQL syntax. If the syntax is wrong, it should save the exception in the log file but engine Apllication should not go WITHOUT success. App Engine should continue with other SQL validation to check the correct syntax and to retrieve values.

    Here is given is peoplecode, which is that I currently use.

    Thanks in advance.


    String local CSG_SQL_ID & sqltext;
    Local date & effdt;
    Local Boolean & sql_flag = True;

    & CSG_SQL_ID = CSG_REP_DIS_AET. CSG_SQL_ID. value;
    SQLExec ("SELECT DEV. CST PS_CSG_SQL_TMP, CRAD PS_CSG_REP_AUT_DST SQLTEXT WHERE CSE. CSG_SQL_ID = DEV. CSG_SQL_ID AND CST. EFFDT = DEV. EFFDT AND CST. CSG_SQL_ID =: 1 ", CSG_SQL_ID, & sqltext);

    Try

    & sql_flag = SQLExec (& sqltext);
    If & sql_flag = True Then
    & sql = CreateSQL (& sqltext);
    Local string SqlString = & sql. Value;
    Logger (String (ExtractTablesJob (& SqlString)));
    Logger (String (ExtractTablesDept (& SqlString)));
    End - If;

    catch Exception & sqlerror
    MessageBox (0, "", 0, 0, "found Exception");
    end - try;

    Ludi,

    I apologize: I remembered wrong. The Select Type must be reselect. I opened a ticket with Oracle on this problem. I hope that maybe they will build better error messaging tools, but we'll see. The real result of the ticket, it is that evolution to select Type of reselect solved my problem.

    Remember that when you Reselect it, you need to follow wherever you are. Reselect him running the DoSelect SQL statement every time until it returns no rows. So, you will need a flag turned on the table. You're DoSelect should select only the rows where the transformed flag is N. Then, you must update the line you are dealing with to set the flag turned on Y. In this way, you will pass through the processing of each lines.

    Also, just to be clear, I don't think that App Designer will ever "validate" your SQL. It allows the database to do that when you run it. It can be frustrating because up to now it is not telling you that you are developing, but the advantage is that App Designer does not limit you. You can place some SQL you want in your program, and it will transmit to the database. Stored procedures, functions, all work because the App Designer do not validate things specific special platform.

    If you wish, you can copy your SQL in the SQLExec to a SQL definition:
    SELECT THE DEV. SQLTEXT
    OF PS_CSG_SQL_TMP CST.
    PS_CSG_REP_AUT_DST SLAG
    WHERE CSE. CSG_SQL_ID = DEV. CSG_SQL_ID
    AND CSE. EFFDT = DEV. EFFDT
    AND CSE. CSG_SQL_ID =: 1

    You could name MY_AE_SQL.

    Then, in your App Engine PeopleCode, you can change the SQLExec in:
    SQLExec (SQL. MY_AE_SQL, & CSG_SQL_ID, & sqltext);

    This will place your SQL in a place that teaches better, but I don't think that it will validate it no more. In my opinion, it makes your code more difficult to read. Someone coming along behind you must open several pieces of code to see what your program does.

    The more I watch your program, you want probably to validate and protect the SQL code that is in & sqltext, rather than the SQLExec. If you want it to be dynamic, I don't see what you can do.

    You could possibly launch an other App Engine as another process. You can use the object API ProcessRequest to plan the program through the process scheduler. You must pass your dynamic SQL code to the other program through a sort of serial control. In this way each SQL would go as a separate instance in process monitor and would go to success or no success individually. I still think it's too complicated.

    I hope these thoughts help. It looks like a difficult task.

    Stephen

Maybe you are looking for