Kirish Asosoiy qisim


oSeries.XValues = oWS.get_Range("A2", "A6")


Download 0.76 Mb.
bet14/14
Sana28.12.2022
Hajmi0.76 Mb.
#1014407
1   ...   6   7   8   9   10   11   12   13   14
Bog'liq
8888 (Автосохраненный)

oSeries.XValues = oWS.get_Range("A2", "A6");
for( int iRet = 1; iRet <= iNumQtrs; iRet++)
{ oSeries = (Excel.Series)oChart.SeriesCollection(iRet);
String seriesName;
seriesName = "=\"Q";
seriesName = String.Concat( seriesName, iRet );
seriesName = String.Concat( seriesName, "\"" );
oSeries.Name = seriesName; }
oChart.Location( Excel.XlChartLocation.xlLocationAsObject, oWS.Name );
//Move the chart so as not to cover your data.
oResizeRange = (Excel.Range)oWS.Rows.get_Item(10, Missing.Value ); oWS.Shapes.Item("Chart 1").Top = (float)(double)oResizeRange.Top;
oResizeRange = (Excel.Range)oWS.Columns.get_Item(2, Missing.Value ); oWS.Shapes.Item("Chart 1").Left = (float)(double)oResizeRange.Left; }
Kod oynasining yuqori qismiga o'ting. Foydalanish direktivalari ro'yxatining oxiriga quyidagi qatorni qo'shing:
C#
using Excel = Microsoft.Office.Interop.Excel; using System.Reflection;
Avtomatlashtirish mijozini sinab ko'ring
Dasturni yaratish va ishga tushirish uchun F5 tugmasini bosing.
Shaklda 1 tugmachasini bosing. Dastur Excelni ishga tushiradi va ma'lumotlarni yangi ish varag'iga to'ldiradi.
Sizdan choraklik savdo ma'lumotlarini kiritish so'ralganda, Ha ni bosing. Ish varag'iga choraklik ma'lumotlar bilan bog'langan diagramma qo'shiladi.
Xulosa

Foydalanilgan adabiyotlar ro’yxati
Download 0.76 Mb.

Do'stlaringiz bilan baham:
1   ...   6   7   8   9   10   11   12   13   14




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling