How to delete a selected line using a button located outside the datagrid in flex4 mxml application

Hi friends,

I'm new to flex, I use flex4 mxml application, I have my doubts... Help, please.

My requirement is that I use a grid.i of data data should this datagrid from another window contextual and recorded the details datagrid now, too, I want to remove a record from a data grid

I use a datagrid. a save button and remove the two buttons are placed outside the grid of data. so once I click on a row of the data grid and click on remove the medium button this record should delete data grid.


All codes suggession and extract are welcome.

Thanks in advance,

B.Venkatesan

Hello

This code can help you:

http://www.Adobe.com/2006/mxml"layout ="absolute"viewSourceURL =" srcview/index.html">"

Import mx.controls.CheckBox;

Import mx.collections.ArrayCollection;

Import mx.controls.Alert;

public var dp:ArrayCollection = new ArrayCollection();

public void addRow (): void

{

var tmp:Object = new Object();

tmp ["amount"] = 100;

dp.addItem (tmp);

}

public function delRow (): void

{

If (dgFee.selectedIndex! = - 1).

dp.removeItemAt (dgFee.selectedIndex);

}

]]>

Thank you and best regards,

-----------------------------------------------------------------------------------------

Vibhuti Gosavi . [email protected] | www.infocepts.com

-----------------------------------------------------------------------------------------

Tags: Flex

