0 Members and 1 Guest are viewing this topic.
I've got a DVB that I'm working on that I would like to use the Listview control. The problem is this: the number of listview controls depends on the number of particular objects in the drawing. I've tried Controls.Add("Forms.Listview.1") but that only gave me an 'Invalid class string' error message.Any takers?
Private Sub Command1_Click()Dim lvw As ListViewDim ctl As Control[b]Set ctl = Controls.Add("MSComctlLib.ListViewCtrl.2", "ListView1")[/b]With ctl.Left = 10.Top = 40.Height = 120.Width = 200.Visible = TrueEnd WithSet lvw = ctlWith lvw.ColumnHeaders.Add 1, "@", "Header1", 100.ColumnHeaders.Add 2, "#", "Header2", 100.GridLines = True.View = lvwReportEnd With'ETC'End Sub
Hi MattWhat I have a found in the registry (in the ROOT branch)
Set ctl = Controls.Add("MSComctlLib.ListViewCtrl.2", "ListView1")