How to search datagidView and Display result in another datagridView using VB 2010?

knowdarian

Member
Joined
Apr 9, 2012
Messages
6
Programming Experience
Beginner
Hi,
I am extracting datas from the table to display in datagridview1 as shown in image1.
Now I want to search the datagridview1 and display the result in datagridview2 as shown image2.
Please do refer the attached images.
I am using Visual basic 2010 for this.
Can anybody Plz help me out in solving this?
image1.pngimage2.jpg
 
What are the rules for selecting the records to be displayed in the second form? Does the user select rows individually? Is there some sort of search based on criteria? Something else?
 
Re: How to search datagidView and Display result in another datagridView using VB2010

Hi,

Thanks for responding...the second form will be consisting of one datagridview and one button. when the user clicks the button,the first datagridview1 from the form1 is to be searched. It should first search for the identical names. e.g. if 'aleksander' name is 2 times in the names column and if the sports he is interested are football and car racing then aleksander must be displayed once and the sports he is interested must be displayed - i.e. football in next to the names column and car racing to the next column. To be more precise i am attaching the image below again.

image1.png

image2.jpg

Your reply would be much precious...............


What are the rules for selecting the records to be displayed in the second form? Does the user select rows individually? Is there some sort of search based on criteria? Something else?
 
Last edited:
Re: How to search datagidView and Display result in another datagridView using VB2010

Any Updates on this interesting output solution.. Please help me on this...
 
First up, please don't create multiple threads for the same topic. I have deleted your duplicate thread.

What you're trying to do is called a "pivot" query, where you map multiple rows in the data to multiple columns in the result set. With that keyword you should be able to search the web and find information on how to perform it.
 
Hi,
Thanks for replying...Can you please help me with the code. As I am a student I am completely new to the programming. So please help me with the code.


First up, please don't create multiple threads for the same topic. I have deleted your duplicate thread.

What you're trying to do is called a "pivot" query, where you map multiple rows in the data to multiple columns in the result set. With that keyword you should be able to search the web and find information on how to perform it.

How can I use pivot query to search it from datagridview1 and display in datagridview2....Please....
Your reply would be much precious.
 
Being new to programming does not mean that you are unable to search the web, read what you find and then try to make use of it. After you've done that, if you're still having trouble then I would be happy to take a look at what you've done and help you try to fix it.
 
Back
Top