oWB = (Excel._Workbook)oWS.Parent; oChart1 = (Excel._Chart)oWB.Charts.Add(Missing.Value, Missing.Value, Missing.Value, Missing.Value); // / / / oChart1.HasTitle = true; oChart1.ChartTitle.Text = Id + "\t" + date + "\t" + cert; / / / // oRange1 = oWS.get_Range(mgraph(maxchart,minchart,10,2,jj)); oChart1.SetSourceData(oRange1, Type.Missing); oChart1.ChartType = Microsoft.Office.Interop.Excel.XlChartType.xlLine; Excel.Axis xAxis1 = (Excel.Axis)oChart1.Axes(Excel.XlAxisType.xlCategory, Excel.XlAxisGroup.xlPrimary); xAxis1.CategoryNames = oRange_ChartValue; oChart1.Location(Excel.XlChartLocation.xlLocationAsObject, oWS.Name); oRange1 = (Excel.Range)oWS.Rows.get_Item(j + 20, Missing.Value); oWS.Shapes.Item("Chart 2").Top = (float)(double)oRange1.Top; oRange1 = (Excel.Range)oWS.Columns.get_Item(2, Missing.Value); oWS.Shapes.Item("Chart 2").Left = (float)(double)oRange1.Left;
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)