01.
Dim
m
As
Integer
= 0
02.
Dim
n
As
Integer
= 23
03.
Dim
func
As
String
04.
Dim
number3
As
String
05.
Dim
expect3
As
Double
06.
Dim
have3
As
Double
07.
Dim
persen3
As
String
08.
For
m = 0
To
GridView3.Rows.Count - 1
09.
number3 =
CStr
(m + 1)
10.
func = GridView3.Rows(m).Cells(2).Text
11.
expect3 =
CDbl
(GridView3.Rows(m).Cells(3).Text)
12.
have3 =
CDbl
(GridView3.Rows(m).Cells(4).Text)
13.
persen3 = GridView3.Rows(m).Cells(6).Text
14.
15.
16.
.Range(
"A"
& n.ToString()).Value = number3 +
"."
+ func
17.
.Range(
"A"
& n.ToString()).HorizontalAlignment = Excel.XlHAlign.xlHAlignLeft
18.
19.
.Range(
"G"
& n.ToString()).Value = expect3
20.
.Range(
"G"
& n.ToString()).HorizontalAlignment = Excel.XlHAlign.xlHAlignRight
21.
22.
.Range(
"H"
& n.ToString()).Value = have3
23.
.Range(
"H"
& n.ToString()).HorizontalAlignment = Excel.XlHAlign.xlHAlignRight
24.
25.
.Range(
"I"
& n.ToString()).Value = persen3
26.
.Range(
"I"
& n.ToString()).HorizontalAlignment = Excel.XlHAlign.xlHAlignRight
27.
28.
29.
n += 1
30.
Next
31.
chartRange = ExcelSheets.Range(
"A4"
,
"F"
&
CDbl
(j.ToString()) - 1)
32.
chartRange.BorderAround(Excel.XlLineStyle.xlContinuous, _
33.
Excel.XlBorderWeight.xlThin, Excel.XlColorIndex. _
34.
xlColorIndexAutomatic, Excel.XlColorIndex.xlColorIndexAutomatic)
35.
36.
chartRange = ExcelSheets.Range(
"G4"
,
"G"
&
CDbl
(j.ToString()) - 1)
37.
chartRange.BorderAround(Excel.XlLineStyle.xlContinuous, _
38.
Excel.XlBorderWeight.xlThin, Excel.XlColorIndex. _
39.
xlColorIndexAutomatic, Excel.XlColorIndex.xlColorIndexAutomatic)
40.
41.
chartRange = ExcelSheets.Range(
"H4"
,
"H"
&
CDbl
(j.ToString()) - 1)
42.
chartRange.BorderAround(Excel.XlLineStyle.xlContinuous, _
43.
Excel.XlBorderWeight.xlThin, Excel.XlColorIndex. _
44.
xlColorIndexAutomatic, Excel.XlColorIndex.xlColorIndexAutomatic)
45.
46.
chartRange = ExcelSheets.Range(
"I4"
,
"I"
&
CDbl
(j.ToString()) - 1)
47.
chartRange.BorderAround(Excel.XlLineStyle.xlContinuous, _
48.
Excel.XlBorderWeight.xlThin, Excel.XlColorIndex. _
49.
xlColorIndexAutomatic, Excel.XlColorIndex.xlColorIndexAutomatic)