473,385 Members | 1,353 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

forms application in vc++.net doubt

Hi,

I am new to VC dot net.

I shall be thakful if you can reply one of my query.
how to change the size of images in imagelist in listview control
vc++.net(forms application).

Thanks and Regards,
Sanjeev
Nov 17 '05 #1
1 1140
Hi !

I'm assuming you're using .NET Framework, because you're using Windows
Forms. In that case, a ListView class has three properties called
LargeImageList, SmallImageList and StateImageList, each related to a
specific display mode of the ListView.

Each of these properties is an ImageList class. This class has ImageSize
property (type Size), that determines the size of the images in this image
collection. Changing this parameter determines the size of the images in the
list. Know that the images themselves are located in ImageList::Images
property, which is of ImageList::ImageCollection type.

Code examples are always the best, so here you go. This is a C++/CLI
example, because that language is much more flexible with .NET Framework
than Managed C++. The only thing this affects in the sample code is the
creation process of the System::Drawing::Size object. In Managed C++, this
is done in a different manner.

<code snip>

MyListView->SmallImageList->ImageSize = gcnew System::Drawing::Size( 200,
200 ); // Sets small image size to 200, 200
MyListView->LargeImageList->ImageSize = gcnew System::Drawing::Size(100,
100); // Sets large image size to 100, 100

</code snip>

Hope this helps

-Antti Keskinen
"Sanjeeva Reddy" <sanjeeva.reddy at yahoo no mail.com> wrote in message
news:ej**************@TK2MSFTNGP10.phx.gbl...
Hi,

I am new to VC dot net.

I shall be thakful if you can reply one of my query.
how to change the size of images in imagelist in listview control
vc++.net(forms application).

Thanks and Regards,
Sanjeev

Nov 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: David Battams | last post by:
Hi there, Quick question about VC.Net forms. The second I add a picture pox with associated image to my form, my app goes off into the weeds in the form designer code at the line where it...
1
by: Microsoft | last post by:
Hi, I am newbie for Visual studio .Net. I had .Net 2002 installed on my system. Now I have installed .Net 2003 under the pretext that Windows forms would be available for use in VC.Net. But in...
1
by: Sanjeeva Reddy | last post by:
Hai, I am using vc++,net(Windows Forms application). I am able to open image on form. And i am able to draw a shape(line) on the image. Please tell me how to save this image along with the shape...
11
by: Paul Tremblay | last post by:
Hi, I can't seem to locate the visual C++ (pre .NET) ng. This may be slight off topic here - please point me to the correct ng if it is. Without going into much detail (and repeating myself...
20
by: Peter Oliphant | last post by:
How does one launch multiple forms in an application? Using Photoshop as an example, this application seems to be composed of many 'disjoint' forms. Yet, they all seem somewhat 'active' in...
2
by: James Walker | last post by:
I am an experienced c++ programmer and I have done most of my c++ programming with .net as console or directx programs. I want to learn windows programming and make quality applications going...
3
by: Neal | last post by:
managed C++ VS 2003 I have a beginner question about windows forms.... I need to call a function when a certain limit has been reached, now with the way VS sets up the .NET windows Form I get...
14
by: John | last post by:
My friend told me that his company will migrate the VC++ win32 applications to C++ .NET windows applications. I don't understand why since currently Microsoft only supports .NET on windows...
11
by: miles.jg | last post by:
Have a application (custom written for a vetical market) which has been developed in VB over the last several years. Now that MS has done what MS does best and is to relegated VB to the twilight...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.