El Guru Programador
Usuario DESCONOCIDO | Registrate Gratis | Usuarios Registrados
Foro de Visual Basic/VB.NET
Foros del Guru > Visual Basic/VB.NET
Usuario necesito ayuda urgente
Desconocido
Enviado - 17/5/2003
 
tengo un problema el lunes tengo que entregar mi tarea de visualbasic me dejaron crear unas graficas de barras de lineas y de pastel la de pastel no se como hacerla pero le damos cinco valores de los cuales se deben de graficar. tengo lo siguiente
Dim a As Integer
Dim b As Integer
Dim c As Integer
Dim d As Integer
Dim e As Integer
Dim f As Integer

Private Sub Command1_Click()
Line30.Y2 = 4200
Line30.Y1 = 4200
Line31.Y2 = 4200
Line31.Y1 = 4200
Line32.Y2 = 4200
Line32.Y1 = 4200
Line33.Y2 = 4200
Line33.Y1 = 4200
Line34.Y2 = 4200
Line34.Y1 = 4200

a = Text1.Text
Line30.Y2 = Line30.Y2 - (a * 200)
b = Text2.Text
Line31.Y2 = Line31.Y2 - (b * 200)
c = Text3.Text
Line32.Y2 = Line32.Y2 - (c * 200)
d = Text4.Text
Line33.Y2 = Line33.Y2 - (d * 200)
e = Text5.Text
Line34.Y2 = Line34.Y2 - (e * 200)
Shape1.Height = 15
Shape1.Top = 4320
Shape2.Height = 15
Shape2.Top = 4320
Shape3.Height = 15
Shape3.Top = 4320
Shape4.Height = 15
Shape4.Top = 4320
Shape5.Height = 15
Shape5.Top = 4320
Shape1.Height = Shape1.Height + (a * 200)
Shape1.Top = Shape1.Top - (a * 200)
a = Shape1
Shape2.Height = Shape2.Height + (b * 200)
Shape2.Top = Shape2.Top - (b * 200)
b = Shape2
Shape3.Height = Shape3.Height + (c * 200)
Shape3.Top = Shape3.Top - (c * 200)
c = Shape3
Shape4.Height = Shape4.Height + (d * 200)
Shape4.Top = Shape4.Top - (d * 200)
d = Shape4
Shape5.Height = Shape5.Height + (e * 200)
Shape5.Top = Shape5.Top - (e * 200)
e = Shape5


End Sub
Private Sub Command2_Click()
End
End Sub

Private Sub Command3_Click()
Line30.Y2 = 4200
Line30.Y1 = 4200
Line31.Y2 = 4200
Line31.Y1 = 4200
Line32.Y2 = 4200
Line32.Y1 = 4200
Line33.Y2 = 4200
Line33.Y1 = 4200
Line34.Y2 = 4200
Line34.Y1 = 4200

Text1.Text = ""
Text2.Text = ""
Text3.Text = ""
Text4.Text = ""
Text5.Text = ""

Shape1.Height = 15
Shape1.Top = 4320
Shape2.Height = 15
Shape2.Top = 4320
Shape3.Height = 15
Shape3.Top = 4320
Shape4.Height = 15
Shape4.Top = 4320
Shape5.Height = 15
Shape5.Top = 4320
End Sub

please mi mail es [email protected]
 
fmarredo
355 Mensaje(s)
Enviado - 19/5/2003
 
Para gráficos te recomendaría usar el control MSChart. Fijate en la ayuda de VB que vas a encontrar ejemplos.
 
 

 

Contactos myStudio Network