C# - Reading specific elements of an XML file into a dataGridView and display rest in textbox -


hi i'm faced problem i'd with. firstly have xml file here

    <data> <row>   <id>1</id>   <description>description 1</description>   <thedate>2013-06-12t00:00:00</thedate>   <somenotes>some notes1asdsadsadsad</somenotes> </row> <row>   <id>2</id>   <description>description 2</description>   <thedate>2013-06-15t00:00:00</thedate>   <somenotes> </somenotes> </row> <row>   <id>3</id>   <description>description 3</description>   <thedate>2013-06-21t00:00:00</thedate>   <somenotes>bobobobojkfjh</somenotes> </row> <row>   <id>4</id>   <description>description 4</description>   <thedate>2013-06-17t00:00:00</thedate>   <somenotes>adaad</somenotes> </row> <row>   <id>5</id>   <description>description 5</description>   <thedate>2013-06-24t00:21:04.803</thedate>   <somenotes>zcxzc</somenotes> </row> <row>   <id>6</id>   <description>description 6</description>   <thedate>2012-12-01t00:00:00</thedate>   <somenotes>ssss</somenotes> </row> <row>   <id>7</id>   <description>description 11</description>   <thedate>2013-05-16t00:21:04.803</thedate>   <somenotes> </somenotes> </row> <row>   <id>8</id>   <description>description 21</description>   <thedate>2013-05-07t00:00:00</thedate>   <somenotes>notes 2</somenotes> </row> <row>   <id>9</id>   <description>description 31</description>   <thedate>2013-01-17t00:00:00</thedate>   <somenotes> </somenotes> </row> <row>   <id>10</id>   <description>description 41</description>   <thedate>2013-01-11t00:00:00</thedate>   <somenotes> </somenotes> </row> <row>   <id>11</id>   <description>description 51</description>   <thedate>2013-06-03t00:00:00</thedate>   <somenotes> </somenotes> </row> <row>   <id>12</id>   <description>description 61</description>   <thedate>2013-06-01t00:00:00</thedate>   <somenotes>some other notes</somenotes> </row> <row>   <id>13</id>   <description>desc 55</description>   <thedate>2013-06-25t00:00:00</thedate>   <somenotes>asadad  d ad ada</somenotes> </row> <row>   <id>14</id>   <description>desc 99</description>   <thedate>2013-06-24t00:00:00</thedate> </row> <row>   <id>15</id>   <description>desk 888</description>   <thedate>2013-05-10t00:00:00</thedate> </row> <row>   <id>16</id>   <description>test again</description>   <thedate>2013-05-02t00:00:00</thedate>   <somenotes>\ad</somenotes> </row> </data> 

i have created simple windows form application datagridview , testbox. here do:

  1. i want load "id", "description" , "thedate" elements datagridview columns , have "somenotes" appear in testbox when corresponding cell clicked in datagridview

  2. i able filter datagridview using "thedate" element can filter today, week, month, year using buttons on form.

any appreciated i'm quite inexperienced using xml files c#. want in simplest way possible nothing has sophisticated , again thanks.

1.read xml datatable.

2.binding datasource of datagridview datatable.

3.set display of coloumn in datagridview.


Comments

Popular posts from this blog

javascript - Count length of each class -

What design pattern is this code in Javascript? -

hadoop - Restrict secondarynamenode to be installed and run on any other node in the cluster -