Data Grid Selection problem

Hi All,
When I use Action Script to create DataGrid, the selection
line cannot be changed in mouse click event. But the
dg.selectedIndex has be changed correct row, only the selection
line is no change.
My sample code as follow:
var dg:DataGrid = new DataGrid()
dg.selectable = true;
var cols:Array = new Array();
var col1:DataGridColumn = new DataGridColumn();
col1.dataField = "col1";
var col2:DataGridColumn = new DataGridColumn();
col2.dataField = "col2";
cols.push(col1);
cols.push(col2);
dg.columns = cols;
var row1:Object = new Object();
var row2:Object = new Object();
var row3:Object = new Object();
var row4:Object = new Object();
var rows:Array = new Array();
rows.push(row1);
rows.push(row2);
rows.push(row3);
rows.push(row4);
dg.dataProvider = rows;
The selection line always hold on last row, how to solve it
let the selection line can follow the selectedIndex to change?
Thanks

The function code is: &F03
alternativley I already tried BACK with the same result.
Where shall I put the LEAVE TO SCREEN 0 when it's using the standard PAI Module which is NOT included within my Report?

Similar Messages

  • Data-grid population problems

    Hi,
    I am having a little problem that is driving me mad . When trying to fill my data-grid noting happens . No error or noting . The only thing i can see is when i run the application a red x is put on my database in the server explorer and when i refresh it
    it will return to normal. 
    Any help would be appreciated.
    Thanks.
    private void btnSearch_Click(object sender, EventArgs e)
    searchAll();
    public void searchAll()
    OleDbConnection conToDataBase = new OleDbConnection(@"Provider=Microsoft.ACE.OLEDB.12.0;Data Source=|DataDirectory|\Resources\health_plus.accdb;Persist Security Info=True");
    OleDbCommand searchAllCom = new OleDbCommand("SELECT * FROM Doctors", conToDataBase);
    conToDataBase.Open();
    searchAllCom.CommandType = CommandType.Text;
    OleDbDataAdapter searchDocAdapter = new OleDbDataAdapter(searchAllCom);
    DataTable doctorsTable = new DataTable();
    searchDocAdapter.Fill(doctorsTable);
    searchDoctorDataGrid.DataSource = doctorsTable;

    Hi Ali-k,
    First you need to make sure the data is in your Access DataBase.
    Then If you have binded the DataSource before searchAll method, you could clear the DataSource before resetting it like below.
    searchDocAdapter.Fill(doctorsTable);
    searchDoctorDataGrid.DataSource = null;
    searchDoctorDataGrid.DataSource = doctorsTable;
    If you have any other concern regarding this issue, please feel free to let me know.
    Best regards,
    Youjun Tang
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Data type selection Problem in ztable to use in the Module Pool Program

    Dear Experts,
    I have created a z-table which is used in Module Pool Program in which i have to save the information saved by the endusers in z-table. But the problem comming is that the amount of information saved by the endusers is so havey & our table is just limited for the 50 characters which is not sufficiet. So I urge you to please tell me what & which type of data type should I have to use to store maximum amount of information in our zt-able which is available in SAP ECC6.0.
    Thanks & Regards,
    Akg

    Dear Akg,
    u can resolve ur problem in following ways,
    1. You can declare the field in a table without an Data element.
          i.e. In the length field . using F4 help in length field how many characters u want u enter.
    2. In the same u can search for an standard data element and use the same.
    3. Creating an custom data element .
    Reward if helps to u!!!
    Regards,
    MNR

  • How to create PDF from data grid selected row records and save in local PC

    ok now i am need another help ;
    i am having one datagrid and one button outside the grid ,
    i   am having one datagrid in that i am having 5 records if i click a   record from the datagrid then click that button means that particular   record will save as PDF in my local PC.
    How to do that,
    Any suggession or examples.
    Thanks in advance
    B.venkatesan.

    <cfdocument>
    Usage is described in the cfml reference manual.  If you don't have one, the internet does.

  • Bug in 1.5.1 Deleting number value in data grid

    Hello,
    it is not possible to set a number in a column to NULL by simply deleting the value
    DROP TABLE tab_test;
    CREATE TABLE tab_test(
    dat DATE
    ,num NUMBER
    ,var VARCHAR2(2)
    INSERT INTO tab_test (dat,num,var)
    VALUES (TO_DATE('01.01.2009','dd.mm.yyyy'),4,'ff');
    COMMIT;Open the table in SQL Developer and select data tab.
    Deleting the date value and commiting is ok
    UPDATE "RVS_FE"."TAB_TEST" SET DAT = TO_DATE('', 'DD.MM.YYYY') WHERE ROWID = 'AAA6Q0AAGAABHUlAAA' AND ORA_ROWSCN = '10443975276'
    Commit Successful
    Deleting the number value and commiting raises an error
    UPDATE "RVS_FE"."TAB_TEST" SET NUM =  WHERE ROWID = 'AAA6Q0AAGAABHUlAAA' AND ORA_ROWSCN = '10443975285'
    One error saving changes to table "RVS_FE"."TAB_TEST":
    Row 1: ORA-00932: inconsistent datatypes: expected NUMBER got DATE
    Rollback Successful
    Deleting the char value and commiting is ok
    UPDATE "RVS_FE"."TAB_TEST" SET VAR =  WHERE ROWID = 'AAA6Q0AAGAABHUlAAA' AND ORA_ROWSCN = '10443975285'
    Commit Successful
    Regards
    Marcus
    Edited by: Marwim on 26.11.2008 08:59

    Jim, I could reproduce and see the error, no change columns order.
    You can use the Marwim script's and, on the data grid, select the column DATE, delete value and commit.
    On the data grid, select the column var, delete value and commit.
    On the data grid, select the column num, delete value and commit -> get error.

  • Problem rendering a combo box in the data grid

    Hi,
    I am rendering a combo box in the data grid control using an
    item renderer. When I click on it to select a value from the drop
    down, the combo box immediately closes giving no time to even click
    on the dropdown. This doesn’t happen every time the combo is
    clicked, although it happens frequently. What I think is that the
    problem arises because the data grid tries to refresh the renderers
    and during this process, the existing combo is removed, thereby
    getting closed automatically. Please let me know of a work around.
    Thanks,
    Cheree

    hi hiwa,
    i have to add combo box in datagrid dynamically.
    it should append as and when i add the data in the above text boxes.
    thanks in advance.

  • Problem in Data Grid

    Hi All,
    Account calculations are not displaying on the data grid. But the values are being picked up with a smart view report.
    I tried running a force calculate and a consolidate all, but that did not work.
    Please suggest in this regards.
    Thanks in advance....

    I tried to use your algorithm to modify my code but i am not able to do that. For this example i am not using any httpservice i am  using data services. I created a PHP file i just need to import it into data services planel and drag that services onto data grid it will automatically bring all the data into that data grid.  Can you tell me what i need to modify to achive my goal. am using following code
    protected function dataGrid_creationCompleteHandler(event:FlexEvent):void
    getHorizontalCommentResult.token = horizontalCommentsService.getHorizontalComment();
    <mx:DataGrid x="159" y="123" id="dataGrid" creationComplete="dataGrid_creationCompleteHandler(event)" dataProvider="{getHorizontalCommentResult.lastResult}" height="223" width="245">
    <mx:columns>
    <mx:DataGridColumn headerText="Comments" dataField="Comments"/>
    </mx:columns>
    PP file
    <?php
    class HorizontalCommentsService{
    public function getHorizontalComment() {
    $connection = mysqli_connect("localhost", "root", "root", "my_db", 8889) or die(mysqli_connect_error());
    $sql = "SELECT * FROM photo_comments ORDER BY Image_ID DESC";
    $result = mysqli_query($connection, $sql) or die('Query Failed: ' . mysql_error($connection));
    $rows = array();
    while($row = mysqli_fetch_object($result)) {
    $rows[ ] = $row;
    return $rows;
    ?>

  • Select various entire lines in data grid doesn't work

    SQL Dev 2.1.1.64 on WinXP.
    I can select entire line in data grid (or query result) by clicking on leftmost column with row number. I expect to select various lines by clicking and dragging, but it won't work. It worked in v1.5.
    Thanks,
    MVr.

    Still 3 other ways that I see:
    * click on the row number of the first row, then shift-click on the row number of the last row
    * click on the first cell of the first row, then drag to the last cell of the last row
    * click on the row number of the second row, then click on the first cell of the first row and drag to the last row (most like what you want)
    Have fun,
    K.

  • Advanced Data Grid - Multi-Select

    Good Day,
    I am using an Advanced Data Grid to display data to the user.  The user needs to be able to select multiple rows, and not necessarily in order.  This is all fine, however, they don't want to have to hold the CTRL or SHIFT keys when selecting, and would like the mouse to act as a select/deselect for the row.
    I know that I will have to extend the ADG class to handle this, but I was hoping that someone else may have done this, or has some guidance.  I have never extended a class before, so I am not sure what all steps i will need to take.
    Thanks!
    Rob

    sortExpertMode property
    public var sortExpertMode:Boolean
    By default, the sortExpertMode property is set to false,
    which means you click in the header area of a column to sort the
    rows of the AdvancedDataGrid control by that column. You then click
    in the multiple column sort area of the header to sort by
    additional columns. If you set the sortExpertMode property to true,
    you use the Control key to select every column after the first
    column to perform sort.
    The default value is false.
    So, this property simply changes HOW you do multi-column
    sorting.
    I submitted an enhancement request:
    http://bugs.adobe.com/jira/browse/FLEXDMV-1429

  • Flashing Problem in advance data grid

    I am using advancedatagrid and make 4 level tree based menu using bindable data priovider, Please see the screenshot
    I define own item render in each level of advance data grid in appliction, but i have flashing issue here, when i update the downloading percantage then image flickring in the list.
    Please give the best solution to avoid the flashing....
    Thanks
    Anees

    Hi,
    while preparing internal table to be passed to ALV, you have to implement the logic for these scenarios.
    Regards,
    Raghavendra

  • FillBy always fills in the same row in data grid view. How to make it fill in a new row for each click of the Fillby Button? VB 2010 EXPRESS?

    Hi there, 
    I am a beginner in Visual Basic Express 2010. I have a Point of Sale program that uses DataGridView to display records from an external microsoft access
    database using the fillby query. 
    It works, but it repopulates the same row each time, but i want to be able to display multiple records at the same time, a new row should be filled for
    each click of the fillby button. 
    also I want to be able to delete any records if the customer suddenly decides to not buy an item after it has already been entered. 
    so actually 2 questions here: 
    1. how to populate a new row for each click of the fillby button 
    2. how to delete records from data grid view after an item has been entered 
    Thanks 
    Vishwas

    Hello,
    The FillBy method loads data according to what the results are from the SELECT statement, so if there is one row then you get one row in the DataGridView, have two rows then two rows show up.
    Some examples
    Form load populates our dataset with all data as it was defined with a plain SELECT statement. Button1 loads via a query I created after the fact to filter on a column, the next button adds a new row to the existing data. When adding a new row it is appended
    to the current data displayed and the primary key is a negative value but the new key is shown after pressing the save button on the BindingNavigator or there are other ways to get the new key by manually adding the row to the backend table bypassing the Adapter.
    The following article with code shows this but does not address adapters.
    Conceptually speaking the code in the second code block shows how to get the new key
    Public Class Form1
    Private Sub StudentsBindingNavigatorSaveItem_Click(
    sender As Object, e As EventArgs) Handles StudentsBindingNavigatorSaveItem.Click
    Me.Validate()
    Me.StudentsBindingSource.EndEdit()
    Me.TableAdapterManager.UpdateAll(Me.MyDataSet)
    End Sub
    Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
    'TODO: This line of code loads data into the 'MyDataSet.Students' table. You can move, or remove it, as needed.
    Me.StudentsTableAdapter.Fill(Me.MyDataSet.Students)
    End Sub
    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
    Me.StudentsTableAdapter.FillBy(Me.MyDataSet.Students, ComboBox1.Text)
    End Sub
    Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
    Me.MyDataSet.Students.AddStudentsRow("Jane", "Adams", "Female")
    End Sub
    End Class
    Get new key taken from
    this article.
    Public Function AddNewRow(ByVal sender As Customer, ByRef Identfier As Integer) As Boolean
    Dim Success As Boolean = True
    Try
    Using cn As New OleDb.OleDbConnection With {.ConnectionString = Builder.ConnectionString}
    Using cmd As New OleDb.OleDbCommand With {.Connection = cn}
    cmd.CommandText = InsertStatement
    cmd.Parameters.AddWithValue("@CompanyName", sender.CompanyName)
    cmd.Parameters.AddWithValue("@ContactName", sender.ContactName)
    cmd.Parameters.AddWithValue("@ContactTitle", sender.ContactTitle)
    cn.Open()
    cmd.ExecuteNonQuery()
    cmd.CommandText = "Select @@Identity"
    Identfier = CInt(cmd.ExecuteScalar)
    End Using
    End Using
    Catch ex As Exception
    Success = False
    End Try
    Return Success
    End Function
    In closing I have not given you a solution but hopefully given you some stuff/logic to assist with this issue, if not perhaps I missed what you want conceptually speaking.
    Additional resources
    http://msdn.microsoft.com/en-us/library/fxsa23t6.aspx
    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.

  • Display image into Data Grid

    Hello,
    I have to display into a data grid, in Flex 2, 2 columns:
    first column ( "Images") must contain a picture with an object and
    second column (" quantity") must contain the amount of that object
    that I want to buy. The problem is that I must take the name of the
    image from an .xml file, specified like this:
    <mx:DataGrid id="obj" dataProvider="{ObjList}" > where
    ObjList is the .xml file with <name/>
    <picture_address/> etc.
    The second column must contain a textbox so I can input a
    number of items for each picture ( can be also a combobox where
    from I can select some value, from 1 to 20 for example).
    I've searched the Internet and I haven't found a solution
    yet. Please give me a link or a solution for this problem.
    Tudor

    use itemrenderes.... the example below shows how to add an
    image.... you can do the same thing with a text box or combo box
    <mx:DataGridColumn width="10" headerText="Image">
    <mx:itemRenderer>
    <mx:Component>
    <mx:Canvas width="100%" height="100%">
    <mx:Image verticalCenter="0" horizontalCenter="0"
    source="{data.picture_adress}""/>
    </mx:Canvas>
    </mx:Component>
    </mx:itemRenderer>

  • How do I take data from a data grid and put it into a variable?

    I am having problems taking data from a datagrid (guess you got that from the title) and setting it to a variable. I am tak
    ing the data from 3 different rss feeds, depending on what button you press, and showing it in a grid. I would like to be able to do more with this data. Here is my code so far:
    <mx:VBox id="vbox" x="70" y="150">
      <mx:Label text="This Data Grid is doing nothing" />
      <mx:DataGrid width="1000" dataProvider="{fullXML}">
       <mx:columns>
        <mx:DataGridColumn id="dataGrid" *dataField="channel.description" headerText="Feed"/>
       </mx:columns>
      </mx:DataGrid>
    </mx:VBox>
    <!-- from test 5 -->
    <mx:Move id="moved" target="{hbox}" repeatCount="0" easingFunction="mx.effects.easing.Linear.easeIn" />
    <mx:HBox id="hbox" fontSize="12" fontFamily="courier">
      <mx:Label text="{website**}" />
    </mx:HBox>
    * this is the data I want to get out
    ** this is where I want to be able to put the variable.
    I don't know if I can do it here or if I need a function or what.
    I would like to be able to put it into an array, but step one is anything at all, so I'm trying just a variable.

    Where do I put that line of code? I see that it goes at the Script part near the top, but how can I use that, I am pretty new to this language. I am not familiar with this line, where does it bind the value from the datagrid to the variable?
    fullXML[myDataGrid.selectedIndex].FIELD_NAME;
    myDataGrid would be the id from the grid I am guessing?
    and selected index would be the channel.description part?
    and FIELD_NAME; is the variable name?
    does this go into a funtion or is it placed at the top where the variables are declared?

  • Text in data grids doesn't display

    With the new 29 version of FireFox, data grids on our site don't seem to display the data in the grids any longer. When using Chrome or IE11, these still show just fine. Version 28 and earlier worked great. The menu system in our site doesn't work well any longer either using version 29.
    What we are seeing on this site was also seen with IE11 when it first came out but that was easily fixed by just using the "compatability" settings in IE11 and adding our site to the list of compatible sites. There isn't such a setting in FireFox so I wonder how we go about getting around this.

    Thanks for the offer but we no part of this site can be publicly accessed. The thought of a font causing the problem doesn't make much sense to me because it was working fine prior to version 29. Why would the font all of a sudden be causing the problem. Furthermore, it isn't just text in data grids but the menu system we use doesn't work properly either. You have to hold down on the left mouse button to use the menu and then when you are on the item you want to select, let off the left mouse button. Guess our only option is to start recommending Chrome or IE.

  • Sort on views in data grid (ORA-00904)

    Can anyone else confirm that this happens, or has been highlighted previously:
    1. Connect to any schema containing views
    2. Expand the views tree
    3. Click on any view
    4. Click on the data tab to display the data grid
    5. Click the sort button
    6. Select any column (must not exist in view selected later)
    7. Click "Apply Sort"
    8. Now click on any other view that does not contain a column of the same name as the one chosen as the sort column previously.
    I receive an ORA-00904 error. The only way I can clear this is to close down the data grid tab item, and re-open it.
    Cheers
    Carl
    DBA - Dunfermline Building Society

    Yes.
    Login as a DBA.
    Go to Other Users - SYS - Views - More - Filter - %% - OK
    Click on DBA_USERS - DATA - Sort - USERNAME - Apply Sort
    Click on DBA_USTATS
    --> ORA-00904 "USERNAME". invalid identifier.
    Notice that the columns in the data view have not changed.
    Close the tab and click on DBA_USTATS fixes the problem (no data anyway).
    Click on freeze view (the push pin) and click on DBA_USTATS fixes the problem.
    These are two easy workarounds, but it is confusing the first time you encounter it.

Maybe you are looking for

  • Determinação automatica de CFOP com e sem crédito em MM

    Olá pessoal, novamente recorro a vocês porque estou com uma dúvida que pode ser simples, mas não estou encontrando alternativas para o meu cliente. Configuramos 4 novos CFOP: 1556/AA e 1556/AC / 2352/AA E 2352/AC A questão é a configuração para deter

  • I have 2 sons that were sharing one account and now I want to separate them, will I run into any issues ?

    I have twin sons and my wife sharing one itunes account and now from what a relative told me I should split them up since face time from my sons itouch is showing up on my wife's iphone ... so I started a new itunes account for all 3 of them, and now

  • How to deactivate schedule line in sales order

    hi friends, how can i deactivate the schedule line in sales order so that we can deliver the sales order after the schedule date. i can uderstand that system is not allowing before schedule date. but what if i want to deliver after that. Thanks in ad

  • Finding Purchased TV Series

    I purchased The Sing Off Season 2 and I can't find where I download the rest of the season. When I go to Season 2 ITunes expects to pay again for the Season I already bought. Anyone know how to find the download I pre-paid for?

  • Again same problem???

    This program executes JTextField and JPasswordField.But the problem is I use Eclipse Platform and It shows error in line 43.The error is: class must implement the inherited abstract method ActionListener.actionPerformed(ActionEvent) But I've already