我在SSRS 2008中創建了一個簡單的報告。我開始複製現有的報告定義並對其進行了修改以適合我的需要。我正在ASP.NET MVC項目的C#中使用Visual Studio Ultimate 2012。矩形中的SSRS圖像/ texboxes不顯示
我有兩個矩形,矩形1和矩形2。 Rectangle1來自原始報告並且顯示得很好,我只是重新排列了其中的ReportItems。但是,Rectangle2並未顯示在生成的報告上。我在設計師中創建了它,並將現有圖像剪切/粘貼到其中。除了外部圖像外,Rectangle2還包含一個帶有靜態值的文本框。
這是我已經試過:
- 驗證了我的數據,獲得通過並是正確的。
- 驗證了所有相關的表達式。
- 驗證我要求的圖像存在。
- 刪除了收縮/增長參數。
- 驗證沒有設置條件顯示要求。
- 創建了一個全新的帶有文本框和圖像的矩形(不顯示)。
- 比較了Rectangle1和Rectangle2之間的XML。
- 比較了Rectangle1和 Rectangle2之間的參數值(在設計器中)以及它們的所有子元素。
- 調整後的Z指數參數。
我在網上找不到任何相關信息。無處不在。納達。壓縮。我沒有想法。
請指點我正確的方向。
下面是一些XML:
<Rectangle Name="Rectangle1">
<ReportItems>
<Image Name="GHS_1">
<Source>External</Source>
<Value>="file:///" + Parameters!AppPath.Value + Parameters!GHSPictograms.Value(0)</Value>
<MIMEType>image/png</MIMEType>
<Sizing>FitProportional</Sizing>
<Top>0.45312in</Top>
<Left>0.17958in</Left>
<Height>1.56in</Height>
<Width>1.56in</Width>
<Visibility>
<Hidden>=Parameters!GHSPictograms.Value(0) = ""</Hidden>
</Visibility>
<Style>
<Border>
<Style>None</Style>
</Border>
</Style>
</Image>
<Textbox Name="Textbox1">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style />
</TextRun>
</TextRuns>
<Style />
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox1</rd:DefaultName>
<Top>2.0521in</Top>
<Left>3.91688in</Left>
<Height>0.25in</Height>
<Width>0.05208in</Width>
<ZIndex>4</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</ReportItems>
<KeepTogether>true</KeepTogether>
<Top>0.84944in</Top>
<Height>6.84897in</Height>
<Width>3.96896in</Width>
<ZIndex>2</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
</Style>
</Rectangle>
...
<Rectangle Name="Rectangle2">
<ReportItems>
<Image Name="PPE0">
<Source>External</Source>
<Value>="File:///" + Parameters!AppPath.Value + Parameters!PPEImages.Value(0)</Value>
<MIMEType>image/png</MIMEType>
<Sizing>FitProportional</Sizing>
<Top>0.45312in</Top>
<Height>1in</Height>
<Width>1in</Width>
<Visibility>
<Hidden>=Parameters!PPEImages.Count < 1</Hidden>
</Visibility>
<Style>
<Border>
<Style>None</Style>
</Border>
</Style>
</Image>
<Textbox Name="Textbox2">
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>PPE</Value>
<Style>
<FontSize>12pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
</TextRuns>
<Style />
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Height>0.33333in</Height>
<Width>1in</Width>
<ZIndex>5</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</ReportItems>
<KeepTogether>true</KeepTogether>
<Top>0.84944in</Top>
<Left>4.0384in</Left>
<Height>1.45312in</Height>
<Width>5.60125in</Width>
<ZIndex>5</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
</Style>
</Rectangle>
UPDATE:我們設法讓Rectangle2顯示在Rectangle1的用z-index玩弄周圍的代價。所以這是有多個矩形的一個問題...
注:我可以通過將所有內容嵌套在一個大的矩形中來繞過這個問題。 SSRS不喜歡多個矩形作爲Body的即時ReportItems。 – kozmi