'Не могу разобраться javascript:AddSmileyIcon('
'), должно работать!!! Выдаёт пустой список. Пробовал различные варианты реализации.
Private Sub BtnCreateStreetList_Click()
Dim pMxDocument As IMxDocument
Dim pQueryFilter As IQueryFilter
Dim pRow As IRow
Dim pCursor As ICursor
Dim StreetName As String
Dim pTable As ITable
Dim pTableSort As ITableSort
Dim FieldIn As Integer
Set pTable = FindLayerbyName(CmbBxLayer.Text)
FieldIn = pTable.FindField("STR_NAME")
Set pQueryFilter = New QueryFilter
pQueryFilter.SubFields = "DISTINCT (STR_NAME)"
Set pTableSort = New TableSort
With pTableSort
.Fields = "STR_NAME"
.Ascending("STR_NAME") = True
Set .QueryFilter = pQueryFilter
Set .Table = pTable
End With
pTableSort.Sort Nothing
Set pCursor = pTableSort.Rows
Set pRow = pCursor.NextRow
Do While Not pRow Is Nothing
If Not IsEmpty(pRow.Value(FieldIn)) And pRow.Value(FieldIn) <> nul Then
CBxStreets.AddItem pRow.Value(FieldIn)
End If
Set pRow = pCursor.NextRow
Loop
End Sub