sujittalukde
Well-known Member
- Joined
- Jun 2, 2007
- Messages
- 520
I am using the following code by a command button-
On initialization of User form, when I click the buttons it adds the column and data. Thereafter, if the command button is again clicked, it is adding the columns and data and not updating the already inserted columns and data.
How can I fix it?
Regards
Sujit
Code:
Private Sub CommandButton2_Click()
lvwWidth =ListView1.width
With Me.ListView1
.ListItems.Clear
.ColumnHeaders.Add , , "Fund Name", (lvwWidth * 0.7)
.ColumnHeaders.Add , , "NAV", (lvwWidth * 0.15), lvwColumnRight
.ColumnHeaders.Add , , "Code", (lvwWidth * 0.149), lvwColumnCenter
.View = lvwReport
.Gridlines = True
.FullRowSelect = True
.MultiSelect = False
.AllowColumnReorder = False
.LabelEdit = lvwAutomatic
End With
'ReadNAVfileforSummary
End Sub
End Sub
How can I fix it?
Regards
Sujit