Similar Questions

  • How to create table selectable line or not based on the value of the line

    Hello.

    JDeveloper 11.1.1.2

    Is it possible to make a selectable table row or not based on a value in the line.

    That is to say. lets say that the row contains a Boolean LOCKED = TRUE.
    This line should not be selectable.

    A line whose value LOCKED = FALSE should be selectable.

    / Erik

    Erik,

    No particular reason to disable a selection of lines for a particular line? If I'm an end user, I would be clicking on the same line of thought again and again my mouse does not ;) (call me dumb :)). How do you differentiate this line (using inlineStyle / styleClass) based on the value of line? In addition, you can disable the other buttons when a row with a particular value is selected (so that the user knows that the selected line is not treatable).

    Arun-

  • How to clear a selected line of the datagrid control in flex 4

    Hi friends,

    I have a datagrid and a button, delete once I've selected a line of datagrid, then click on Remove button medium it should remove the data grid.

    How to do this.please help.

    No matter what welcome suggession

    Thanks in advance,

    Vegas

    Hello

    For that you call the same function on click of a button. This button is outside your datagrid control.

    public void deleteItem(event:MouseEvent):void {}
    dgArrayCollection.removeItemAt (dg.selectedIndex);
    dgArrayCollection.refresh ();
    }

    Thank you and best regards,

    ---------------------------------------------------------------------- -----------------------------

    Kanchan Ladwani | [email protected] | www.infocepts.com

    ---------------------------------------------------------------------- -----------------------------

  • After dragging table how can we single selection line enabled?

    Hello world

    I dragged a single table and created two buttons. Now I need the table to be selected (while dragging I don't check this value)
    After dragging table how can we single selection line enabled?

    Thank you.

    Hi Kumar,

    Add this attribute to the af: table:

    rowSelection="single"
    

    AP

  • How to make a selected line in the table of the adf

    Hello
    I add a new line to my table as below.

    BindingContainer DCBindingContainer =
    (DCBindingContainer) ADFUtil.evaluateEL("#{bindings}");
    DCIteratorBinding iter = bindingContainer.findIteratorBinding("IfwSystemBrandView1Iterator");
    ViewObject vo = iter.getViewObject ();
    line = vo.createRow ();
    row.setNewRowState (Row.STATUS_INITIALIZED);
    vo.insertRow (row);

    This code adds a newline at the end of the table.
    I want this new line to select once it gets added.
    How to get there?

    Thank you
    Praveen

    So that the new row to select, you need to add the key to the new line created in the SelectedRowKeys of the table.
    (1) create a link to the table named "table".
    (2) after the insertion of the new line, add the following code:

    Key to the new line should be added to the key defined for the selected table row to be selected.
    table.getSelectedRowKeys () .add (row.getKey ());

    Thank you
    Nini

  • How to delete songs to mp3 using windows mediam player

    How to remove data on mp3 using vista - Media Player. There should be a way

    Try the following:

    http://www.ehow.com/how_4523725_delete-songs-from-MP3-player.html

  • How to use a button to fire the stored procedure or anonymous block PLSQL

    I am converting an application forms at the APEX, and which was easy became almost unbelievably difficult. I have a page that represents a record with an element called "history_rec". It is an element of the checkbox. Clicking on it causes the column for this record to be filled with the letter 'H', indicating that this recording is now historical and not assets. I also have this page a button that says "Renew Record." This button redirects to the current page and sets the value of 5 elements of the page on the values of the record being replaced with the new record.

    (This, incidentally, is an insurance system of follow-up to the loan guarantees. The insurance must be renewed annually, and this system is used to ensure that it is.)

    I also want the button to trigger a process that updates the old record by filling in the history_rec column. To do this, I created a process called "make_history" that contains the following SQL code:

    "Ensure the update
    Set history_rec = "H".
    "where insureseq =: P22_INSURESEQ.

    I chose for the 'process' Point ' on demand: run this process when requested by AJAX. "

    Is it possible my button 'Renew the Record' and if so, how? If this is not the case, how should I proceed?

    Doug,

    I'm glad you've made any progress.

    What process throws the error, it is the last process?

    "Error Unable to fetch row ' with this code ORA" ORA-01403: no data found. "

    Is page 21 page that you develop?

    I want to make is that demand for return on page 21

    What you already have for the branches Page?

    Jeff

  • Can I use "home" button to let the phone alarm clock

    I have lenovo vibe s1, I ask can I use multitasking button or the "home" button to let phone-wake up while the screen locked instead of the button On / Off?

    No, I don't think you can do this on the phones of Lenovo. Some phones (used to) support double tap, but not all and it did never work very regularly. On some phones of Lenovo, you can use the home button to light a torch after long press. I think you neeed to wake the phone to screen lock however.

  • How to open several screen together in 10 Blackberry like on the page on my current application

    Hi all

    I am currently the application design in which there is a button action as assistance or to this date.

    When I click that button, I did the implementation such that he calls an other html.

    With the help of bb.pushScreen

    When I came back from About.html it will load the previous (main.html)

    but in this way the setting values and current variables are lost in main.html.

    There are many apps that do as they can slip on the dialog box as see main application together.

    Is it sort of wrong to broadcast any dialogue on Main.html main.html still works when I close any dialogue.

    Please help me!

    Thank you

    GBA

    I think I understand 2 questions in what you describe.

    1. you have the data loaded into your default main.html page and if it is changed by the user, it is not present when it is reloaded? You can get around this by having a global data or using localStorage object. In the function onscreenready in the index, you can update the values of your fields of data using the data in your global object or variable localStorage. If you look at page options of the sensors sample, you will see an example to have a screen to update objects screen with values of global data loading. https://github.com/BlackBerry/BB10-WebWorks-samples/tree/master/sensors

    2. you want to implement the gesture of glance in your application, so that you can slide the screen to the right and see a bottom at the same time. This feature is not included in the current bbUI.js. You can try to add in there, but we don't have any samples for her.

  • When you use a button to send the PDF PDF form can be divided into two?

    Hello

    I have a PDF form which consists of two pages - the second help autofilled data from boxes filled with page 1.

    I asked when the form is completed and the user presses the button submit, if the PDF file can be contacted only two files then page 1 and 2 of each its own PDF by email, but for the same recipient?

    Except that they use Adobe Acrobat in order to transmit the file, more.

  • How to deletions has selected list item from a list item.

    How delete a list item selected in a list item.

    My question that I should write to list_index so that it indicates the selected list item

    DELETE_LIST_ELEMENT (Nom_liste, list_index);

    -----
    Form of Oracle 10g

    Hello

    The trigger when-list-changed fires whenever the value has been changed.
    You get this value/index with the following:

    DECLARE
       LC$Liste  Varchar2(61) := :system.cursor_item ;
       LC$Valeur Varchar2(30) := Name_In( LC$Liste ) ;
       LN$Nbre   Pls_integer ;
    BEGIN
    
       LN$Nbre := Get_List_Element_Count( LC$Liste ) ;
    
       For i IN 1 .. LN$Nbre Loop
          If Get_List_Element_Value( LC$Liste, i ) = LC$Valeur Then
             -- you get the selected value, and index there --
             :BLOC2.LABEL := Get_List_Element_Label( LC$Liste, i ) ;
             Exit ;
          End if ;
       End loop ;
    
    END;
    

    François

  • How to pull information from a text field in my email subject line using a button to send email?

    I know how to create a button to e-mail with the static object, but I need to pull on the name field in the subject line.

    I use LiveCycle Designer ES2 v. 9.0 on a Windows computer.

    Example: Change request for < text field of the form >

    Not in the XML file, in the Click event of the button.

    You will find the scripteditor on the 'window '. "scripteditor.

    There you can change the event right next to 'show '.

  • How to delete saved selections?

    I have a CS3/CS4 compatible PSD file that includes more than a dozen selections recorded. When I use the load selection menu item, the dropdown selection menu I saved there.

    There are several recorded selections is no longer, I need this file.

    Is it possible to remove or modify them in any way?

    Have you tried using the control panel layers?

  • How to achieve 360 degree display using arctangent of structure of the case?

    I have the sine and cosine signals. The tangent and arctangent are used to get the - 90 to 90 degrees. To achieve the 360 degree screen, I will use the absolute value and an additional degree, such as 90 180 and 270. I created the case and select parts, but I don't know how to link these two. Help, please!

    Thank you!

    Focus on the atan2 function.  This takes X and Y entry and you give the angle between - pi and pi.

    -Darin

  • How to enable microphone AND line-in audio to record at the same time?

    At the present time, then I plug the microphone, line triggers.
    How to mix the two?

    It depends on your hardware chipset and driver of the company that built your audio system.  Really, we need to know precisely what audio card/driver type and the name of the template that you use to tell you what capabilities it has (assuming that this information is available from the manufacturer).

Maybe you are looking for