etoy intentando pasarle una colecion de botones a una funcion, est e es el codigo:
Private Function bot_mover(b As Collection, ByVal rsc As Recordset, index As Integer) As Boolean
Select Case index
Case "0"
rsc.MoveFirst
Case "1"
If Not rsc.BOF Then rsc.MovePrevious
Case "2"
If Not rsc.EOF Then rsc.MoveNext
Case "3"
rsc.MoveLast
End Select
'If IsArray(b) Then
For contador = 0 To 4
If rsc.EOF = True Then
If b(contador).Tag = "Adelante" Then b(contador).Enabled = False Else b(contador).Enabled = True
Else
If rsc.BOF = True Then
If b(contador).Tag = "Atras" Then b(contador).Enabled = False Else b(contador).Enabled = True
Else
b(contador).Enabled = True
End If
End If
Next contador
'End If
bot_mover = True
End Function
al k se le llama asi:
bot_mover cmd_mover_admin, rspass, index
pero me falla no se en que al llamarlo, me da un type mistmatch
Muchas gracias atodos