Dynamically access item names from plsql block?

hi folks - is it possible to access the block/item names inside a form, from a plsql block within the form? does that make sense, probably not, it's gone 5pm and my brains fried today.
I want to try and control access to various items from within a back end table. Then in the form startup, I wanted to loop through the item names, fire them through to a check_access() function, and display or hide them depending on the result.
does that sound possible, to get the item names at runtime, or do I have to hard code each item name I want to pass to the function?
ps. forms 10g
thanks.

yes! check it out:
Looping Through Items in a Data Block

Similar Messages

  • Unix command from Plsql block

    Hi all ,
    I have tried unix command from PLSQL Block,
    Please see the code.
    DECLARE
    stat INTEGER;
    host_command varchar2(100);
    errormsg VARCHAR2(80);
    command varchar2(2000);
    BEGIN
    command:='touch /home/oracle/testting.txt';
    dbms_pipe.reset_buffer;
    host_command:= dbms_pipe.unique_session_name;
    dbms_output.put_line('host_command:'||host_command);
    dbms_pipe.pack_message(command);
    dbms_output.put_line('pack message:'||command);
    stat := dbms_pipe.send_message(host_command);
    dbms_output.put_line('stat:'||stat);
    IF stat <> 0 THEN
    raise_application_error(-20000, 'Error:'||TO_CHAR(stat)||' sending on pipe');
    END IF;
    stat := dbms_pipe.receive_message(host_command);
    dbms_output.put_line('stat2:'||stat);
    IF stat <> 0 THEN
    raise_application_error(-20000, 'Error:'||TO_CHAR(stat)||' receiving on pipe');
    END IF;
    dbms_pipe.unpack_message(errormsg);
    dbms_output.put_line('errormsg:'||errormsg);
    IF errormsg <> 'SUCCESS' THEN
    raise_application_error(-20000, 'Execution error: '||errormsg);
    END IF;
    END;
    Nothing happend from this code just getting only following result with error.
    -----------------result-----------------------------
    host_command:ORA$PIPE$002D19820001
    pack message:touch /home/oracle/testting.txt
    stat:0
    stat2:0
    errormsg:touch /home/oracle/testting.txt
    DECLARE
    ERROR at line 1:
    ORA-20000: Execution error: touch /home/oracle/testting.txt
    ORA-06512: at line 33
    Can any one tell me what i doing wrong in this code.
    I m working on Oracle 11g and AIX unix server.

    This is the forum for the SQL Developer product, not for general PL/SQL questions. There is a link to the SQL and PL/SQL forum in the announcement at the top of this forum.

  • How to Access Item Names Property of ListBox inside of Cluster?

    In LabVIEW 2010 I have a Cluster of Controls on the Front Panel. In that Cluster I have a ListBox. How do I access the Item Names Property of the ListBox in my Block Diagram.
    From the Cluster, I can get the ListBox, but that returns an I32 value, probably the index of the selected Item.
    In the Block Diagram, how can I get the Item Name Property of the ListBox from a Reference to the Cluster?
    THANKS.
    Solved!
    Go to Solution.

    by using the "controls" array of your cluster, you can access the individual elements. You have then to convert the reference to a "more specific class" using a reference to an arbitrary listbox (or a constant reference of the required type), then you can access all properties of your listbox.
    THINK G!! ;-)
    Using LabView 2010 and 2011 on Mac and Win
    Programming in Microsoft Visual C++ (Win), XCode (Mac)

  • How to get the Portal Page name from PLSQL?

    Can anyone tell me how to get the portal page name from my dynamic page using plsql?
    Apparently you can get the page id and work it out from there, but my calls to get the page id are not returning any values anyway.
    My code for attempting to get the page id is below.
    <oracle>
    declare
    v_pageid varchar2(30);
    begin
    v_pageid := wwpro_api_parameters.get_value('_pageid', '/pls/portal30');
    htp.print('Page is '|| v_pageid);
    end;
    </oracle>
    Ideally I'd actually just like to get the page name. Is there a straightforward way to do this?
    Thanks in advance!
    Sarah

    Few clarifications -
    1. wwpro_api_parameters cannot be used to get default portal
    page parameters such as '_pageid', '_dad', '_schema' etc.,
    2. Page information can be obtained through any components which
    are available in that particular page. For example, in case of
    dynamic page, we need to publish it as a portlet and add it to the
    page. This process creates necessary packages in the DB, but we
    will not have access to the portlet methods.
    So, I would prefer creating a simple DB provider & portlet and access
    page title from its show method as follows -
    //Declare local variable l_page_id, l_page_title as varchar2
    select page_id into l_page_id from wwpob_portlet_instance$ where
    portlet_id = p_portlet_record.portlet_id and
    provider_id = p_portlet_record.provider_id;
    select name into l_page_title from wwpob_page$ where id=l_page_id;
    More information on DB provider can be found at
    http://portalstudio.oracle.com/pls/ops/docs/FOLDER/COMMUNITY/PDK/articles/understanding.database.providers.html
    Secondly, usage of wwpro_api_parameters.get_value method is
    incorrect. This method expects two arguments -
    <ul>
    <li><b>p_name : </b> The name of the parameter to be returned.</li>
    <li><b>p_reference_path : </b> An unique identifier for a portlet instance on the current page.</li>
    </ul>
    p_reference_path would be something like 99_SNOOP_PORTLET_76535103 and not some type of path as its name suggests.
    The following code fragment fetches all parameters available
    for a portlet.
    Note : Copy this code into 'show' method of your portlet.
    //Declare l_names, l_values as owa.vc_arr
    * Retreive all of the names of parameters for this portlet
    l_names := wwpro_api_parameters.get_names(
    p_reference_path=>p_portlet_record.reference_path);
    * Retreive all of the values of parameters for this portlet
    l_values := wwpro_api_parameters.get_values(p_names=>l_names,
    p_reference_path=>p_portlet_record.reference_path);
    //Loop through these arrays to get parameter information
    htp.p('<center><table BORDER COLS=2 WIDTH="90%" >');
    htp.p('<tr ALIGN=LEFT VALIGN=TOP>');
    htp.tableData(wwui_api_portlet.portlet_heading('Name',1));
    htp.tableData(wwui_api_portlet.portlet_heading('Value',1));
    htp.tableRowClose;
    if l_names.count = 0 then
    htp.p('<tr ALIGN=LEFT VALIGN=TOP>');
    htp.p('<td COLSPAN="2">'
    ||wwui_api_portlet.portlet_text(
    'No portlet parameters were passed on the URL.',1)
    ||'</td>');
    htp.tableRowClose;
    else
    for i in 1..l_names.count loop
    htp.p('<tr ALIGN=LEFT VALIGN=TOP>');
    htp.tableData(l_names(i));
    htp.tableData(l_values(i));
    htp.tableRowClose;
    end loop;
    end if;
    htp.p('</table></center>');
    Hope it helps...
    -aMJAD.

  • How do I write javascript for a text block to extract name from signature block?

    Hello,
    I've created a training certificate that the trainee has to sign electronically. To prevent someone from simply putting in their friends name in there and saving it; to send to their friend and help them from having to take the training and quiz I would like to write a javascript in the text block that would extract the name from their signature block and autofill the name in the text block. Is there a way to do this?

    You would have to use JavaScript to access the signature field object and then you can access the various properties of the signature depending upon the certificate or method for signing.
    signatureInfo
    console.show();console.clear();
    // Get particular info;
    var f = this.getField("Signature1");
    // uses the ppklite sig handler;
    var Info = f.signatureInfo();
    // Some standard signatureInfo properties;
    console.println("name = " + Info.name);

  • Unable to insert row in object table from plsql block

    I have table called test based on an object type. When I issue an insert statement from sqlplus, the row is inserted. The exact same sql statement in a plsql block gives the error below. Any ideas? (it is not a constraint problem).
    SQL> insert into test values( 3,2,1,1,'asp',1,'mach' );
    1 row created.
    SQL> begin
    2 insert into test values( 3,2,1,1,'asp',1,'mach' );
    3 end;
    4 /
    insert into test values( 3,2,1,1,'asp',1,'mach' );
    ERROR at line 2:
    ORA-06550: line 2, column 16:
    PL/SQL: ORA-06552: PL/SQL: Compilation unit analysis terminated
    ORA-06553: PLS-302: component 'DOCUMENT' must be declared
    ORA-06550: line 2, column 4:
    PL/SQL: SQL Statement ignored
    (ddl)
    CREATE OR REPLACE type document as object
    DOC_ID NUMBER (38),
    BATCH_ID NUMBER (38),
    STATE NUMBER (2),
    TRANSIENT NUMBER (2),
    ASP VARCHAR2 (20),
    USER_ID NUMBER (6),
    MACHINE VARCHAR2 (30),
    MEMBER PROCEDURE setState,
    MEMBER function getState RETURN NUMBER
    ) not final;
    create table test of document;

    Hi Adam
    You need to instantiate your object type in your insert statement(while doing through PL/SQL block), so try like this
    Insert into test values(document(1,2,'CO',55,'xyz','kkk','PENTIUM'));
    The reason you were successful through SQLPLUS was that, SQLPLUS automatically instantiate the values into object type.
    Qurashi

  • Find item name from item id

    Hi!
    We have a library procedure that accepts block id as parameter.
    The procedure fetches some block realted information from the database. So, it needs to refer to the block name.
    Is there any way find the block name from block id?
    Rgds,
    SB

    This is pretty crude, but it will work. Maybe someone else can suggest a better way:
    Function Block_Name(B Block) return varchar2 is
      Blk_Nam varchar2(30);
    Begin
      Blk_Nam := Get_Block_Property(B,NextBlock);
      If Blk_Nam is not null then
        Blk_Nam := Get_Block_Property(blk_Nam,PreviousBlock);
      Else
        Blk_Nam := Get_Block_Property(B,PreviousBlock);
        If Blk_Nam is not null then
          Blk_Nam := Get_Block_Property(Blk_Nam,NextBlock);
        Else --only one block in Form
          Blk_Nam := Get_Form_Property(:System.Current_Form ,First_Block);
        End if;
      End if;
      Return(Blk_Nam);
    End;

  • Accessing Printer name from Registry

    Hi,
    I am trying to use the following program to get the Printer name from my Registry.. this program has been taken from Forums.
    package yourpackage;
    import java.awt.Graphics;
    import java.awt.print.PageFormat;
    import java.awt.print.Printable;
    import java.awt.print.PrinterException;
    import java.awt.print.PrinterJob;
    import oracle.forms.ui.VBean;
    import oracle.forms.properties.ID;
    public class printDialog extends VBean
    private static final ID PRINTER = ID.registerProperty("PRINTER");
    public printDialog()
    class PrintObject implements Printable
    public int print (Graphics g, PageFormat f, int pageIndex)
    return NO_SUCH_PAGE;
    public Object getProperty(ID id)
    if (id == PRINTER) {
    PrinterJob job = PrinterJob.getPrinterJob();
    job.setPrintable(new PrintObject());
    if (job.printDialog())
    return job.getPrintService().getName();
    } else {
    return null;
    } else {
    return null;}
    This program when compiled gives me the error as
    Error(32,12): method getPrintService() not found in class java.awt.print.PrinterJob
    I did set the project settings from Project-Project Settings and included Oracle Forms Libraries. But I still continue to get the error.
    What is the relevant class that I have to add and also how will I add it as I am a bit new to JDev.
    Early response would be highly appreciated
    Thanks a lot for your time and help
    Narain.

    Narain,
    the code is from Oracle Forms and wont run in any other context. The code used within this sampel is teh Java printing services API available in Java 1.4.
    http://java.sun.com/j2se/1.4.2/docs/guide/jps/spec/JPSTOC.fm.html
    Frank

  • Item name in detail block changed!?  Help please!

    Hi, All
    I have a master-detail relationship. The join condition is Mast.ref_id = Detail.id. There was no returning records when I run datablock. When I came backe to the form, I found that the item name for Detail.Id was changed to FMNITE. I tried a few times, the name changed to different wierd charactors.
    Did anybody have this problem?
    Thanks,
    Deborah

    Hi Deborah,
    I've had two times the same problem. Delete the relation, delete the Item and recreate them both. That was in my cases enough workaround. Before I did it, I have restartet the Forms Builder.
    Have luck
    Gerd

  • Execute immediate issue while calling a procedure from plsql block

    Hi all,
    I have the following simple code ,my execute immediate is not working(I am pasting the error below as well)
    CREATE OR REPLACE PROCEDURE CALL_RAHUL_PROCEDURES
    AS
    strng varchar2(1000);
    BEGIN
    for i in (select proc_name,flag,id from rahul_procedures order by id)
    loop
    if (i.flag = 'Y')
    then
    strng := 'exec '||i.proc_name||'(''rahul'')';
    dbms_output.put_line(strng);
    execute immediate strng;
    end if;
    end loop;
    END CALL_RAHUL_PROCEDURES;
    Error:
    Connecting to the database INQDWD.
    ORA-00900: invalid SQL statement
    ORA-06512: at "ETLADMIN.CALL_RAHUL_PROCEDURES", line 17
    ORA-06512: at line 2
    exec RAHUL_HELLO_WORLD2('rahul');
    Process exited.
    Disconnecting from the database INQDWD.
    data in rahul_procedures table :
    Proc_name flag Id
    RAHUL_HELLO_WORLD     N     1
    RAHUL_HELLO_WORLD2     Y     2
    RAHUL_HELLO_WORLD     N     3
    RAHUL_HELLO_WORLD3     N     4
    please help.
    Regards
    Rahul

    Mac_Freak_Rahul wrote:
    Well I have to call 26 procedures one by one and the names of the procedures would be in a table'rahul_procedures' Which is 100% wrong.
    Data is stored in tables, program code is stored in procedures or view defintions.
    http://en.wikipedia.org/wiki/Data_%28computing%29
    >
    Data vs programs
    Typically, different files are used to store programs vs data. Executable files contain programs; all other files are data files.
    >
    So you have just violated the primary distinction between data and program code.
    I dont find anything strange in my question,Only because you do not appear to know what you are doing or the difference between data and program code.
    http://asktom.oracle.com/pls/apex/f?p=100:11:0::::P11_QUESTION_ID:1943344500346351703
    >
    ugh, what an ugly "design". I can see your life will be full of performance issues, strange 'bugs', and other unpleasant side effects. I mean, it all looks "so cool", but it'll be a nightmare to maintain and enhance.
    but then you have the issue of binds, which will be intractable. You'd have to know the binds at compile time, but you have hidden all of your sql in a magic generic table - so you cannot possibly know your binds at compile time.
    I would suggest you discard all of this code (I am DEAD SERIOUS) and start over. This is a bad idea from the get go. Or at least do me a favor and do not use plsql (you make it look like a good database implementation, but it isn't)
    The objective here is to store SQL Statements in a Table(a sql repository) and just call the required SQL from the application using the sqlid using the sql_execute procedure. ...
    CHANGE YOUR OBJECTIVE.
    How about this for a good objective:
    the objective here is to store sql statement in a plsql routine (a sql repository, you call a procedure and we run sql) and just call the required sql form the applicatoin using the STORED PROCEDURE
    sorry, can I think of hacks to get you going? yes, application contexts come to mind - a fixed number of binds comes to mind. Am I going to work them out? No - it is the wrong way to approach a database application.

  • How Automate Dynamically Embedding Customer Names from a List into PDF Footer?

    Mavens,
    After discovering that a PDF training workbook of mine has been widely copied (without authorization), I'd like to "personalize" future versions of this artifact with the customer/user name dynamically embedded in each PDF's footer.
    Based on your experience, what is the easiest, quickest & most economical way to: generate a set of PDFs (from a "Master") where each individual PDF is personalized with a user/customer name in the footer (e.g., "This document is licensed to {FRED BLOTZ} at {BIG COMPANY, Inc.}. Duplication or distribution is not authorized.").
    The desired workflow is:
    1. Create an MS-Excel Workbook with a list of all trainee (user) names.
    2. Open some type of "PDF Personalization" tool.
    3. Provide the path to the "Master PDF" to the tool.
    4. Provide the name of the customer (company) to the tool.
    5. Provide a path to the MS-Excel Workbook with list of individual's names.
    6. Provide a path to a folder where the tool should write the generated PDFs.
    7. Click a button ("Generate Personalized PDFs").
    Then...distribute individualized PDFs to trainees.
    Is there a tool out there somewhere which provides the desired solution?
    Thank you in advance for your experienced-based suggestions.
    Plane Wryter
    PS: While I fully appreciate the on-going discussions regarding the merits/lack-of-merits of DRM, etc...if you elect to reply to this request...please be so kind as to focus on the question as presented and avoid clambering onto a soapbox to "rant" about DRM...or suggest increasing the fee to the customer (a big firm that only pays "per-trainee" fees) to cover distribution. Thank you.

    go to database, show sql query. please paste the query in here it will be easier to help you
    if you cant seem to get it from there, go to database, database expert and edit the command file. (if that is the dataset you are using) copy and paste that.

  • How to get the item name from a column in an interactive report?

    I created an interactive report. Then on the same page I added a tabular form region. What I want to implement is that, when I click a column link button on a specific row, the name of the row will be passed to the tabular region, so that the tabular region can list the corresponding items that belong to that specific row. But I have no idea what the name it is. Any idea? Thanks!

    Thanks! I've got it work! Now I can associate many product to a specific ProductNumber.
    Another issue comes up: I want to be able to add more products in this category. But when I press the "Add Row" button, it generates a new line but with ProductNumber null. This results me in failing to insert the new record, because the rule is that ProductNumber can't be null, and also it can't be assured that the new record is associated with this category (ProductNumber). What can I do to make it automatically come up with the same ProductNumber for new records? I guess some kind of a trigger may be needed, but I don't know how to do it.
    I made a screenshot here: http://img25.imageshack.us/img25/3051/98605982.png
    Thanks!

  • How to access item renderer from main mxml?

    Hi,
    I have a datagrid which has item renderer. Code looks like this:
    <mx:DataGrid id="newsfeedgrid" width="100%" height="100%" visible="true" verticalScrollPolicy="auto"
                                  verticalGridLines="false" horizontalGridLines="true" horizontalGridLineColor="#E5F0F3" showHeaders="false"
                                  rowHeight="70" wordWrap="true" resizableColumns="false">
                                  <mx:columns>
                                            <mx:DataGridColumn headerText="Image Name" dataField="imgname" width="100">
                                            <mx:itemRenderer>
                                                      <mx:Component>
                                                                <mx:VBox height="100%" width="100%">
                                                                <!--          <mx:Image source="{data.imgname}" height="100%" width="100%"/>-->
                                                                <local:SmoothImage source="{'http://localhost/musicbook/attachdoc/'+data.imgname}" height="100%" width="100%"/>
                                                                          <mx:Text text="{data.fname+' '+data.lname}" fontSize="10" fontWeight="bold" fontFamily="Verdana" color="#3D3636"/>
                                                                </mx:VBox>
                                                      </mx:Component>
                                            </mx:itemRenderer>
                                            </mx:DataGridColumn>
                                            <mx:DataGridColumn headerText="Messages" dataField="mymsg" wordWrap="true" resizable="true"
                                                      >
                                                      <mx:itemRenderer>
                                                                <mx:Component>
                                                                          <mx:VBox verticalScrollPolicy="off" creationComplete="lbl_initialize()">
                                                                                    <!--<mx:HBox width="100%">
                                                                                              <mx:Text text="{data.uname}" width="100%" color="BLUE" fontSize="10" fontWeight="bold"
                                                                                              useHandCursor="true" buttonMode="true" mouseChildren="false"
                                                                                              click="this.outerDocument.userPage('msgFromC onnGrid')"/>
                                                                                              <mx:Text text="{data.actmsg}" width="100%" fontSize="10" fontWeight="bold"
                                                                                              />
                                                                                              <mx:Text text="{data.secuname}" width="100%" color="BLUE" fontSize="10" fontWeight="bold"
                                                                                              useHandCursor="true" buttonMode="true" mouseChildren="false"
                                                                                              click="this.outerDocument.userPage('msgFromC onnGrid')"/>
                                                                                    </mx:HBox>-->
                                                                                    <mx:Text id="lbl" width="100%"
                                                                            selectable="true"
                                                                            link="lbl_link(event);" />
                                                                                    <!--<mx:ControlBar id="cbar">-->
                                                                                    <mx:Spacer height="50%"/>
                                                                                    <mx:HBox width="100%">
                                                                                    <mx:Text text="{data.datetime}" fontSize="7" color="#8B9698"/>
                                                                          </mx:HBox>
                                                                           <mx:Script>
                                                                        <![CDATA[
                                                                            import mx.controls.Alert;
                                                                                    public var tempsecuname:String;
                                                                            private function lbl_initialize():void {
                                                                                      /* if(lbl.text=="Pratik is good")
                                                                                                lbl.htmlText="<a href='event:flex.org'>Good</a> is Pratik";
                                                                               //lbl.htmlText = "For more information on Flex, see <u><a href='event:flex.org'>http://www.flex.org/</a></u>.";
                                                                                if(data.secuname==null)
                                                                                          tempsecuname = "";
                                                                                else
                                                                                          tempsecuname=data.secuname;
                                                                               lbl.htmlText="<a href='event:flex.org'><font color='#2112EF'><b>"+data.uname+"</b></font></a>"+data.actmsg+"<a href='event:flex.org'><font color='#2112EF'><b>"+tempsecuname+"</b></font></a>";            
                                                                            private function lbl_link(evt:TextEvent):void {
                                                                                Alert.show(evt.toString(), evt.text);
                                                                                switch (evt.text) {
                                                                                    case "flex.org":
                                                                                        // You clicked the flex.org link.
                                                                                        break;
                                                                        ]]>
                                                                    </mx:Script>
                                                                          </mx:VBox>
                                                                </mx:Component>
                                                      </mx:itemRenderer>
                                            </mx:DataGridColumn>
                                  </mx:columns>
                                            </mx:DataGrid>
    Problem currently is since lbl_initialize() function is called on creationComplete of Vbox, output displayed is not expected and when ever i navigate to grid page output gets changed and it is not proper.
    I wanted to use text ,lbl, in my main.mxml so that i can assign the value when i am setting data provider.
    Please help!!!

    Thanks for your reply.. overriding set data in fact is a better approach and my half problem is solved but i am still facing some issues. Please find my code below:
    <mx:DataGridColumn headerText="Messages" dataField="mymsg" wordWrap="true" resizable="true"
                                                      >
                                                      <mx:itemRenderer>
                                                                <mx:Component>
                                                                          <mx:VBox verticalScrollPolicy="off" >
                                                                                    <mx:Text id="lbl" width="100%"
                                                                            selectable="true"
                                                                            link="lbl_link(event);" />
                                                                                    <!--<mx:ControlBar id="cbar">-->
                                                                                    <mx:Spacer height="50%"/>
                                                                                    <mx:HBox width="100%">
                                                                                    <mx:Text text="{data.datetime}" fontSize="7" color="#8B9698"/>
                                                                          </mx:HBox>
                                                                           <mx:Script>
                                                                        <![CDATA[
                                                                                  import mx.core.Application;
                                                                            import mx.controls.Alert;
                                                                                    public var tempsecuname:String;
                                                                                    public var tempmsg:String="";
                                                                                   override public function set data( value:Object ) : void {
                                                        super.data = value;
                                                                               lbl.htmlText="<a href='event:data.uname'><font color='#2112EF'><b>"+data.uname+"</b></font></a>"+tempmsg;
                                                                               if(data.datetime>Application.application.lastlogout)
                                                                                         Alert.show(Application.application.lastlogout);
                                                                                         lbl.setStyle("fontWeight","bold");
                                                                            private function lbl_link(evt:TextEvent):void {
                                                                        ]]>
                                                                    </mx:Script>
                                                                          </mx:VBox>
                                                                </mx:Component>
                                                      </mx:itemRenderer>
                                            </mx:DataGridColumn>
    Now my text is coming properly with link like how i wanted. I have added here another functionality where I am checking the last logouttime of user and the msg time and if msgtime is greater than last logout time then i am showing it in bold.
    override public function set data( value:Object ) : void {
                                    super.data = value;
                    lbl.htmlText="<a href='event:data.uname'><font color='#2112EF'><b>"+data.uname+"</b></font></a>"+tempmsg;
                    if(data.datetime>Application.application.lastlogout)
                    Alert.show(Application.application.lastlogout);
                    lbl.setStyle("fontWeight","bold");
    First time is shows properly but if i scroll then some random row is also appearing in bold, also when ever this set data function is getting called some random rows are coming in bold.
    Please let me know your input

  • Radio button item value from plsql

    Hi,
    I have a radio button with 3 options on a region (P3_RADIO1). With pressing a button I would like to check the value of P3_RADIO1. But in plsql :P3_RADIO1 is empty. How can I reach the selected return_value of then radio button item?
    A.

    Hi,
    Reasonable straightforward. You just need to use the bound values of the radio button (1 or 2):
    switch (this.rawValue)
        case "1":
        Response12BN.presence = "invisible";
        xfa.host.messageBox("Attach a copy of your company’s safety manual and safety incentive programs.",  "SAFETY PROGRAM ATTACHMENTS", 3, 1);
        break;
        case "2":
        Response12BN.presence = "visible";
        Response12BN.rawValue = xfa.host.response("Please enter the reason you do not have a Written Safety Program here", "WRITTEN SAFETY PROGRAM");
        break;
    Should work,
    Niall

  • Trying to save an item name in a block so I can return to it.

    Hi
    I'm working with Oracle 10g forms developer.
    I'm trying to save the field I'm in so that after I press a button to do stuff and return. I go back to the field I was in.
    I've tried assigning :system.cursor_item and :system.trigger_item to a variable in my sys block but I keep getting the error
    FRM-41506: Cannot find Block: invalid ID. I'm doing this in the post-change trigger of the item I want to return to.
    It seems to be objecting to the statement :sys.current_discounting_field := :system.trigger_item;.
    Can anyone help please?

    try this:
    +{YOU WILL HAVE TO DO WHATEVER PROCESSING WHERE APPROPRIATE}+
    DECLARE
    v_currec NUMBER(4);
    v_curfld VARCHAR2(50);
    BEGIN
    v_currec := :SYSTEM.CURSOR_RECORD;
    v_curfld := :SYSTEM.CURRENT_VALUE;
    COPY (:SYSTEM.CURSOR_RECORD, :p_block || '.' || :p_field);
    GO_RECORD(v_currec);
    GO_FIELD (v_curfld);
    END;

Maybe you are looking for