What Does : Dim Array() as String means and what Dim Array as String() Means?
If I pass a array to function like below:
As I pass a array to this function and some thing , it should add to it... but it doesn't add unless the object is
but it should works as
or anything
If I pass a array to function like below:
VB.NET:
Public Sub Array_AddSomething(ByVal strEntry As Object, ByRef strArray() As Object)
Try
Dim Upper As Integer
If strArray IsNot Nothing AndAlso strArray.Length > 0 Then
Upper = UBound(strArray)
ReDim Preserve strArray(0 To Upper + 1)
strArray(Upper + 1) = strEntry
Else
ReDim Preserve strArray(0)
strArray(0) = strEntry
End If
Catch ex As Exception
MsgBox("Please Contact with your vendor or developer. Some internal error from array passing.", MsgBoxStyle.Critical, "Array Value Adding")
End Try
End Sub
As I pass a array to this function and some thing , it should add to it... but it doesn't add unless the object is
VB.NET:
Dim str() as object
but it should works as
VB.NET:
Dim str() as string