very thanks!
I have done what you had told me to do.
A new problem troubles me,that is when I chaned the property of form_1 in the form_ 2.then I write:
form1.validate( );
form1.Show();
what I want to know is to concern whether the form1 immediately be changed.
but I failed.can you show me other ways to see the form1 immediately?
thanks!
User Profile
Collapse
-
C#-APP: How I can control other forms in one form?
Exactly I create a main form and a sub form.There are several pictures on the main form.
what I want to do is when I select one picture in the main form,I want the sub form display that picture immediately and the control is not changed from the main to the sub.
very thanks!
Platform:
FrameWork3.5
Microsoft Visual C# 2008 -
yang from china replied to How can i to save byte array data to a stream and convert them to a bitmap instancein .NETThank you for your reply.I found a way to solve my proble.Can you show me some advices:
byte[] paletteArr = readPaletteData ();
byte[] pixelArr = readPixelData() ;
Bitmap bmp = new Bitmap(Width,He ight);
for (int i = 0; i < Height;i++ )
{
for (int j = 0; j < Width; j++)
{
Color tmp;
int R = (int)paletteArr[pixelArr[i * Width + j] * 3 + 2];
int...Leave a comment:
-
yang from china replied to How can i to save byte array data to a stream and convert them to a bitmap instancein .NETvery thanks for your guide!
well, I am failed to use MemmoryStream to create bitmap.
bitmap constructor:bit map(stream);
When I use MemoryStream to create bitmap,The error window tell me parameter is wrong.so I have to find a way to create bitmap by using palette data and pixel data I get from the TGA file.
by the way,can you show me how to use MemoryStream to create bitmap?
thank...Leave a comment:
-
yang from china started a topic How can i to save byte array data to a stream and convert them to a bitmap instancein .NETHow can i to save byte array data to a stream and convert them to a bitmap instance
I cannot open TGA file use framework's class,so I am trying to convert TGA file to BMP file(or others).Now I have read the palette data and pixel data successfully.On e way I create a temporary BMP file so I can open it again by use filestream.but it is stupid.
Can anyone tell me create bitmap instance by using palette data and pixel data?
any reply is very thanksful.
No activity results to display
Show More
Leave a comment: