Crystal Report Viewer在Xaml.cs中为空 [英] Crystal Report Viewer Null in Xaml.cs

查看:73
本文介绍了Crystal Report Viewer在Xaml.cs中为空的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,

我在WPF应用程序中集成了crystal reportviewer。我引用了SAPBusinessObjects.WPF.Viewer和SAPBusinessObjects.WPF.ViewerShared dll。我可以在我的设计中看到crystalreportviewer控件。但是在我的xaml.cs中,Crystalreportviwer控件显示为null。我不知道我哪里出错了。我在VS 2012开发,.Net frameWork 3.5和CR 13安装在我的电脑上。以下代码是我的xaml代码。



窗口x:Class =WpfCrystalReport.frmLabelTemplate1

xmlns =http:// schemas。 microsoft.com/winfx/2006/xaml/presentation

xmlns:x =http://schemas.microsoft.com/winfx/2006/xaml

xmlns :my =clr-namespace:SAPBusinessObjects.WPF.Viewer; assembly = SAPBusinessObjects.WPF.Viewer

Title =MainWindowHeight =350Width =525

Grid

my:CrystalReportsViewer Horizo​​ntalAlignment =LeftName =crystalReportsViewer1

VerticalAlignment =TopHeight =500Width =500

网格

窗口



如果您有任何解决方案,请告诉我。

Hello,
I am integrating crystal reportviewer in WPF Application. I referenced SAPBusinessObjects.WPF.Viewer and SAPBusinessObjects.WPF.ViewerShared dll. I can see crystalreportviewer control in my design.But in my xaml.cs Crystalreportviwer control is showing null. I dont know where i am going wrong.I am developing in VS 2012 , .Net frameWork 3.5 and CR 13 is installed in my pc. Following code is my xaml code.

Window x:Class="WpfCrystalReport.frmLabelTemplate1"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:my="clr-namespace:SAPBusinessObjects.WPF.Viewer;assembly=SAPBusinessObjects.WPF.Viewer"
Title="MainWindow" Height="350" Width="525"
Grid
my:CrystalReportsViewer HorizontalAlignment="Left" Name="crystalReportsViewer1"
VerticalAlignment="Top" Height="500" Width="500"
Grid
Window

If you have any solution please let me know.

推荐答案

尝试本教程 [ ^ ]


这篇关于Crystal Report Viewer在Xaml.cs中为空的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