TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Dorababu Meka
215
8.3k
1.7m
Crystal report displaying varbinary(MAX) on the report
Sep 25 2016 2:16 AM
I am trying to display the varbinary data on a crystal report after converting it to original bytes. The content that I saved is a pdf content. I followed this approach to achieve as per my requirement
http://csharpdotnetfreak.blogspot.com/2012/06/crystal-reports-display-images-database.html
My code is as follows
SqlConnection con =
new
SqlConnection(ConfigurationManager.ConnectionStrings[
"MyCon"
].ConnectionString);
string
strSelect =
"SELECT FileData from Documents where ID = 26"
;
SqlCommand cmd =
new
SqlCommand(strSelect, con);
SqlDataAdapter dAdapter =
new
SqlDataAdapter(cmd);
con.Open();
dAdapter.Fill(dsReport.Tables[
"Documents"
]);
Byte[] bytes = (Byte[])dsReport.Tables[0].Rows[0][
"FileData"
];
dsReport.Tables[0].Rows[0][
"FileData"
] = bytes;
dsReport.AcceptChanges();
con.Close();
CrystalReport1 rpt =
new
CrystalReport1();
rpt.SetDataSource(dsReport);
crystalReportViewer1.ReportSource = rpt;
So can some one help me how can I display byte[] data on to the report
Reply
Answers (
3
)
Crystal report - complicated sql query
I like to create a sample dynamic telerik report? pls help