Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > 'CrystalReportViewer' is ambiguous in the namespace 'CrystalDecisions.

Reply
Thread Tools

'CrystalReportViewer' is ambiguous in the namespace 'CrystalDecisions.

 
 
Nancy.
Guest
Posts: n/a
 
      09-28-2004
It seems that I can not be able to display a crystal
report with the crystal viewer in a web application.
However, in Windows Application I do not have this kind
of problems.

In a Web form, I have the CrystalReportViewer1 and
databind to a SampleDorm.rpt that is part of my project.

The following code binds the dataset to the report's
setdatasource.

Dim oRpt As SampleDorm
oRpt = New SampleDorm
oRpt.SetDataSource(m_dstG)
Once I executed this code I get the error message.
Any help?
 
Reply With Quote
 
 
 
 
i. Wiin
Guest
Posts: n/a
 
      09-28-2004
Make sure you include both CrystalDecisions.Web and
CrystalDecisions.CrystalReports.Engine

Then when you dim your oRpt as a
CrystalDecisions.CrystalReports.Engine.ReportDocum ent instead of the class
of your actual report as you were doing.

So it should look something like this: (pardon my VB.NET code below as I use
C# usually).

Dim oRpt as ReportDocument
oRpt = new SampleDorm
oRpt.SetDataSource(m_dstG)







"Nancy." <(E-Mail Removed)> wrote in message
news:2ec901c4a580$29fb52b0$(E-Mail Removed)...
> It seems that I can not be able to display a crystal
> report with the crystal viewer in a web application.
> However, in Windows Application I do not have this kind
> of problems.
>
> In a Web form, I have the CrystalReportViewer1 and
> databind to a SampleDorm.rpt that is part of my project.
>
> The following code binds the dataset to the report's
> setdatasource.
>
> Dim oRpt As SampleDorm
> oRpt = New SampleDorm
> oRpt.SetDataSource(m_dstG)
> Once I executed this code I get the error message.
> Any help?



 
Reply With Quote
 
 
 
 
Nancy
Guest
Posts: n/a
 
      09-28-2004
Thanks for your prompt response. I am not getting the
error anymore, but the report is not displaying in the
screen.

>-----Original Message-----
>Make sure you include both CrystalDecisions.Web and
>CrystalDecisions.CrystalReports.Engine
>
>Then when you dim your oRpt as a
>CrystalDecisions.CrystalReports.Engine.ReportDocu ment

instead of the class
>of your actual report as you were doing.
>
>So it should look something like this: (pardon my VB.NET

code below as I use
>C# usually).
>
>Dim oRpt as ReportDocument
>oRpt = new SampleDorm
>oRpt.SetDataSource(m_dstG)
>
>
>
>
>
>
>
>"Nancy." <(E-Mail Removed)> wrote in message
>news:2ec901c4a580$29fb52b0$(E-Mail Removed)...
>> It seems that I can not be able to display a crystal
>> report with the crystal viewer in a web application.
>> However, in Windows Application I do not have this kind
>> of problems.
>>
>> In a Web form, I have the CrystalReportViewer1 and
>> databind to a SampleDorm.rpt that is part of my

project.
>>
>> The following code binds the dataset to the report's
>> setdatasource.
>>
>> Dim oRpt As SampleDorm
>> oRpt = New SampleDorm
>> oRpt.SetDataSource(m_dstG)
>> Once I executed this code I get the error message.
>> Any help?

>
>
>.
>

 
Reply With Quote
 
i. Wiin
Guest
Posts: n/a
 
      09-28-2004
Are you seeing the CrystalReportsViewer control when viewing the page in a
browser? Is that control the only control you have on your page? Try
placing a Label just above and another just below the report viewer control.
Programmatically set the Text of the upper label at the beginnging of your
code that populates the report and then programmatically set the Text lower
label after you do the DataBind(). This way you know the code is being
processed.

"Nancy" <(E-Mail Removed)> wrote in message
news:027d01c4a590$ed14e620$(E-Mail Removed)...
> Thanks for your prompt response. I am not getting the
> error anymore, but the report is not displaying in the
> screen.



 
Reply With Quote
 
 
 
Reply

Thread Tools

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ambiguous in the namespace =?Utf-8?B?U2FudGlhZ28gUGF6IC0gRnJvbSBTcGFpbg==?= ASP .Net 0 10-22-2007 07:14 AM
user control ambiguous in the namespace g@work ASP .Net 2 07-04-2007 11:22 AM
usercontrol_ascx' is ambiguous in the namespace 'ASP'. Nemisis ASP .Net 4 04-16-2007 08:54 AM
'mycontrol_ascx' is ambiguous in namespace ASP =?Utf-8?B?SGFucyBCYXVtYW5u?= ASP .Net 0 11-23-2006 10:09 AM
BC30560: 'default_aspx' is ambiguous in the namespace 'ASP'. John ASP .Net 1 06-24-2005 02:06 PM



Advertisments