begin process at 2008 05 16 09:42:14
1 173 261 membres
101 nouveaux aujourd'hui
13 970 membres club

Vous ne trouvez pas de réponse à votre problème ? Alors posez la question dans le forum.
Souvenez-vous qu'il n'y a jamais de question bête, mais rester dans l'ignorance parce que l'on n'ose pas poser une question, ça c'est une erreur !

TRACER UN RECTANGLE OU UN CERCLE SUR POCKETPC 2002 AVEC .NET


Information sur la source

Catégorie :PPC :: Graphisme Source .NET ( DotNet ) Classé sous : tracer, dessiner, rectangle, cercle, dessin Niveau : Débutant Date de création : 26/05/2003 Date de mise à jour : 26/05/2003 16:19:01 Vu / téléchargé: 13 937 / 297

Note :
5,5 / 10 - par 2 personnes
5,50 / 10

  • 1

  • 2

  • 3

  • 4

  • 5

  • 6

  • 7

  • 8

  • 9

  • 10

Commentaire sur cette source (0)
Ajouter un commentaire et/ou une note


Description

Voici un petit exemple que je viens de faire, c'est la 1ère fois que je touche au compact Framework (j'ai pas de pocketPC... Mais rien n'est perdu mon anniversaire approche à ce qu'il parait :-p)
Donc pour l'occasion du lancement de pdafr.com j'ai essayé de faire mumuse avec le compact Framework.
C'est un régal vivement que je m'achète un PocketPC :-p
Cet exemple vous montre en Quelques lignes comment tracer un Rectangle plein ou un cercle plein dans un PictureBox
Langage utilisé : VB.NET
IDE : VS.NET 2003 Framework 1.1  

Source

  • Private Sub BtnRectangle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnRectangle.Click
  • Dim objBitMap As New Bitmap(PictureBox1.Width, PictureBox1.Height)
  • Dim objGraphics As Graphics
  • Dim MonRectable As Rectangle
  • Dim MaBrush As Brush
  • objGraphics = Graphics.FromImage(objBitMap)
  • MonRectable = New Rectangle(10, 10, 100, 100)
  • MaBrush = New SolidBrush(Color.Blue)
  • objGraphics.Clear(Color.White)
  • objGraphics.FillRectangle(MaBrush, MonRectable)
  • Me.PictureBox1.Image = objBitMap
  • objGraphics.Dispose()
  • objGraphics = Nothing
  • End Sub
  • Private Sub BtnCercle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnCercle.Click
  • Dim objBitMap As New Bitmap(PictureBox1.Width, PictureBox1.Height)
  • Dim objGraphics As Graphics
  • Dim MonRectable As Rectangle
  • Dim MaBrush As Brush
  • objGraphics = Graphics.FromImage(objBitMap)
  • MonRectable = New Rectangle(10, 10, 100, 100)
  • MaBrush = New SolidBrush(Color.Blue)
  • objGraphics.Clear(Color.White)
  • objGraphics.FillEllipse(MaBrush, MonRectable)
  • Me.PictureBox1.Image = objBitMap
  • objGraphics.Dispose()
  • objGraphics = Nothing
  • End Sub
    Private Sub BtnRectangle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnRectangle.Click
        Dim objBitMap As New Bitmap(PictureBox1.Width, PictureBox1.Height)
        Dim objGraphics As Graphics
        Dim MonRectable As Rectangle
        Dim MaBrush As Brush

        objGraphics = Graphics.FromImage(objBitMap)
        MonRectable = New Rectangle(10, 10, 100, 100)
        MaBrush = New SolidBrush(Color.Blue)
        objGraphics.Clear(Color.White)
        objGraphics.FillRectangle(MaBrush, MonRectable)
        Me.PictureBox1.Image = objBitMap
        objGraphics.Dispose()
        objGraphics = Nothing
    End Sub

    Private Sub BtnCercle_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BtnCercle.Click
        Dim objBitMap As New Bitmap(PictureBox1.Width, PictureBox1.Height)
        Dim objGraphics As Graphics
        Dim MonRectable As Rectangle
        Dim MaBrush As Brush

        objGraphics = Graphics.FromImage(objBitMap)
        MonRectable = New Rectangle(10, 10, 100, 100)
        MaBrush = New SolidBrush(Color.Blue)
        objGraphics.Clear(Color.White)
        objGraphics.FillEllipse(MaBrush, MonRectable)
        Me.PictureBox1.Image = objBitMap
        objGraphics.Dispose()
        objGraphics = Nothing
    End Sub
  

Conclusion

Voilà, c'est simple non ?  
Pour les "Membres Club", vous pouvez télécharger directement un fichier contenu dans le zip sans télécharger le zip en entier !

Télécharger le zip

    Aucun commentaire pour le moment.

Ajouter un commentaire

Appels d'offres

Pub



CalendriCode

Mai 2008
LMMJVSD
   1234
567891011
12131415161718
19202122232425
262728293031 

VS Express FR Gratuit !

VS Express en français et 100% gratuit !

Téléchargements

Logiciels à télécharger sur le même thème :

Boutique

Boutique de goodies CodeS-SourceS