Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Problem with the PictureBox Control: Please Help

Problem with the PictureBox Control: Please Help

Scheduled Pinned Locked Moved C#
helpquestion
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • E Offline
    E Offline
    E6AD
    wrote on last edited by
    #1

    Hi, Can someone please tell me how can I zoom in and out of an image that is displayed in a picture box control??? Please Help... Thanks, E.A.

    C M 2 Replies Last reply
    0
    • E E6AD

      Hi, Can someone please tell me how can I zoom in and out of an image that is displayed in a picture box control??? Please Help... Thanks, E.A.

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      You can't. So many people seem to think a picture box control should be a full featured image viewer, and it's not. It's for showing a picture. If you want to do anything more, you'll have to write the code yourself. I prefer to put a panel on my form and use it to work out the bounds to draw my own images for this very reason, it means I have full control. The Graphics.DrawImage method has a number of overloads, and all are designed to be able to zoom into an area of an image and/or draw only part of the image. Christian Graus - Microsoft MVP - C++

      1 Reply Last reply
      0
      • E E6AD

        Hi, Can someone please tell me how can I zoom in and out of an image that is displayed in a picture box control??? Please Help... Thanks, E.A.

        M Offline
        M Offline
        Marc 0
        wrote on last edited by
        #3

        Yup, ehat Christian said. Or you can use the search function of Codeproject ;): PictureBox with zooming and scrolling[^]. Pompiedompiedom... ;)


        "..Commit yourself to quality from day one..it's better to do nothing at all than to do something badly.." -- Mark McCormick

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups