PC Review Forums Newsgroups Microsoft DotNet Microsoft ADO .NET Typed dataset as remoting methods return type problem

Reply

Typed dataset as remoting methods return type problem

 
Thread Tools Rate Thread
Old 14-09-2004, 05:06 PM   #1
Gatwick
Guest
 
Posts: n/a
Default Typed dataset as remoting methods return type problem


VS 2003 .Net fw 1.1

I have remoting object (singleton) with such method:

public Common.DataSetOffices GetSalesPointList()
{
// prepare return data
DataSet dsResult = m_DataSetOffices.Copy();
return dsResult;
}

I use it in my app as:
...
Common.DataSetOffices dsTmp = obj.SalesPointList;
...
But when ecxecution runs to this string exception occures(just at the
time of assignment operator):

Object reference not set to an instance of an object. System.Data at
System.Data.LookupNode.Bind(DataTable table, ArrayList list)
at System.Data.DataExpression.Bind(DataTable table)
at System.Data.DataExpression..ctor(String expression, DataTable
table, Type type)
at System.Data.DataColumn.set_Expression(String value)
at System.Data.Merger.MergeSchema(DataTable table)
at System.Data.Merger.MergeTableData(DataTable src)
at System.Data.Merger.MergeDataSet(DataSet source)
at System.Data.DataSet.Merge(DataSet dataSet, Boolean preserveChanges,
MissingSchemaAction missingSchemaAction)
at ColIns.DataSetOffices..ctor(SerializationInfo info,
StreamingContext context) in X:\ColIns\Common\DataSetOffices.cs:line
63

As far as I see the problem is in DataSetOffices constructor. But it
is wizard-generated and i dont want to change it for my own. How can
I avoid such problem?

  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off