![]() |
![]() |
![]() |
|
![]() |
#1 |
Novato ![]() Ingreso: agosto-2009
Mensajes: 36
Sexo: ![]()
Agradecido: +89
|
![]()
bueno ya que no veo nada de Visual Basic Studio pondre algunos tips para los que empiesan.
Su tu tienes tambien algon tips de [VB6] as un post en este tema para tener todos los tips juntos... los subire todos arriba bien ordenados. Y disculpan me espanol qes que soy aleman, pero me gusta mucho esta pajina,asi que le ayudo un poquito con lo que saber..^^, have fun!! poco a poco voy poniendo mas si ay interes ;-) Me dare esfuerzo en escribir correctamente pero si no comprende algo pregunta Centrar una ventana en Visual Basic: Código:
Move (Screen.Width - Width) \ 2, (Screen.Height - Height) \ 2 En ves de: Form1.Left = Screen.Width - Width \ 2 Form1.Top = Screen.Height - Height \ 2 Übersetzung: Deutsch » Spanisch In ListBox Eintrag suchen und löschen Ponga en un formulario de un ListBox, un TextBox y un ComandButtonund una oportunidad con este código: Código:
Option Explicit Private Sub Form_Load() ' Liste (List1) mit Werten füllen 'genera nombres en el List1 Dim i As Integer For i = 1 To 10 List1.AddItem "Eintrag " & CStr(i) Next i End Sub Private Sub Command1_Click() Dim i As Integer Dim sText As String ' der Variable sText Inhalt der TextBox zuweisen sText = Text1.Text ' ListBox durchsuchen und ... For i = 0 To List1.ListCount - 1 If List1.List(i) = sText Then ' ... falls gefunden Eintrag löschen List1.RemoveItem i Exit For End If Next i End Sub Übersetzung: Deutsch » Spanisch In ListBox Eintrag suchen und löschen iniciar un nuevo proyecto al que se pone un cuadro de lista y un botón de comando. Pegue el siguiente código: Código:
Private Sub Form_Load() List1.AddItem "Eintrag 1" List1.AddItem "Eintrag 2" List1.AddItem "Eintrag 3" List1.AddItem "Eintrag 4" List1.AddItem "Eintrag 5" End Sub Private Sub Command1_Click() ' neuen Eintrag hinzufügen List1.AddItem "... und noch ein Eintrag" With List1 If .ListCount < 0 Then ' mittels ListIndex den letzten Eintrag auswählen .ListIndex = .ListCount - 1 ' den letzten Eintrag nicht markiert darstellen .Selected(.ListIndex) = False End If End With End Sub Crear un proyecto nuevo y escribir el código siguiente: Código:
Private Sub Form_Resize() Form1.Cls Form1.AutoRedraw = True Form1.DrawStyle = 6 Form1.DrawMode = 13 Form1.DrawWidth = 2 Form1.ScaleMode = 3 Form1.ScaleHeight = (256 * 2) For i = 0 To 255 Form1.Line (0, Y)-(Form1.Width, Y + 2), RGB(0, 0, i), BF Y = Y + 2 Next i End Sub Última edición por tito.; 28-ago-2009 a las 17:06 |
![]() |
![]() |
![]() |
#2 |
![]() Ingreso: diciembre-2009
Mensajes: 3
Sexo: ![]()
Agradecido: +18
|
![]()
Gracias por aportar, me gusta la idea, por aqui tengo algunas rutinas que pueden servir, deja veo de que manera puede ser mejor para compartirlas, si escribiendo el codigo asi o pasando el proyecto, saludos.
|
![]() |
![]() |
(0 miembros y 1 visitantes) | |
|
|
![]() |
||||
Tema | Autor | Foro | Respuestas | Último mensaje |
Programación con Visual Basic .NET en Visual Studio 2005 VideoTutoriales.es | rix180 | Programación | 29 | 28-jul-2011 02:14 |
Visual Basic + Microsof Acce Ayuda.. | VeneZolaniTo | Peticiones | 8 | 27-oct-2010 01:15 |
VideoTutorial Visual Basic 6.0 | polin | Programación | 9 | 08-jun-2010 12:37 |
Busco Cursos Completos de programacion en Java y Visual Basic | djthreem | Peticiones | 3 | 20-abr-2010 20:38 |