![]() | |
![]() |
| | Thread Tools | Search this Thread | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
#3
| |||
| |||
|
|
Hi Scott, First of all, I would like to confirm my understanding of your issue. From your description, I understand that you need to use intellisense on a typed DataSet when it is made in code. If there is any misunderstanding, please feel free to let me know. As far as I know, typed DataSets are made in code. When you have created your .XSD file in IDE, VS.NET will generate class (.cs or .vb) file automatically according to the schema files using xsd.exe. The generated file will be put together with the schema. To see the .cs or .vb file that has been generated, here are the steps: 1. Click on the button Show all files in the Solution Explorer. 2. If your typed DataSet is MyDataSet, expand MyDataSet.xsd in the Solution Explorer. 3. Double click MyDataSet.cs or MyDataSet.vb to see the typed DataSet class definition. After you have built the project, the typed DataSet structure can be used for intellisense. For example, if you have two tables in it, named Customers and Orders, when you need to get the reference for one of the tables, you can simple use myDataSet.Orders instead of myDataSet.Tables["Orders"]. HTH. If anything is unclear, please feel free to reply to the post. Kevin Yu ======= "This posting is provided "AS IS" with no warranties, and confers no rights." |
#4
| |||
| |||
|
|
Actually Kevin, my question is, can you make a typed dataset completely from handwritten code, not using the IDE? "Kevin Yu [MSFT]" <v-kevy (AT) online (DOT) microsoft.com> wrote in message news 8xszDESEHA.1516 (AT) cpmsftngxa10 (DOT) phx.gbl...Hi Scott, First of all, I would like to confirm my understanding of your issue. From your description, I understand that you need to use intellisense on a typed DataSet when it is made in code. If there is any misunderstanding, please feel free to let me know. As far as I know, typed DataSets are made in code. When you have created your .XSD file in IDE, VS.NET will generate class (.cs or .vb) file automatically according to the schema files using xsd.exe. The generated file will be put together with the schema. To see the .cs or .vb file that has been generated, here are the steps: 1. Click on the button Show all files in the Solution Explorer. 2. If your typed DataSet is MyDataSet, expand MyDataSet.xsd in the Solution Explorer. 3. Double click MyDataSet.cs or MyDataSet.vb to see the typed DataSet class definition. After you have built the project, the typed DataSet structure can be used for intellisense. For example, if you have two tables in it, named Customers and Orders, when you need to get the reference for one of the tables, you can simple use myDataSet.Orders instead of myDataSet.Tables["Orders"]. HTH. If anything is unclear, please feel free to reply to the post. Kevin Yu ======= "This posting is provided "AS IS" with no warranties, and confers no rights." |
#5
| |||
| |||
|
|
Actually Kevin, my question is, can you make a typed dataset completely from handwritten code, not using the IDE? "Kevin Yu [MSFT]" <v-kevy (AT) online (DOT) microsoft.com> wrote in message news 8xszDESEHA.1516 (AT) cpmsftngxa10 (DOT) phx.gbl...Hi Scott, First of all, I would like to confirm my understanding of your issue. From your description, I understand that you need to use intellisense on a typed DataSet when it is made in code. If there is any misunderstanding, please feel free to let me know. As far as I know, typed DataSets are made in code. When you have created your .XSD file in IDE, VS.NET will generate class (.cs or .vb) file automatically according to the schema files using xsd.exe. The generated file will be put together with the schema. To see the .cs or .vb file that has been generated, here are the steps: 1. Click on the button Show all files in the Solution Explorer. 2. If your typed DataSet is MyDataSet, expand MyDataSet.xsd in the Solution Explorer. 3. Double click MyDataSet.cs or MyDataSet.vb to see the typed DataSet class definition. After you have built the project, the typed DataSet structure can be used for intellisense. For example, if you have two tables in it, named Customers and Orders, when you need to get the reference for one of the tables, you can simple use myDataSet.Orders instead of myDataSet.Tables["Orders"]. HTH. If anything is unclear, please feel free to reply to the post. Kevin Yu ======= "This posting is provided "AS IS" with no warranties, and confers no rights." |
#6
| |||
| |||
|
|
Hi Scott, Why not? Look the .cs class behind the xsd file -there is everything MSDataSetGenerator created. -- Miha Markic [MVP C#] - RightHand .NET consulting & development miha at rthand com www.rthand.com "Scott M." <s-mar (AT) nospam (DOT) nospam> wrote in message news:O$7edIESEHA.2876 (AT) TK2MSFTNGP09 (DOT) phx.gbl... Actually Kevin, my question is, can you make a typed dataset completely from handwritten code, not using the IDE? "Kevin Yu [MSFT]" <v-kevy (AT) online (DOT) microsoft.com> wrote in message news 8xszDESEHA.1516 (AT) cpmsftngxa10 (DOT) phx.gbl...Hi Scott, First of all, I would like to confirm my understanding of your issue. From your description, I understand that you need to use intellisense on a typed DataSet when it is made in code. If there is any misunderstanding, please feel free to let me know. As far as I know, typed DataSets are made in code. When you have created your .XSD file in IDE, VS.NET will generate class (.cs or .vb) file automatically according to the schema files using xsd.exe. The generated file will be put together with the schema. To see the .cs or .vb file that has been generated, here are the steps: 1. Click on the button Show all files in the Solution Explorer. 2. If your typed DataSet is MyDataSet, expand MyDataSet.xsd in the Solution Explorer. 3. Double click MyDataSet.cs or MyDataSet.vb to see the typed DataSet class definition. After you have built the project, the typed DataSet structure can be used for intellisense. For example, if you have two tables in it, named Customers and Orders, when you need to get the reference for one of the tables, you can simple use myDataSet.Orders instead of myDataSet.Tables["Orders"]. HTH. If anything is unclear, please feel free to reply to the post. Kevin Yu ======= "This posting is provided "AS IS" with no warranties, and confers no rights." |
#7
| |||
| |||
|
|
I'm not asking if a typed DataSet can be represented by code. I'm asking if I can make one completely in code (no VS .NET drag & drop) and still get intellisense when I use the DataSet. "Miha Markic [MVP C#]" <miha at rthand com> wrote in message news:eRAoaQHSEHA.1644 (AT) TK2MSFTNGP09 (DOT) phx.gbl... Hi Scott, Why not? Look the .cs class behind the xsd file -there is everything MSDataSetGenerator created. -- Miha Markic [MVP C#] - RightHand .NET consulting & development miha at rthand com www.rthand.com "Scott M." <s-mar (AT) nospam (DOT) nospam> wrote in message news:O$7edIESEHA.2876 (AT) TK2MSFTNGP09 (DOT) phx.gbl... Actually Kevin, my question is, can you make a typed dataset completely from handwritten code, not using the IDE? "Kevin Yu [MSFT]" <v-kevy (AT) online (DOT) microsoft.com> wrote in message news 8xszDESEHA.1516 (AT) cpmsftngxa10 (DOT) phx.gbl...Hi Scott, First of all, I would like to confirm my understanding of your issue. From your description, I understand that you need to use intellisense on a typed DataSet when it is made in code. If there is any misunderstanding, please feel free to let me know. As far as I know, typed DataSets are made in code. When you have created your .XSD file in IDE, VS.NET will generate class (.cs or .vb) file automatically according to the schema files using xsd.exe. The generated file will be put together with the schema. To see the .cs or .vb file that has been generated, here are the steps: 1. Click on the button Show all files in the Solution Explorer. 2. If your typed DataSet is MyDataSet, expand MyDataSet.xsd in the Solution Explorer. 3. Double click MyDataSet.cs or MyDataSet.vb to see the typed DataSet class definition. After you have built the project, the typed DataSet structure can be used for intellisense. For example, if you have two tables in it, named Customers and Orders, when you need to get the reference for one of the tables, you can simple use myDataSet.Orders instead of myDataSet.Tables["Orders"]. HTH. If anything is unclear, please feel free to reply to the post. Kevin Yu ======= "This posting is provided "AS IS" with no warranties, and confers no rights." |
#8
| |||
| |||
|
|
Hi Scott, I am not sure I understand you. Typed dataset is code, acutally it is a class derived from DataSet. The designer does just that - it converts xsd into a class derived from DataSet which is later used by ide. You can freely create it by yourself - it is no magic there. -- Miha Markic [MVP C#] - RightHand .NET consulting & development miha at rthand com www.rthand.com So, if you code your own typed dataset "Scott M." <s-mar (AT) nospam (DOT) nospam> wrote in message news:%23gjDioJSEHA.3056 (AT) TK2MSFTNGP11 (DOT) phx.gbl... I'm not asking if a typed DataSet can be represented by code. I'm asking if I can make one completely in code (no VS .NET drag & drop) and still get intellisense when I use the DataSet. "Miha Markic [MVP C#]" <miha at rthand com> wrote in message news:eRAoaQHSEHA.1644 (AT) TK2MSFTNGP09 (DOT) phx.gbl... Hi Scott, Why not? Look the .cs class behind the xsd file -there is everything MSDataSetGenerator created. -- Miha Markic [MVP C#] - RightHand .NET consulting & development miha at rthand com www.rthand.com "Scott M." <s-mar (AT) nospam (DOT) nospam> wrote in message news:O$7edIESEHA.2876 (AT) TK2MSFTNGP09 (DOT) phx.gbl... Actually Kevin, my question is, can you make a typed dataset completely from handwritten code, not using the IDE? "Kevin Yu [MSFT]" <v-kevy (AT) online (DOT) microsoft.com> wrote in message news 8xszDESEHA.1516 (AT) cpmsftngxa10 (DOT) phx.gbl...Hi Scott, First of all, I would like to confirm my understanding of your issue. From your description, I understand that you need to use intellisense on a typed DataSet when it is made in code. If there is any misunderstanding, please feel free to let me know. As far as I know, typed DataSets are made in code. When you have created your .XSD file in IDE, VS.NET will generate class (.cs or .vb) file automatically according to the schema files using xsd.exe. The generated file will be put together with the schema. To see the .cs or .vb file that has been generated, here are the steps: 1. Click on the button Show all files in the Solution Explorer. 2. If your typed DataSet is MyDataSet, expand MyDataSet.xsd in the Solution Explorer. 3. Double click MyDataSet.cs or MyDataSet.vb to see the typed DataSet class definition. After you have built the project, the typed DataSet structure can be used for intellisense. For example, if you have two tables in it, named Customers and Orders, when you need to get the reference for one of the tables, you can simple use myDataSet.Orders instead of myDataSet.Tables["Orders"]. HTH. If anything is unclear, please feel free to reply to the post. Kevin Yu ======= "This posting is provided "AS IS" with no warranties, and confers no rights." |
#9
| |||
| |||
|
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
| |