Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Type 'DataSet' is not defined.

Posted on 2006-06-07
4
Medium Priority
?
1,462 Views
Last Modified: 2008-03-06
Hi,

I have a aspx and ascx when I run the aspx file it generates the following error:



Server Error in '/' Application.
--------------------------------------------------------------------------------
Compilation Error
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: BC30002: Type 'DataSet' is not defined.
Source Error:
Line 3:      Sub Page_Load(ByVal Sender As Object, ByVal E As EventArgs)
Line 4:          Dim dgi As DataGridItem = CType(Me.BindingContainer, DataGridItem)
Line 5:          Dim ds As DataSet = CType(dgi.DataItem, DataSet)
Line 6:          If (Not (TypeOf dgi.DataItem Is DataSet)) Then
Line 7:              Throw New ArgumentException("Please change the TemplateDataMode attribute to 'Table' in the HierarGrid declaration")
Source File: c:\inetpub\wwwroot\Template\Sup.ascx    Line: 5

0
Comment
Question by:RyanBank
  • 2
4 Comments
 
LVL 10

Assisted Solution

by:SystemExpert
SystemExpert earned 80 total points
ID: 16850828
Hi,

Read the discussion from following link and has good tips for your problem

and hope it may help

http://www.programmingtalk.com/archive/index.php/t-2280.html

Thanks
0
 
LVL 7

Accepted Solution

by:
SimonBlake earned 1920 total points
ID: 16850829
Have you imported System.Data?

Simon
0
 

Author Comment

by:RyanBank
ID: 16850858
SimonBlake,

Work like a charm!

Thanks
0
 
LVL 7

Expert Comment

by:SimonBlake
ID: 16850868
n/p easily done
0

Featured Post

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

One of the pain points with developing AJAX, JavaScript, JQuery, and other client-side behaviors is that JavaScript doesn’t allow for cross domain request for pulling content. For example, JavaScript code on www.johnchapman.name could not pull conte…
Sometimes in DotNetNuke module development you want to swap controls within the same module definition.  In doing this DNN (somewhat annoyingly) swaps the Skin and Container definitions to the default admin selections.  To get around this you need t…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an anti-spam), the admin…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Suggested Courses
Course of the Month20 days, 14 hours left to enroll

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question