Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3229470
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T16:48:52+00:00 2026-05-17T16:48:52+00:00

I am not sure if I am missing something, but for the life of

  • 0

I am not sure if I am missing something, but for the life of me I cannot get the grid to be editable.

All I am doing is loading a file to a Dictionary, then binding that Dictionary to the grid.

The grid displays the data in the Dictionary, but I cant edit any data in the grid.

I tried changing the modes also:

  1. EditOnEnter
  2. EditOnKeyStroke

And Nada.

Any ideas? PS: I have not done much GUI work in C++, so maybe I am overlooking something.

Here is how I load the grid.

Dictionary<String^, String^>^ data = gcnew Dictionary<String^, String^>();
BindingSource^ bindingSource1 = gcnew BindingSource();

// Read and display lines from the file until the end of the file is reached.
while ( line = sr->ReadLine() )
{
  array<String^>^split = line->Split( chars );    
  data->Add(split[0], split[1]);
}


dataGridView1->DataSource = bindingSource1;
bindingSource1->DataSource = data;

dataGridView1->AutoResizeColumns( DataGridViewAutoSizeColumnsMode::AllCells);

Thank in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T16:48:52+00:00Added an answer on May 17, 2026 at 4:48 pm

    I found the problem. You have to use an update-able source and a Dictionary is not update-able.

    Once I changed to a DataTablew, problem solved.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Maybe im missing something but im not sure. All im simply trying to do
I must be missing something obvious but I'm not sure what. I've created a
I'm not sure if I'm missing something really obvious, but I keep getting a
I have to be missing something simple, but I'm really not sure what. I
OK, I am missing something fundamental here I am sure! But for the life
I'm not sure if I'm totally missing something here but I can't find any
I'm sure I'm missing something pretty basic, but I have just started to get
I'm not sure if I am completely mad or missing something but I am
I a missing something here but I am not sure what is that. So
I am missing something obvious, but I'm not sure what. I have a single

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.