Results 1 to 4 of 4

Thread: [RESOLVED] Datagrid Row/Column Location

  1. #1

    Thread Starter
    Addicted Member Tengkorak's Avatar
    Join Date
    Nov 2006
    Posts
    240

    Resolved [RESOLVED] Datagrid Row/Column Location

    How to move in a datagrid object. which of the column 1 and row 1 I want to move to the row 1 and column 3.
    whether this can be done on the datagrid.


    Thank you

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: Datagrid Row/Column Location

    First up, as you're using VB 2010 I would suspect that you are doing one of the following:

    1. Using WinForms and using a DataGridView rather than a DataGrid.
    2. Using WinForms and actually using a DataGrid, in which case you should switch to a DataGridView.
    3. Not using WinForms.

    If you are using a DataGridView then please use the correct terminology. If you are not using WinForms then please post in the proper forum (ASP.NET, WPF, Silverlight) or at least let us know exactly what technology you're using. Otherwise, you either cause confusion or require us to make assumptions that could easily be wrong.

    As for the question, what do you actually mean? Are you saying that you want to focus a specific cell? Copy a value from one cell to another? Something else?
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3

    Thread Starter
    Addicted Member Tengkorak's Avatar
    Join Date
    Nov 2006
    Posts
    240

    Re: Datagrid Row/Column Location

    i use DatagridView Control, this for Desktop App.
    yes, i want to focus a specific cell. but i don't know how to do.

  4. #4
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: Datagrid Row/Column Location

    You get the desired cell by whatever means are appropriate, e.g. the Item property of the grid, and then you assign that to the CurrentCell property.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width