Click here to Skip to main content
15,902,276 members
Home / Discussions / C#
   

C#

 
GeneralRe: Passing Values Pin
Michael P Butler10-Jul-04 0:28
Michael P Butler10-Jul-04 0:28 
GeneralIE Browser and IHTMLDocument2 Pin
brian hanf9-Jul-04 9:18
brian hanf9-Jul-04 9:18 
GeneralDisable windows shortcuts!?! Pin
QzRz9-Jul-04 7:46
QzRz9-Jul-04 7:46 
GeneralRe: Disable windows shortcuts!?! Pin
Dave Kreskowiak9-Jul-04 8:47
mveDave Kreskowiak9-Jul-04 8:47 
GeneralRe: Disable windows shortcuts!?! Pin
QzRz9-Jul-04 9:04
QzRz9-Jul-04 9:04 
Generalchange bitmap resolution Pin
kendao9-Jul-04 7:25
kendao9-Jul-04 7:25 
GeneralRe: change bitmap resolution Pin
Heath Stewart9-Jul-04 8:58
protectorHeath Stewart9-Jul-04 8:58 
GeneralRe: change bitmap resolution Pin
Werdna10-Jul-04 11:19
Werdna10-Jul-04 11:19 
I found that GetTumbnailImage doesn't do as good of a job resizing.
Here is some simple code that resized your image (but distorts if aspect ratio is different)
Bitmap resizeImage(Bitmap bmp, int width, int height)
{
Bitmap newBmp = new Bitmap(width, height);
Graphics g = Graphics.FromImage(newBmp);
g.InterpolationMode = InterpolationMode.HighQualityBicubic;
g.DrawImage(bmp, width, height);
g.Dispose();
return b;

}

setting InterpolationMode to HighQualityBicubic gives best results with quality, but it slow. You can look at other options for InterpolationMode.

If you're image is not the default 32bpp, you will have to set that in constructor to bitmap.
If you want different resolution (not the size), you can use SetResolution on the bitmap object.
GeneralCOM Object Pin
FlamTaps9-Jul-04 7:25
FlamTaps9-Jul-04 7:25 
GeneralRe: COM Object Pin
MilesAhead9-Jul-04 8:17
MilesAhead9-Jul-04 8:17 
GeneralRe: COM Object Pin
FlamTaps12-Jul-04 8:55
FlamTaps12-Jul-04 8:55 
GeneralRe: COM Object Pin
Anonymous12-Jul-04 9:37
Anonymous12-Jul-04 9:37 
GeneralRe: COM Object Pin
FlamTaps12-Jul-04 10:29
FlamTaps12-Jul-04 10:29 
GeneralRe: COM Object Pin
MilesAhead14-Jul-04 14:07
MilesAhead14-Jul-04 14:07 
GeneralImpersonation in C# question, please help! Pin
garfieldlee999-Jul-04 7:00
garfieldlee999-Jul-04 7:00 
GeneralRe: Impersonation in C# question, please help! Pin
Heath Stewart9-Jul-04 9:04
protectorHeath Stewart9-Jul-04 9:04 
GeneralProperty Grid Pin
machocr9-Jul-04 6:53
machocr9-Jul-04 6:53 
GeneralRe: Property Grid Pin
Heath Stewart9-Jul-04 9:07
protectorHeath Stewart9-Jul-04 9:07 
GeneralRe: Property Grid Pin
Jay Shankar11-Jul-04 22:26
Jay Shankar11-Jul-04 22:26 
General.NET 2.0's WebBrowser control Pin
Judah Gabriel Himango9-Jul-04 6:32
sponsorJudah Gabriel Himango9-Jul-04 6:32 
GeneralRe: .NET 2.0's WebBrowser control Pin
Heath Stewart9-Jul-04 9:11
protectorHeath Stewart9-Jul-04 9:11 
Generalimplement a own shell-view Pin
Shir Khan9-Jul-04 5:23
Shir Khan9-Jul-04 5:23 
GeneralRe: implement a own shell-view Pin
Jesse Squire9-Jul-04 5:36
Jesse Squire9-Jul-04 5:36 
GeneralRe: implement a own shell-view Pin
Nick Parker9-Jul-04 6:00
protectorNick Parker9-Jul-04 6:00 
GeneralData layer DLL .Config Pin
Andy H9-Jul-04 4:58
Andy H9-Jul-04 4:58 

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.