CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums
Results 1 to 2 of 2

Thread: Display Icons

  1. #1
    Join Date
    Dec 2000

    Display Icons

    How is it possible to create a control that can be used to display a sequence of icons, where the path to the icons is to be specified at run-time?

  2. #2
    Join Date
    May 2000
    Toronto, ON, Canada

    Re: Display Icons


    The control already exist. That if you want to use CStatic control. It has a member function SetIcon. All you have to do is to set it's property to icon from resource. For that use the "Picture" control from resource and set it's icon property from "General" tab, and at "Type" choose "Icon". Or, if you create it dymanically use SS_ICON as parameter in Create function.
    Now for changing at run time use LoadImage function to obtain a handle to a icon from file.

    Tell me if that help or if you need more info.



    Emanuel Vaduva

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