Ver Mensaje Individual
  #4 (permalink)  
Antiguo 11/11/2005, 12:37
Avatar de David
David
Moderador
 
Fecha de Ingreso: abril-2005
Ubicación: In this planet
Mensajes: 15.720
Antigüedad: 20 años
Puntos: 839
De acuerdo

Cita:
Iniciado por vbx3m
pero puedes utilizar esto:

Dim command As Object
Private Sub Form_Load()
For Each command In Controls
If TypeOf command Is CommandButton Then
command.Picture = LoadPicture(ruta)
End If
Next
End Sub
Me gustó la forma como lo resolvísteis....
Vale, podríamos agregarle ésto:
Código:
 
Dim Imagen As IPicture
Set Imagen = LoadPicture("ruta")
For Each command In Controls
If TypeOf command Is CommandButton Then
if command.Tag = "PINTAR" Then
command.Picture = Imagen
End If
End If
Next
Así pues, en vés de pintar todos los botones, solo pinta los que tienen el Tag PINTAR, además, no tenemos que volver a cargar la Imagen las 200 veces...
__________________
Por favor, antes de preguntar, revisa la Guía para realizar preguntas.