Message 1 of 3
Setting an Initial listbox value
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi,
Im trying to set an the default selected value of a listbox to "Model". The code highlights "Model" but the .Value and .Text properties remain blank. How do I set these to = "Model". If I select it manually it works.
LBO_Layout.AddItem ("Model")
LBO_Layout.AddItem ("Active")
Dim layout As AcadLayout
Dim layouts As AcadLayouts
Set layouts = ThisDrawing.layouts
For Each layout In layouts
If (Not (layout.Name = "Model")) Then
LBO_Layout.AddItem (layout.Name)
End If
Next layout
LBO_Layout.Text = "Model"
Thanks
Im trying to set an the default selected value of a listbox to "Model". The code highlights "Model" but the .Value and .Text properties remain blank. How do I set these to = "Model". If I select it manually it works.
LBO_Layout.AddItem ("Model")
LBO_Layout.AddItem ("Active")
Dim layout As AcadLayout
Dim layouts As AcadLayouts
Set layouts = ThisDrawing.layouts
For Each layout In layouts
If (Not (layout.Name = "Model")) Then
LBO_Layout.AddItem (layout.Name)
End If
Next layout
LBO_Layout.Text = "Model"
Thanks