Hi - I have problems in getting values of an ArrayList produced in an external library. This works in VB.NET but not in Basic4PPC.
My library in VB.NET exposes the following property:
Note: ResultSuggestions has been declared in a module in my library as an ArrayList as follows:
When I call ReturnSuggestions from a sample program in VB.NET which uses my library, everything is OK. This is how I call it:
However, calling it from Basic4PPC doesn't work. This is my code:
where "detect" is an instance previously initiated by using detect.new1.
If Basic4PPC recognized detect.ReturnSuggestions as an ArrayList, I guess that Basic4PPC's Intelisense would suggest methods such as "count" but it doesn't.
Any ideas?
It works in VB.NET but not in Basic4PPC. Perhaps I must add something specific to my library so it works with Basic4PPC?
Rgds,
moster67
My library in VB.NET exposes the following property:
B4X:
Public ReadOnly Property ReturnSuggestions() As ArrayList
Get
Return ResultSuggestions
End Get
End Property
Note: ResultSuggestions has been declared in a module in my library as an ArrayList as follows:
B4X:
Public ResultSuggestions As New ArrayList()
When I call ReturnSuggestions from a sample program in VB.NET which uses my library, everything is OK. This is how I call it:
B4X:
Private Sub CheckSuggestionsAvailable()
If CheckSpelling.ReturnSuggestions.Count > 0 Then
For i As Integer = 0 To CheckSpelling.ReturnSuggestions.Count - 1
ListBox1.Items.Add(CheckSpelling.ReturnSuggestions.Item(i).ToString.ToLower)
Next
End If
End Sub
However, calling it from Basic4PPC doesn't work. This is my code:
B4X:
If detect.ReturnSuggestions.count > 0 Then
For i =0 To detect.ReturnSuggestions.count - 1
listbox1.Add(StrToLower(detect.ReturnSuggestions.item(i)))
Next
End If
where "detect" is an instance previously initiated by using detect.new1.
If Basic4PPC recognized detect.ReturnSuggestions as an ArrayList, I guess that Basic4PPC's Intelisense would suggest methods such as "count" but it doesn't.
Any ideas?
It works in VB.NET but not in Basic4PPC. Perhaps I must add something specific to my library so it works with Basic4PPC?
Rgds,
moster67
Last edited: