Click here to Skip to main content
15,886,026 members
Please Sign up or sign in to vote.
1.00/5 (3 votes)
See more:
i have tried using datasource method but gives me login failed message.
Posted
Comments
Sergey Alexandrovich Kryukov 2-Sep-14 2:35am    
Datasource works perfectly, as well as insert, update and other operations on unbound DataGridView. If you screwed up something, it does not mean that we can know how, from your post. Your post is totally not informative. This is the same as asking "I cannot start my car's engine. How to fix it?"
—SA
Thanks7872 2-Sep-14 2:39am    
In addition to that, i would say this is not the correct use of DataGridView at all.
Sergey Alexandrovich Kryukov 2-Sep-14 2:43am    
I would not be so sure. We just know nothing about OP's use. (And if, by any chance, you think that unbound use is wrong, I can show you enough cases when this is the only reasonable way to use DataGridView. :-)
—SA
Thanks7872 2-Sep-14 2:45am    
I agree with you, but it should be the last option when nothing works.
Sergey Alexandrovich Kryukov 2-Sep-14 2:51am    
No, no. There are just very different things, when there is no a database of other standard-looking data source, nothing. Of database model is not relational. I have one such project, where database schema is based on Meta2Data and hence virtual metadata (schema) can be changed during runtime from the DataGridView (columns (part of schema, database attribute) dynamically added, removed). Yes, this is so exotic thing that not many can understand it, but this is a very interesting (and simple) concept which required unbound use.

Besides, you can use DataGridView just as a convenient container for input control (due to specific structure of input data). What would you bind there? And this is quite a legitimate example.

This is not because "nothing else works", but because unbound use is apparently right thing in first place.

Your statements are based on some quite standard setting of some pretty typical applications. Not all applications should be typical...

—SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900