🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.csharpbuilder.language.csharp
Article #46

Re: Converting byte[] to bitmap

#46
From: Mick
Date: Fri, 26 May 2006 15:01
24 lines
1797 bytes
Thanks for that! Works a treat!


"Marc Rohloff [TeamB]" <"on request"> wrote in message 
news:1xxx3grz8ki2o$.dlg@dlg.marcrohloff.com...
> On Fri, 26 May 2006 13:14:38 +0100, Mick wrote:
>
>> I am loading a jpeg byte[] from a database and i am trying to load this 
>> into
>> a bitmap object wher i can resize it. I can do this by copying the byte[] 
>> to
>> a file and using the standard bitmap load from file functions;
>>
>> Is there a way I can do this without having to goto to the disk?
>
> I assume you mean load it from a file using the constructor?
>
> You should be able to use a MemoryStream which accepts a byte[] in its
> constructor and then pass this Stream to the constructor of your
> Bitmap.
>
> -- 
> Marc Rohloff [TeamB]
> marc rohloff -at- myrealbox -dot- com 
Technical Details
Message-ID: <44771857@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <4476f12d$1@newsgroups.borland.com> <1xxx3grz8ki2o$.dlg@dlg.marcrohloff.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 1efe35,7404b6c94d2abff
X-Google-Attributes: gid1efe35,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Mick" <mick@imagered.co.uk>
Newsgroups: borland.public.csharpbuilder.language.csharp
References: <4476f12d$1@newsgroups.borland.com> <1xxx3grz8ki2o$.dlg@dlg.marcrohloff.com>
Subject: Re: Converting byte[] to bitmap
Date: Fri, 26 May 2006 16:01:37 +0100
Lines: 26
Organization: Imagered
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2869
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2869
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: 194.73.111.3
Message-ID: <44771857@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1148655703 194.73.111.3 (26 May 2006 08:01:43 -0700)
Path: arc1-ca.pugleaf.net!g2news2.google.com!news3.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail