Results 1 to 2 of 2

Thread: .NET is driving me .NUTS

  1. #1

    Thread Starter
    Lively Member Radar's Avatar
    Join Date
    Apr 2001
    Posts
    70

    Angry .NET is driving me .NUTS

    Is it just me or is .NET missing alot of useful properties in its intrinsic controls as compared to VB. For example, I can't seem to find a replacement for the PaintPicture method for the .NET picturebox. Also no AutoRedraw property. or ScaleMode for custom scales. I know that some of these can be overcome with API calls, but they are still quite handy. Any thoughts?
    Aww screw it. I didn't really want to fool with it anymore anyhow.

  2. #2
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649
    No you will sertanly not found any of those method you've mentioned.
    There is also no Line, PSet, Scale or Circle functions.
    All graphic function have been rewritten for VB.Net.
    So forget everything you know about graphic output, including most of what you know about working with bitmaps.

    You mentioned the API. If you are accustomed to using Win32 API calls for graphic operation then forget everything you know ...
    Just kidding!!
    You're actually in luck, 'cause you'll be able to get up to speed very quickly with the new graphic environment.

    To load bitmaps you use the System.Drawing.Bitmap object.
    VB Code:
    1. Dim bm As New System.Drawing.Bitmap("c:\winnt\zapotec.bmp")
    2. Dim g As Graphics = Graphics.FromHwnd(PictureBox1.Handle)
    3.  
    4. g.DrawImage(bm, 0, 0)
    5. g.Dispose() 'dispose the objects
    6. bm.Dispose()
    Best regards

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width