Set variable in a parent form

HI All,
I have a form listing all my items in a datagrid, when I
click in one I open
different form where is all my item description in detail.
But to select one
item from my data I have to setup the item ID, how can I do
that. I try this
but doesn't work.
this.visible = false;
this.parentApplication.itemDesc_mxml.itemNewID =
items_dg.selectedItem.itemID;
this.parentApplication.itemDesc_mxml.visible = true;
In my itemDesc_mxml I have this
[Bindable]public var itemNewID:Number = 0;
public function init():void
if (itemNewID != 0){
my_RO.getItem();
Please help
Rgds
JFB

It's difficult to tell from your code, but this line seems a
bit suspicuos:
this.parentApplication.itemDesc_mxml.itemNewID =
items_dg.selectedItem.itemID;
it may be that you simply want:
itemDesc_mxml.itemNewID = items_dg.selectedItem.itemID;
which I assume you are calling from parent of itemDesc_mxml.
Also when you make itemDesc_mxml visible you should also call
itemDesc_mxml.init( );

Similar Messages

  • How to send a TextBox value to a variable in the parent form in C#?

    I have an aboutBox control ("settings") that has a textBox in it. When the user presses the save button on this settings I want it to save the string from the textBox, pass it to a variable in the main form, close the settings box and then press
    a button in the main form.
    How would this be done?
    Thank you!

    what do u mean by "text saved in the textbox"?
    if you mean to set the value into the Textbox in the form2
    private void Form2_Loaded(object sender, EventArgs e)
    this.TextBox1.Text =valueFromForm2;
    2) When you click the save button on form2 it is already calling the delegate what do u mean by firing event?

  • Can one Recordset created in the Main/Parent form be used in more than one Subform?

    Hi
    Can one Recordset created in the Parent form be used in more than one Subform?  The parent and subforms are unbound.
    If so, how do I do this?
    Many thanks for your help!
    smsemail

    You can declare a public object variable in the parent form's module's Declarations area:
        Public rs As DAO.Recordset
    Then, anywhere in the parent form's module:
        Dim strSQL As String
        strSQL= "SELECT etc"
        Set rs = CurrentDb.OpenRecordset(strSQL)
    In a subform's module, or anywhere else for that matter while the form is open, you can return a reference to the recordset as a property of the class:
        Form_YourParentFormName.rs
    Ken Sheridan, Stafford, England

  • How to access objects in the Child Form from Parent form.

    I have a requirement in which I have to first open a Child Form from a Parent Form. Then I want to access objects in the Child Form from Parent form. For example, I want to insert a record into a block present in Child Form by executing statements from a trigger present in Parent Form.
    I cannot use object groups since I cannot write code into Child Form to first create object groups into Child Form.
    I have tried to achieved it using the following (working of my testcase) :
    1) Created two new Forms TESTFORM1.fmb (parent) and TESTFORM2.fmb (child).
    2) Created a block named BLK1 manually in TESTFORM1.
    3) Created two items in BLK1:
    1.PJC1 which is a text item.
    2.OPEN which is a push button.
    4) Created a new block using data block wizard for a table EMPLOYEE_S1. Created items corresponding to all columns present in EMPLOYEE_S1 table.
    5) In WHEN-NEW-FORM-INSTANCE trigger of TESTFORM1 set the first navigation block to BLK1. In BLK1 first navigable item is PJC1.
    6) In WHEN-NEW-ITEM-INSTANCE of PJC1, code has been written to automatically execute the WHEN-BUTTON-PRESSED trigger for the "Open" button.
    7) In WHEN-BUTTON-PRESSED trigger of OPEN item, TESTFORM2 is opened using the following statement :
    open_form(‘TESTFORM2',no_activate,no_session,SHARE_LIBRARY_DATA);
    Since its NO_ACTIVATE, the code flows without giving handle to TESTFORM2.
    8) After invoking OPEN_FORM, a GO_FORM(‘TESTFORM2’) is now called to set the focus to TESTFORM2
    PROBLEM AT HAND
    ===============
    After Step 8, I notice that it passes the focus to TESTFORM2, and statements after go_form (in Parent Form trigger) doesnot executes.
    I need go_form with no_activate, similar to open_form.
    Edited by: harishgupt on Oct 12, 2008 11:32 PM

    isn't it easier to find a solution without a second form? If you have a second window, then you can navigate and code whatever you want.
    If you must use a second form, then you can handle this with WHEN-WINDOW-ACTIVATED and meta-data, which you have to store in global variables... ( I can give you hints if the one-form-solution is no option for you )

  • Imported Form and sub-form from another database. Sub-form not creating new records tied to parent form's data.

    I have imported all objects from an old access db (.adp file) into a new db (.accdb).  All of my data lives in sql server so I have added all the tables and views to the .accdb as linked tables.  My forms all connect to data, but I am having issues
    with a sub form.  The sub form does not allow for creation of children records tied to the parent record the way the old db did/does.
    Correct - old format .adp file (notice the empty second record in sub-form with the defaulted date of today's date):
    Incorrect - new .accdb file (notice the lack of empty second record in sub-form like above):
    If I click the create new record icon in the bottom of the subform, it creates a completely blank record not tied to the parent record (fields blacked out in screen shots above).  When using this button all parent record fields are blank.  
    I have also verified the child table used in the sub-form has a valid Fky relationship to parent table used in the parent form.
     

    Have you checked each forms 'Filter' property (in Design view) to make sure they are blank and that each forms 'Filter On Load' property to make sure it is set to 'No'? Also, you might try inserting the following commands in each forms On
    Open event:
    DoCmd.RunCommand acCmdRemoveAllFilters
    DoCmd.ShowAllRecords
    If you can open each forms Record Source and they are showing that new records are able to be entered (the new record * is showing at the bottom of the recordset), then check each forms On Load and On Open events to make sure there is no filtering.
    In addition, check any macro or VBA commands behind the button that opens the main form to make sure there is no SQL filtering in the DoCmd.OpenForm command.
    If one of the forms Record Source does NOT allow new records, then you will need to change that Record Source so the new record * indicator shows.
    Out of ideas at this point.

  • Accessing variables in a parent class?

    Hello everyone,
    I'm rather new to java, and I've been looking at the documentation a bit but am still trying to figure out just what I am looking for. I've posted an example of such before where I have two seperate files, the parent class file and the child class file. What I want to do is somehow return the instance of parent that child was created with from the below code.
    public class parent {
         protected int var;
         public static void main(String[] args) {          
              child chld = new child();
    }Is it possible to get the same instance of parent that created the child? If so, can it be used to access or modify the variables held by parent? Or is it only possible to do this by creating methods to set or get the value of the variable?
    Can someone point me to the proper term as well, so as I might check the manual as well?

    Another thing I just noticed; your question does not seem to match your post's subject title. Taking that into context, it is possible to read your post very differently. Do you mean that you want to reference parent from inside of its own method, not necessarily after it has returned?
    You can access an object's variables and its methods from within a method it owns. To clarify what I mean...
    public class Something
        int someData = 0;
        public void someAction()
            // Something has a variable "someData" which can be accessed directly from inside of Something's own method someAction()
            someData = 5;
            System.out.println(someData);
    }If you mean you want a reference to the object itself from within one of its methods, Google for the "this" keyword.
    None of these have anything to do with the child object though, so I'm still a bit stumped as to what exactly you mean. Perhaps a combination of all answers received so far?
    Again, you probably need to further clarify exactly what you're looking for.

  • Accessing a variable declared in another form

    Can someone tell me how I access a variable outside from the form it was declared in? I've tried examples but they haven't worked.

    There are many right ways and many wrong ways to do what you want, the two below (one code example) and one link to a demo project are but two ways to do this.
    A simple example, form1 as two buttons, form2, two buttons, one text box. This replies on knowing the parent form.
    Public Class Form1
    Public SomeVar As String = "Karen"
    Public Property SomeProp As Integer = 4
    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
    Dim f As New Form2 With {.Owner = Me}
    Try
    f.ShowDialog()
    Finally
    f.Dispose()
    End Try
    End Sub
    Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
    MessageBox.Show(Me.SomeVar)
    End Sub
    End Class
    Form2
    Public Class Form2
    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
    Dim MyParent As Form1 = CType(Me.Owner, Form1)
    MessageBox.Show(MyParent.SomeProp.ToString & Environment.NewLine & MyParent.SomeVar)
    End Sub
    Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
    Dim MyParent As Form1 = CType(Me.Owner, Form1)
    MyParent.SomeVar = Me.TextBox1.Text
    End Sub
    End Class
    The following link has a project which is much more involved, I allow non-modal forms to pass data between the two in real time and both forms stick to each other.
    https://onedrive.live.com/redir?resid=a3d5a9a9a28080d1!727&authkey=!AEQ4n6P1H4sD6QI&ithint=file%2czip
    Please remember to mark the replies as answers if they help and unmark them if they provide no help, this will help others who are looking for solutions to the same or similar problem.

  • Accessing SPML Object class variable on SUN IDM Form or workflow

    Hi All,
    Can anyone suggest me how we can access the SPML variable on SUN IDM Form and workflow?
    e.g
    I have object class deffination in SPML configuration with schema deffination as below
    <Configuration name='SPML'>
    <Extension>
    <Object> <Attribute name='classes'>
    <List>
    <Object name='person'>
    <Attribute name='type' value='User'/>
    <Attribute name='form' value='SPMLPerson'/>
    <Attribute name='default' value='true'/>
    <Attribute name='identifier' value='uid'/>
    </Object>
    </List>
    </Attribute>
    <Attribute name='schemas'>
    <List>
    <String>
    <![CDATA[
                       <schema xmlns="urn:oasis:names:tc:SPML:1:0"
                      ...SPML standard schema...
                      </schema>
                       ]]>
    </String>
    <String>
    <![CDATA[
                       <schema xmlns="urn:oasis:names:tc:SPML:1:0"
                       ...Waveset custom schema...
                       </schema>
                       ]]>
    </String>
    </List>
    </Attribute>
    </Object>
    </Extension>
    </Configuration>
    Where I deffine my custom schema with all attributes that I want to view on SUN IDM custom form.
    I am able to set value from ModifyRequest for the variable but not able to get it on the Form or workflow.
    I did try with below expression to get the variable but no luck.
    <ref>attribute_name</ref>
    <ref>SPML.attribute_name</ref>
    <ref>SPML.Object_name.attribute_name</ref>
    Please suggest how we can access the variable?
    Any information will be appricated.
    Regards,
    vinash

    Hi All,
    Can anyone suggest me how we can access the SPML variable on SUN IDM Form and workflow?
    e.g
    I have object class deffination in SPML configuration with schema deffination as below
    <Configuration name='SPML'>
    <Extension>
    <Object> <Attribute name='classes'>
    <List>
    <Object name='person'>
    <Attribute name='type' value='User'/>
    <Attribute name='form' value='SPMLPerson'/>
    <Attribute name='default' value='true'/>
    <Attribute name='identifier' value='uid'/>
    </Object>
    </List>
    </Attribute>
    <Attribute name='schemas'>
    <List>
    <String>
    <![CDATA[
                       <schema xmlns="urn:oasis:names:tc:SPML:1:0"
                      ...SPML standard schema...
                      </schema>
                       ]]>
    </String>
    <String>
    <![CDATA[
                       <schema xmlns="urn:oasis:names:tc:SPML:1:0"
                       ...Waveset custom schema...
                       </schema>
                       ]]>
    </String>
    </List>
    </Attribute>
    </Object>
    </Extension>
    </Configuration>
    Where I deffine my custom schema with all attributes that I want to view on SUN IDM custom form.
    I am able to set value from ModifyRequest for the variable but not able to get it on the Form or workflow.
    I did try with below expression to get the variable but no luck.
    <ref>attribute_name</ref>
    <ref>SPML.attribute_name</ref>
    <ref>SPML.Object_name.attribute_name</ref>
    Please suggest how we can access the variable?
    Any information will be appricated.
    Regards,
    vinash

  • Set  variable with property userName of the user

    I'm working with 11g
    I have a initiator human task with the "author" variable ( and the corrisponding form have a string box "Author")
    I must define the default value with the userName ( the name of the user that start a process instance )
    I posted a script task before the initiator human task, but I do not know what value to assign.
    Can I recover this value from the realm? how?
    Thanks
    Elena

    I resolve in this mode
    I have used script box before human task box and I have set the variable in ora:getCreator().
    Elena

  • Set maximum size in Text Form Field Options for a field in bi publisher RTF

    Hi All,
    How to set maximum size in Text Form Field Options for a field in bi publisher RTF.
    I have a RTF whch is having a field in that i need to add some validation condition but after adding certain condition in Add help text tab ,it is not accepting after certain length, how i can increase the length to unlimited,please help me on this
    Thnaks

    Form fields have some restrictions if your are using version lower than 11g.
    They can accommodate only 393 chars. You can add the text in both status bar and help key, which can in total consume 393 chars.
    If your code logic is more than that, it can be split into multiple form fields as Avinash suggested or you can use sub template logic and handle coding over there. Again in sub template code can be within/outside form fields.
    So there is no option for user to increase the size of form field.

  • Using Spry Data Set Variable in Recordset

    I have a page that contains a spry data set and a recordset. The recordset uses one of the variables from the spry data set to filter its results. how do I apply the spry data set variable to the recordset?

    I believe passing this the variable through the URL requires you to update the page, right?
    Yes
    Is there anyway to grab the spry data set variable direct and apply it to your recordset filter?
    The SpryDataSet variable can only be used on the clientside (JavaScript) so you will have to get your recordset using JS.
    A page refresh can be set in motion if you add {useCache: false, loadInterval: 500} to your dataset to then set an observer to your dataset to invoke the page refreash function.
    Gramps

  • Access a variable in the Adobe form for Java Scripting

    Hi,
    I am unable to know how to access the variable in a Adobe form.
    The variable is field of an internal table. My adobe form structure is as follows
    MAIN_PAGE->FORMSET->FirstFORM->EXT.
    in the EXT subform the variable(cust)  exists.
    The cust is in turn an internal table.

    Hello Sreelatha,
    I think we cannot hide a page.  as in, page is the main container.  In a container, we can hide any field using some scripting.  Even though if we hide the field, it is present on page but not visible. 
    but if some logic is there, please let me know.
    Thanks,
    Rakesh.
    Edited by: rakhi966 on Sep 8, 2011 8:54 PM

  • OBIEE 10g - Can I use logical SQL to set variable?

    I am trying to set value of a session variable in the Advanced tab Prefix box of a request.
    Assigment of absolute value like this is working good:
    SET VARIABLE MYVAR=1;
    Can I set the variable using logical SQL? Something like:
    SET VARIABLE MYVAR = (SELECT table1.col1 from catname where table1.col2=1)
    Thanks in advance.

    Hi,
    You can create a session variable or dynamic variable in the RPD and try using it in here at the Advanced Tab prefix.
    But still check yourself if you need multiple values returning in the SQL statement.
    Hope this is helpful/ useful.
    Regards
    MuRam

  • Disable Parent Form while invoking Child Form using FND_FUNCTION.EXECUTE

    Hi,
    Any inputs in getting this issue resolved would be really helpful? I have a parent form wherein I am calling Child form (Line Details Form) by passing the masterid it works fine. Here How do we refrain the user control to access master form when child form is opened? Here when child form is invoked by click of a button and try to close the master, still I could see the child form opened. Any help will he highly appreciated. Many Thanks.
    Please find the details of the db version and function being used to invoke the form. I tried with all parameter options, when we give Open_flag as 'N', the master form gets closed after opening the child form. Perhaps given the open_flag as 'Y'. Kindly let me know your inputs in case of any missout from my end.
    Forms Version: Oracle Forms 10g
    Version: Oracle Applications : 12.1.3
    Database Version: 11.1.0.7.0
    fnd_function.execute(
    FUNCTION_NAME=> 'CHILD_FORM_LINE_DETAIL'                                                   ,OPEN_FLAG=>'Y'
         ,SESSION_FLAG=>'Y'
         ,other_params=>:Global.master_table_ID
    Thanks,
    Ahmed

    Hi,
    Please review the following documents and see if it helps.
    Note: 93784.1 - Custom Form is Not Executed When Called Using FND_FUNCTION.EXECUTE
    Note: 1031970.6 - Where is FND_FUNCTIONS.EXECUTE defined?
    Note: 744065.1 - Sample CUSTOM Library Code To Customize Applications
    Regards,
    Hussein

  • Need help with Different approaches to setting variables in a Flash movie in Adobe Flash CS3 Professional Version

    Hi,
    I'm using Adobe Flash CS3 Professional version of Flash
    software,
    I need help and guidance on
    Different approaches to setting variables in a Flash movie,
    what I should do in the fla file, and in the html file.
    Thanks, Gil

    Hi petro_jemes,
    Just a little claritification, you need to add the value to the variable "[string]$ou", and also change the language in the variable "$emailbody" in the function "Get-ADUserPasswordExpirationDate".
    I hope this helps.

Maybe you are looking for

  • Improving Oracle9i DB performance using IMPORT/EXPORT

    Hi, I'm experiencing wrong performance on Oracle9.2.0.6 DB for production system. I have one schema and two tablespaces: the first one for data (18 datafiles sized each 1GB), and the second one for indexes (15 datafiles sized each 1GB). I tryed to tu

  • Help with untagged traffic VLAN, Cisco 2960

    I guess I am getting old because I just can't seem to make this work once I start configuring the VLAN. I've attached a JPG of the scenario of the network model I am trying to deploy, but I have simplified it to the most basic model possible. I have

  • WHEN - VALIDATE IN ADF.

    hi jdev experts, am using jdev 11.1.1.5.0 - adfbc - oracle db10g and also i worked in Oracle forms 10g. there is some thing like when-validate-item. eg: in for oracle forms 10g take 2 fields (emp_id,emp_decription) here emp_id as lov. in when validat

  • Loadbalancing ldaps on ACE module

    Is it possible to configure loadbalancing of ldaps with end-to-end mode (encryption from end to end) on ACE module ? And if yes, do i have to use a special script for health checking ?

  • HT1296 how do I delete a camera roll of my ipad

    I have an the newest Ipad first apple product I have owned Ihave a pc how do you delete a camera roll off the ipad and how do you put pictures from my pc to my ipad it will only let me chose all folder when i'm connected to my pc and Itunes is open p