Thank you for reply
I changed my code i create
Dataset1
DataTable1 inside Dataset1 have these fields
DriverID
DriverName
EmplyeeName
ResidentNo
and make stored procedure as
create proc ViewEmployeeNoR
(
@EmployeeNo nvarchar(20)
)
as
select * from dbo.ViewTest6 where DriverID=@EmployeeNo
and make Dataset1 as datasource of my report CrystalReportData1
and put in form crystal report viewer and textbox1 and button1
under button1 i write this code
SqlConnection con = new SqlConnection("data source=192.168.1.5; initial catalog=hrdata;uid=sa; password=1234");
SqlCommand cmd = new SqlCommand();
cmd.Connection = con;
cmd.CommandType = CommandType.StoredProcedure;
//cmd.CommandText = "Select DriverID,DriverName,EmplyeeName,ResidentNo from Employee where DriverID=@EmployeeNo";
cmd.CommandText = "ViewEmployeeNoR";
cmd.Parameters.Add("@EmployeeNo", SqlDbType.NVarChar, 20);
cmd.Parameters["@EmployeeNo"].Value = textBox1.Text;
SqlDataAdapter da = new SqlDataAdapter();
da.SelectCommand = cmd;
DataSet1 ds = new DataSet1();
da.Fill(ds, "DataTable1");
Reports.CrystalReportData1 objRpt = new Reports.CrystalReportData1();
objRpt.SetDataSource(ds.Tables[0]);
crystalReportViewer1.ReportSource = objRpt;
crystalReportViewer1.Refresh();
but i dont know how to customize this code to accept adding image
this all what i do
can any one help me how to add image in crystal report from local path