473,386 Members | 1,705 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

how to reference strognly typed dataset up mulitple projects

I'm writing an winforms app in vb.net 1.1 and am having trouble referencing
a strongly typed dataset in the UI project. The dataset's source is behind
a web service and the data project (client side) gets a reference to the
dataset schema and all that comes with strongly typing a dataset via a
reference to the web service. The business tier which depends on the data
tier and also imports the namespace of the data project can reference this
dataset OK due to importing the data project's namespace. However, up one
more level in the UI project I can't reference the dataset because it's main
reference exists in the data tier and can not be seen through the business
tier.

For example, the project as names are as follows

VIPNow_WinUI UI tier
VIPNow_WinBLL Business tier
VIPNow_WinDAL Client side data tier

wsVA is the reference to the web service in the data tier
dsVAL_LU is the name of the dataset
tbVA_LU is a data table in the dataset

and the msg in the blue squiggly is:

Public ReadOnly Property tbVA_LU() As
VIPNow_WinDAL.wsVA.dsVAL_LU.tbVA_LUDataTable' is declared in project
'VIPNow_WinDAL.dll', which is not referenced by project 'VIPNow_WinUIL.exe'.

One of many reasons I need to reference the dataset in the UI tier is
because I pass parts of the dataset such as a datatable from the business
tier to the UI tier. another reason is I can have intellesence on the
dataset while having it's original source (where its strongly typed) in one
single place for the entire application which is behind the web service on
the server.

Is there a way to reference this dataset in the UI tier?

--
mo*******@nospam.nospam
Nov 21 '05 #1
5 1640
Moondaddy,

Is it possible that you give us this question step by step. I have now the
idea to see a complete architectural building in one newsgroup message.

Just my thought,

Cor
Nov 21 '05 #2
Hi

I did not understand your scenario very clear.
Can we simplify the scenario as below?
You have a typed dataset class in project A, and you want the project B to
use the dataset directly without generate again.
If so, I think you may need to do the similar job project B, because the
dataset class is regenerated everytime you make a single change..

If I have any misunderstanding, please feel free to post here. Also can you
specify your scenario more clearly?

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

Nov 21 '05 #3
"moondaddy" <mo*******@nospam.nospam> wrote in message
news:Op**************@TK2MSFTNGP09.phx.gbl...

In order to use the DataSet in the UI layer, you must have a reference
to the DLL in which the Type is defined. Since these objects are
being generated from a Web Service, the definition, presumably, is
somewhere server side.

However, in order to use your Typed DataSet on the client, the client
application needs its own reference the Dll that defines your Typed
DataSet class. Same assembly, deployed into two places. (There's
another way using Interfaces, but I haven't got there yet).

HTH,
Phill W.
Nov 21 '05 #4
Thanks. yes I was able to use the typed dataset in the UI by referencing
the data tier dll in the UI, but this seemed like a hack as the business
object should hold a reference to the data dll, and the UI dll hold a
reference to the business dll. I was hoping there was another way around
this.

--
mo*******@nospam.nospam
"Phill. W" <P.A.Ward@o-p-e-n-.-a-c-.-u-k> wrote in message
news:d9**********@yarrow.open.ac.uk...
"moondaddy" <mo*******@nospam.nospam> wrote in message
news:Op**************@TK2MSFTNGP09.phx.gbl...

In order to use the DataSet in the UI layer, you must have a reference
to the DLL in which the Type is defined. Since these objects are
being generated from a Web Service, the definition, presumably, is
somewhere server side.

However, in order to use your Typed DataSet on the client, the client
application needs its own reference the Dll that defines your Typed
DataSet class. Same assembly, deployed into two places. (There's
another way using Interfaces, but I haven't got there yet).

HTH,
Phill W.

Nov 21 '05 #5
Hi

Based on my understanding, the relation is as below.
UI->BL->DL--->WebService.
The Strong typed DataSet in Webservice will be exposed to DL, and DL will
regerate a its namespaced strong typed dataset.

I think in the common design scenario, the BL should encapsulate all the
data layer, the UI layer should not access to the dataset directly. The
Business layer should exposed the meaningful Object to the UI layer.
e.g. modal the employee table as the employee object, and use the
employee.name, employee.Add and so on method or property to hide the
concrete data in the dataset.

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

Nov 21 '05 #6

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

Similar topics

3
by: Freeon | last post by:
Hi, I am looking for a way to sort a strong typed dataset. It would seem the most straightforward way is to use a dataview. The only problem is when I use the dataview I seem to loose the strong...
1
by: Optimus | last post by:
Hi everyone, I currently develop an application in vs.net 2005 with vb.net. I was trying to use typed dataset and I've got in trouble for converting untyped dataset into Typed DataSet. I don't...
7
by: Annie | last post by:
hello guys, Let is say I have two layers: the GUI web application that has the master page and web forms. and the DAL - Data access layer which is another web application and has been created...
35
by: Chris | last post by:
Hi, I tried to create a class which must change the propety 'visible' of a <linktag in the masterpage into 'false' when the user is logged. But i get the error: "Object reference not set to an...
21
by: Peter Bradley | last post by:
Hi all, This post is sort of tangentially related to my earlier posts on configuration files for DLLs. Does anyone know how to create typed DataSets using VS2005's new DataSet designer, but...
2
by: Magnus Bergh | last post by:
I have a solution which contains multiple projects (different applications). Every project use the same typed dataset (and also a few other shared code files). I tried to remove the dataset.xsd...
1
by: ravilolam | last post by:
Hi guys Ravikumar here This is the erro iam not able to rectify, can any body help me for this. Description: An unhandled exception occurred during the execution of the current web request....
4
by: Rachana | last post by:
Hi, I have understood Data Sets but what is meant by typed/untyped/ strongly typed datasets. Can any one explain me or suggest any site/ article, to get these concepts (and their ...
4
by: John Sheppard | last post by:
Hello there I was wondering if anyone could help me, I am trying to pass a typed dataset to a dialoged child form by reference. I have binding sources sitting on the child form. So to refresh...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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,...
0
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...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.