I have an ASP.NET app using the Report Viewer control.
I would like the Report Viewer control to resize as the browser (web page)
is resized.
Setting <rsweb:ReportViewer ... Width="100%" ... </rsweb:ReportViewer>
controls the width as expected. As the page is made wider, the control
resizes.
However, when I use <rsweb:ReportViewer ... Height="100%" ...
</rsweb:ReportViewer> to do the same for the height of the control, the
report content does not appear. The toolbars appear, but the report content
does not.
I have to do something like <rsweb:ReportViewer ... Height="300px" ...
</rsweb:ReportViewer> to get my report content to appear.
Is this a known problem?
Is there something I am overlooking, like is there another property I need
to set to get this to work? I cannot find any other property that looks like
it is related to this problem.
--
Chris, SSSI
This is a XHTML artifact. If you remove the doctype in the asp.net page, it
will work.
Please remove the line <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> in the asp.net
page.
Sincerely,
Wei Lu
Microsoft Online Community Support
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.
==================================================
(This posting is provided "AS IS", with no warranties, and confers no
rights.)
How is everything going? Does my suggestion resolve your problem?
If you have any feedback, please feel free to let me know.
>>This is a XHTML artifact.
Can you explain in more detail what you mean? Why is the presence of DOCTYPE
causing this behavior in the Report Viewer Control?
>>If you remove the doctype in the asp.net page, it will work.
>>Please remove the line <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
>>Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
>>in the asp.net page.
Why will this fix the problem?
What if any other problems will removing that line of code cause?
Thanks!
--
Chris, SSSI
>>If you remove the doctype in the asp.net page, it will work.
>>Please remove the line <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
>>Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
>>in the asp.net page.
Our ASP.NET pages have this line:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
Not the one that you mentioned.
Also, I removed the line of code above, and it made no difference. The
report content still does not appear when Height="100%". Only the Report
Viewer Control tool bars appear. The report does not appear in the HTML
rendering. However, if I export the report being viewed to PDF format, all
report content is rendered. This looks like a bug in the Report Viewer
Control.
--
Chris, SSSI
How you test the page?
Would you please try to test on a simple page with only one report viewer
control on it?
Please remove the line and have the height to "100%" for the report viewer.
Sincerely,
Wei Lu
Microsoft Online Community Support
==================================================
I can, but my application does not have a "simple page with only one report
viewer
control on it". So even if it works on a simple page that does not solve my
problem.
How do you propose that I fix this problem in my application?
-- Chris
--
Chris, SSSI
What is the nature of your page? Is it ASP.NET 1.0, 1.1 or 2.0?
Are you using master pages? (we are).
-- Chris
--
Chris, SSSI
The good news is I solved my problem.
I did have to remove the !DOCTYPE as you suggested. But the problem also was
related to the fact that the Report Viewer Control was contained inside a
table on the page. And that table had no height specified. Once I set
height="100%" on the table, the report content for the Report Viewer Control
appeared. I thought that if you do not set a size for an html table, that it
will be sized based on its content. Since the Report Viewer Control shows the
report pages, I would expect the table to be sized accordingly. Anyway I am
not sure I understand why my fix solved the problem, but it did fix it.
===================
MORE IMPORTANTLY
===================
I had some questions in a earlier pose in this thread that you did not
answer. Can you please answer them now?
>>This is a XHTML artifact.
Can you explain in more detail what you mean? Why is the presence of DOCTYPE
causing this behavior in the Report Viewer Control?
>>If you remove the doctype in the asp.net page, it will work.
>>Please remove the line <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
>>Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
>>in the asp.net page.
Why does this fix the problem?
What, if any, other problems will removing that line of code cause?
-- Chris
--
Chris, SSSI
I think this is that the Report Viewer Control rendered the HTML code does
not matc the XHTML artifact.
This issue is a known issue of the Report Viewer Control. I got this
workaround from the product team and they do not provide more detailed
information on this issue.
Anyway, I am glad to discuss more detail on this issue but since this is
relate the Report Viewer Control Code, I could not provide more detailed
information now. Thank you for your follow up.
andrea
--
andrea tiveron
director
e-metodi.it
rome
italy
For Example..
<rsweb:ReportViewer ID="rptViewer" SizeToReportContent="true" Width="100%" runat="server" AsyncRendering="false">
</rsweb:ReportViewer>
Chill !!!
Azhar
EggHeadCafe - .NET Developer Portal of Choice
http://www.eggheadcafe.com/default.aspx?ref=ng
Posted via DevelopmentNow.com Groups
http://www.developmentnow.com/g/
It is perfectly working after removing the doc type in the page
Thanks
Vinod
>> On Friday, September 01, 2006 2:06 AM wrote:
>> Hello Chris,
>>
>>
>>
>> This is a XHTML artifact. If you remove the doctype in the asp.net page, it
>>
>>
>>
>> will work.
>>
>>
>>
>> Please remove the line <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
>>
>>
>>
>> Transitional//EN"
>>
>>
>>
>> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> in the asp.net
>>
>>
>>
>> page.
>>
>>
>>
>> Sincerely,
>>
>>
>>
>> Wei Lu
>>
>>
>>
>> Microsoft Online Community Support
>>
>>
>>
>> ==================================================
>>
>>
>>
>> Get notification to my posts through email? Please refer to
>>
>>
>>
>> http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
>>
>>
>>
>> ications.
>>
>>
>>
>> Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
>>
>>
>>
>> where an initial response from the community or a Microsoft Support
>>
>>
>>
>> Engineer within 1 business day is acceptable. Please note that each follow
>>
>>
>>
>> up response may take approximately 2 business days as the support
>>
>>
>>
>> professional working with you may need further investigation to reach the
>>
>>
>>
>> most efficient resolution. The offering is not appropriate for situations
>>
>>
>>
>> that require urgent, real-time or phone-based interactions or complex
>>
>>
>>
>> project analysis and dump analysis issues. Issues of this nature are best
>>
>>
>>
>> handled working with a dedicated Microsoft Support Engineer by contacting
>>
>>
>>
>> Microsoft Customer Support Services (CSS) at
>>
>>
>>
>> http://msdn.microsoft.com/subscriptions/support/default.aspx.
>>
>>
>>
>> ==================================================
>>
>>
>>
>> (This posting is provided "AS IS", with no warranties, and confers no
>>
>>
>>
>> rights.)
>>>> On Wednesday, September 06, 2006 10:17 AM wrote:
>>>> Hello Wei,
>>>>
>>>>
>>>>
>>>> How you test the page?
>>>>
>>>>
>>>>
>>>> Would you please try to test on a simple page with only one report viewer
>>>>
>>>>
>>>>
>>>> control on it?
>>>>
>>>>
>>>>
>>>> Please remove the line and have the height to "100%" for the report viewer.
>>>>
>>>>
>>>>
>>>> Sincerely,
>>>>
>>>>
>>>>
>>>> Wei Lu
>>>>
>>>>
>>>>
>>>> Microsoft Online Community Support
>>>>
>>>>
>>>>
>>>> ==================================================
>>>>
>>>>
>>>>
>>>> Get notification to my posts through email? Please refer to
>>>>
>>>>
>>>>
>>>> http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
>>>>
>>>>
>>>>
>>>> ications.
>>>>
>>>>
>>>>
>>>> Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
>>>>
>>>>
>>>>
>>>> where an initial response from the community or a Microsoft Support
>>>>
>>>>
>>>>
>>>> Engineer within 1 business day is acceptable. Please note that each follow
>>>>
>>>>
>>>>
>>>> up response may take approximately 2 business days as the support
>>>>
>>>>
>>>>
>>>> professional working with you may need further investigation to reach the
>>>>
>>>>
>>>>
>>>> most efficient resolution. The offering is not appropriate for situations
>>>>
>>>>
>>>>
>>>> that require urgent, real-time or phone-based interactions or complex
>>>>
>>>>
>>>>
>>>> project analysis and dump analysis issues. Issues of this nature are best
>>>>
>>>>
>>>>
>>>> handled working with a dedicated Microsoft Support Engineer by contacting
>>>>
>>>>
>>>>
>>>> Microsoft Customer Support Services (CSS) at
>>>>
>>>>
>>>>
>>>> http://msdn.microsoft.com/subscriptions/support/default.aspx.
>>>>
>>>>
>>>>
>>>> ==================================================
>>>>
>>>>
>>>>
>>>> (This posting is provided "AS IS", with no warranties, and confers no
>>>>
>>>>
>>>>
>>>> rights.)
>>>>> Sincerely,
>>>>>
>>>>>
>>>>>
>>>>> Wei Lu
>>>>>
>>>>>
>>>>>
>>>>> Microsoft Online Community Support
>>>>>> On Wednesday, September 20, 2006 9:43 AM andy6 wrote:
>>>>>> Hi Chris
>>>>>> excuse for the delay of my answer.
>>>>>> 1) Asp.Net 2.0
>>>>>> 2) No, I do not use master page!
>>>>>>
>>>>>> andrea
>>>>>> --
>>>>>> andrea tiveron
>>>>>> director
>>>>>> e-metodi.it
>>>>>> rome
>>>>>> italy
>>>>>>
>>>>>>
>>>>>> "Chris G." wrote:
>>>>>>> On Sunday, January 11, 2009 1:41 AM Azhar Kazi wrote:
>>>>>>> Guys here is a good news for you all, the solutiono is really very simple.
>>>>>>>
>>>>>>> set AsyncRendering to false in the Report viewer control, that should solve your problem.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> For Example..
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> <rsweb:ReportViewer ID="rptViewer" SizeToReportContent="true" Width="100%" runat="server" AsyncRendering="false">
>>>>>>>
>>>>>>> </rsweb:ReportViewer>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> Chill !!!
>>>>>>>
>>>>>>> Azhar
>>>>>>>> On Sunday, January 11, 2009 1:41 AM Azhar Kazi wrote:
>>>>>>>> Guys here is a good news for you all, the solutiono is really very simple.
>>>>>>>>
>>>>>>>> set AsyncRendering to false in the Report viewer control, that should solve your problem.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> For Example..
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> <rsweb:ReportViewer ID="rptViewer" SizeToReportContent="true" Width="100%" runat="server" AsyncRendering="false">
>>>>>>>>
>>>>>>>> </rsweb:ReportViewer>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> Chill !!!
>>>>>>>>
>>>>>>>> Azhar
>>>>>>>>> Submitted via EggHeadCafe - Software Developer Portal of Choice
>>>>>>>>> Composing WCF applications
>>>>>>>>> http://www.eggheadcafe.com/tutorials/aspnet/b428fb65-08b4-45c8-97cd-47ee1a1eaf41/composing-wcf-applications.aspx