Image Edit Control


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2

Thread: Image Edit Control

  1. #1
    Sinni Guest

    Image Edit Control


    I have an Image edit control in my form and I am trying to display different
    images, which is in the “tiff” file format into this control. All images
    are in different height & width. How do I adjust the Height & Width of the
    Image Edit Control in order to display the images with different size?
    I have the code like this:

    ImgEdit1.Height = ImgEdit1.ImageHeight
    ImgEdit1.Width = ImgEdit1.ImageWidth
    ImgEdit1.Zoom = 50
    ImgEdit1.Display

    But the size of the control is not changing exactly as the size of the image
    displayed.
    Please help me.

    Thanks,
    Sinni.


  2. #2
    dnagel Guest

    Re: Image Edit Control

    It's been a while since I worked with this one...

    My recollection was that all the images in the list
    could be any size, but would all display at the same
    size if you are binding them to another Windows Common
    Control...

    Heres the text from microsoft... (Second controls refers
    to the 'client' of the imagelist control...)


    You can insert any size image into the ImageList control. However, the size of the image displayed by the second control
    depends on one factor: whether or not the second control is also a Windows Common control bound to the ImageList
    control.

    When the ImageList control is bound to another Windows Common Control, images of different sizes can be added to the
    control, however the size of the image displayed in the associated Windows Common Control will be constrained to the
    size of the first image added to the ImageList. For example, if you add an image that is 16 by 16 pixels to an ImageList
    control, then bind the ImageList to a TreeView control (to be displayed with Node objects), all images stored in the
    ImageList control will be displayed at 16 by 16 pixels, even if they are much larger or smaller.

    On the other hand, if you display images using the Picture object, any image stored in the ImageList control will be
    displayed at its original size, no matter how small or large.



    So, basically, don't bind the imagelist to any control and set
    the pictures in the client control yourself.

    D.



    "Sinni" <ts2n@yahoo.com> wrote in message news:3e678e35$1@tnews.web.devx.com...
    >
    > I have an Image edit control in my form and I am trying to display different
    > images, which is in the “tiff” file format into this control. All images
    > are in different height & width. How do I adjust the Height & Width of the
    > Image Edit Control in order to display the images with different size?
    > I have the code like this:
    >
    > ImgEdit1.Height = ImgEdit1.ImageHeight
    > ImgEdit1.Width = ImgEdit1.ImageWidth
    > ImgEdit1.Zoom = 50
    > ImgEdit1.Display
    >
    > But the size of the control is not changing exactly as the size of the image
    > displayed.
    > Please help me.
    >
    > Thanks,
    > Sinni.
    >




Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center