Results 1 to 5 of 5

Thread: VB Form Skin DPI BUG!!! Advanced users only

  1. #1

    Thread Starter
    New Member
    Join Date
    May 2000
    Posts
    8

    VB Form Skin DPI BUG!!! Advanced users only

    When you place a picture ona vb form then change the dpi on your computer after the program is compiled the form changes size but the picuter on the form stays the same and looks out of place and size is worng etc, anyone know of a way to stretch the picture int he form, i dont wnat to use anything in stead of the form (ie piture box image) just need some code, i have looked everywhere for this but found nothing

    Help please




    -=XPS=-

  2. #2
    Retired VBF Adm1nistrator plenderj's Avatar
    Join Date
    Jan 2001
    Location
    Dublin, Ireland
    Posts
    10,359
    When you're loading the app, create a DC for the picture and then Blit into the picturebox.
    Then if the user changes the resolution, StretchBlt the picture into the picturebox.
    Microsoft MVP : Visual Developer - Visual Basic [2004-2005]

  3. #3

    Thread Starter
    New Member
    Join Date
    May 2000
    Posts
    8
    Sorry dude blt etc etc you lost me on DC

    ICQ me 40910963
    Or leave some code as I have no idea wot that was about.


    Thanks anywayz tho

    -=XPS=-

  4. #4
    Retired VBF Adm1nistrator plenderj's Avatar
    Join Date
    Jan 2001
    Location
    Dublin, Ireland
    Posts
    10,359
    Hmm mail me [email protected] with a link to this thread and Ill post the code a little later. Bit busy right now.
    Microsoft MVP : Visual Developer - Visual Basic [2004-2005]

  5. #5
    Retired VBF Adm1nistrator plenderj's Avatar
    Join Date
    Jan 2001
    Location
    Dublin, Ireland
    Posts
    10,359
    Just in case anyone is searching the forums, here's the code for making a borderless picturebox that loads a picture into a device context and uses StretchBlt to blit an image into it etc.
    Attached Files Attached Files
    Microsoft MVP : Visual Developer - Visual Basic [2004-2005]

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