473,671 Members | 2,231 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Adding a dataset

I have a project with the namespace "Rota" and added an XML file with the
second line( after the version and encoding) <Rota xmlns"Http\\... .etc"/>. I
then created a schema and dragged a DataSet onto the main form of the
project. The pop up window offered me the name Rota.Rota, so accepted it.
It created a dataset object called rota1 in the component tray, but my
program doesn't recognise the name "Rota". I get the message "The name Rota
is not recognised in the namespace Rota.Rota. Are you missing a ref....etc."

What have I done wrong?

As you can probably imagine, I am VERY new to programming, so any help would
be much appreciated.
Nov 16 '05 #1
2 1103
Hi
Try to witch to code file and see the initialization of the dataset. give
it the full path . ie the namespace then the name of the class created for
your typed dataset.( under your xsd file you will find a CS file that
include the implementioan for your dataset ' I will dump an example at the
end of the post ) get the name of the class ( for that is the name that you
use for your instance )
So you call it private namespace_name. the_set_class_n ame myset ;
For example if you have a class named trail in namespace all then you will
have to define the dataset as
Private all.trial mydastset ;
Here you are what the class should look like
public class trial : DataSet { \\ it inhiret from dataset (and this is //
the name you need to use

private rowDataTable tablerow;

public xml() {
// it should be a reasnabaly long class…..
….
….
hope this was clear
Mohamed Mahfouz
MEA Developer Support Center
ITworx on behalf of Microsoft EMEA GTSC

Nov 16 '05 #2
Thanks Mohamoss. Sorted it out now.

"Mohamoss" wrote:
Hi
Try to witch to code file and see the initialization of the dataset. give
it the full path . ie the namespace then the name of the class created for
your typed dataset.( under your xsd file you will find a CS file that
include the implementioan for your dataset ' I will dump an example at the
end of the post ) get the name of the class ( for that is the name that you
use for your instance )
So you call it private namespace_name. the_set_class_n ame myset ;
For example if you have a class named trail in namespace all then you will
have to define the dataset as
Private all.trial mydastset ;
Here you are what the class should look like
public class trial : DataSet { \\ it inhiret from dataset (and this is //
the name you need to use

private rowDataTable tablerow;

public xml() {
// it should be a reasnabaly long class…..
….
….
hope this was clear
Mohamed Mahfouz
MEA Developer Support Center
ITworx on behalf of Microsoft EMEA GTSC

Nov 16 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
4003
by: Eric Petruzzelli | last post by:
If I fill my dataset and there is no data. The dataset is still created with zero rows (all columns are there). When I add my first row using the script below, it takes over 2 seconds to add??? If I add the second row, instant. How can I eliminate this delay?
0
1228
by: lgdev | last post by:
I am using a Dataset with two tables (Customer, Order) and adding a DataRelation object with Nested property set to True. I do not have a schema defined for the dataset. Calling GetXml results in the following: <Customer> <Order /> <Order /> <Order /> </Customer>
4
5477
by: DotNetJunky | last post by:
I have built a control that runs an on-line help system. Depending on the category you selected via dropdownlist, it goes out and gets the child subcategories, and if there are any, adds a new dropdownlist to the screen for selection. This continues until there are no children, and then it checks for a help article list based on that last selection and displays actual articles for display. Adding the controls and getting everything...
3
4873
by: Jim Heavey | last post by:
Trying to figure out the technique which should be used to add rows to a datagrid. I am thinking that I would want an "Add" button on the footer, but I am not quite sure how to do that. Is that the best method? Do you have a sample of how to do this?
10
2339
by: Trevor | last post by:
Hey, I am trying to do this tutorial on the microsoft site : http://msdn.microsoft.com/library/default.asp? url=/library/en-us/dndotnet/html/usingadonet.asp I can get everything to work up to the DataAdd part (Section heading is Adding Rows to a DataSet) I dont really know what to do after i have added all the
16
2475
by: Geoff Jones | last post by:
Hi Can anybody help me with the following, hopefully simple, question? I have a table which I've connected to a dataset. I wish to add a new column to the beginning of the table and to fill it with incremental values e.g. if the tables looks like this: 23 56
6
4409
by: Rudy | last post by:
Hi all, I know this is easy, just can't seem to get it. I have a windows form, and a text box, with a value already in it. I need to add that value to a table. It's just one value, so the entire row doesn't get filled. I have a connection and all that stuff. Private Sub btnPlaceBet_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnPlaceBet.Click ' Dim Myds As Footbet.DStable '...
6
2233
by: Mark | last post by:
I'm trying to add a table to a dataset but get the error: "A DataTable named 'BordDates0040' already belongs to this DataSet." Code: Dim dtBordDates As DataTable dtBordDates = LoadTable(strDBPath & strDBName, strTableName, strSQL) Dim ds2 As DataSet = New DataSet()
0
1447
by: AboutJAV | last post by:
I created a crystal report with the report.rpt reportdata.xsd I created the a new dataset with the reportdata myreportdata = new reportdata(); That automatically created a new dataset with all the fields I
1
2505
by: vbDavidC | last post by:
I am adding a new record to a table via a dataset/adapter. I have got the following to work for me but I am wondering if there is a better way to do this. I am having to have something in my DS before I can add records, since DS does not exist. I'd rather not have a SELECT since I really don't need any records in my dataset that I will be adding a new record to. Dim dsNewRow As DataRow
0
8472
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8390
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8909
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8667
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7428
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6222
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4399
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2806
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1801
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.