Click here to Skip to main content
15,891,513 members
Home / Discussions / C#
   

C#

 
Questionquestion about webviewer control Pin
tonyonlinux26-Feb-10 12:46
tonyonlinux26-Feb-10 12:46 
AnswerRe: question about webviewer control Pin
AspDotNetDev26-Feb-10 13:18
protectorAspDotNetDev26-Feb-10 13:18 
GeneralRe: question about webviewer control Pin
tonyonlinux26-Feb-10 18:21
tonyonlinux26-Feb-10 18:21 
QuestionOpenSSL.NET Tutorial? [modified] Pin
Kiotaya26-Feb-10 11:13
Kiotaya26-Feb-10 11:13 
AnswerRe: OpenSSL.NET Tutorial? Pin
carlecomm27-Feb-10 0:10
carlecomm27-Feb-10 0:10 
GeneralRe: OpenSSL.NET Tutorial? Pin
Kiotaya2-Mar-10 13:20
Kiotaya2-Mar-10 13:20 
GeneralRe: OpenSSL.NET Tutorial? Pin
Kiotaya2-Mar-10 13:27
Kiotaya2-Mar-10 13:27 
QuestionPoor thumbnail quality when using listview Pin
Eagle3226-Feb-10 9:36
Eagle3226-Feb-10 9:36 
Hi,

I am having an issue regarding the thumbnail quality and image size. I am using ImageList and ListView to display the images. The problem occurs when i try to create the image from the filepath or from a memorystream object. The quality appears to be blurry.

I did set the quality to "Depth.32Bit". But this still hasnt solve the problem.

I also want to maintain the aspect ratio of the ImageSize dynamically if possible?

Can anyone help kindly me please regarding the above requests/issues?

Here is the code i created behind a datagridview click event.
this.StaffListView.View = View.LargeIcon;
            this.StaffListView.LargeImageList = StaffImageList;
            StaffImageList.ImageSize = new Size(120, 120);
            StaffImageList.ColorDepth = ColorDepth.Depth32Bit;

            int pos = StaffDataGridView.CurrentRow.Index;
            try
            {
                if (File.Exists(StaffDataGridView.Rows[pos].Cells[1].Value.ToString()))
                {
                    byte[] ImageD = (byte[])StaffDataGridView.Rows[pos].Cells[2].Value;
                    String RfilePath = StaffsDataGridView.Rows[pos].Cells[1].Value.ToString();

                    MemoryStream memStream = new MemoryStream(ImageD);
                    Image image = Image.FromStream(memStream, true);
                    string filename = fileNameExtractor(RfilePath);
                    StaffImageList.Images.Add(RfilePath, image);
                    StaffListView.Items.Add(filename, RfilePath);

                }
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message.ToString());
            }


I also tried not to use the thumbnail thats in the database by creating a thumbnail image from scratch by using an overidden thumbnail method to create a thumbnail and then add that thumbnail to the ListView. This was to check if the problem is with the image in the database but thats where i am having difficulty identifying the where the issue is actually occuring.

I would appreciate if you could get back to me please?

Thanks,
AnswerRe: Poor thumbnail quality when using listview Pin
Luc Pattyn26-Feb-10 10:13
sitebuilderLuc Pattyn26-Feb-10 10:13 
GeneralRe: Poor thumbnail quality when using listview Pin
Eagle3226-Feb-10 11:38
Eagle3226-Feb-10 11:38 
AnswerRe: Poor thumbnail quality when using listview [modified] Pin
Luc Pattyn26-Feb-10 12:20
sitebuilderLuc Pattyn26-Feb-10 12:20 
GeneralRe: Poor thumbnail quality when using listview Pin
Eagle3227-Feb-10 0:24
Eagle3227-Feb-10 0:24 
GeneralRe: Poor thumbnail quality when using listview Pin
Luc Pattyn27-Feb-10 0:37
sitebuilderLuc Pattyn27-Feb-10 0:37 
GeneralRe: Poor thumbnail quality when using listview Pin
Eagle3227-Feb-10 6:44
Eagle3227-Feb-10 6:44 
GeneralRe: Poor thumbnail quality when using listview Pin
Luc Pattyn27-Feb-10 7:40
sitebuilderLuc Pattyn27-Feb-10 7:40 
GeneralRe: Poor thumbnail quality when using listview Pin
Eagle3227-Feb-10 7:59
Eagle3227-Feb-10 7:59 
GeneralRe: Poor thumbnail quality when using listview Pin
Luc Pattyn27-Feb-10 8:14
sitebuilderLuc Pattyn27-Feb-10 8:14 
GeneralRe: Poor thumbnail quality when using listview Pin
Eagle325-Mar-10 10:08
Eagle325-Mar-10 10:08 
AnswerRe: Poor thumbnail quality when using listview Pin
Luc Pattyn26-Feb-10 12:53
sitebuilderLuc Pattyn26-Feb-10 12:53 
Questionhow to create a cookie with C# ??? Pin
andyxfun26-Feb-10 8:37
andyxfun26-Feb-10 8:37 
AnswerRe: how to create a cookie with C# ??? Pin
Saksida Bojan26-Feb-10 8:56
Saksida Bojan26-Feb-10 8:56 
Questionvoice chat in windows mobile 6 Pin
Rodinho26-Feb-10 7:53
Rodinho26-Feb-10 7:53 
AnswerRe: voice chat in windows mobile 6 Pin
Dr.Walt Fair, PE26-Feb-10 8:46
professionalDr.Walt Fair, PE26-Feb-10 8:46 
GeneralRe: voice chat in windows mobile 6 Pin
Wes Aday26-Feb-10 9:03
professionalWes Aday26-Feb-10 9:03 
AnswerRe: voice chat in windows mobile 6 Pin
rioshzhao23-Sep-10 20:02
rioshzhao23-Sep-10 20:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.