|
The functionality you're describing is called splash screen and there are some articles here on Codeproject that cover this topic and should give you some ideas how to implement this effectively and nicely. Just search the articles for "splash screen".
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
|
I'm inheriting TabControl in user defined class CustomTubControl, but when I try to open form with this control in Designer, I get error message: "TabPage cannot be added to a 'Microsoft.CompactFramework.Design.UnsafeControl'. TabPages can only be added to TabControls." on line:
this.m_Tab.Controls.Add(this.tabHeader);
Form builds, but it is not visible in Designer. How can the new control be visible in the Designer?
|
|
|
|
|
Hello,
The TabPage has to be added to the TabPages property of your TabControl.
this.m_Tab.TabPages.Add(this.tabHeader);
All the best,
Martin
|
|
|
|
|
I am having problem with control events.I am unable to raise overriden paint event.drag& drop event and mouse events.The control is dropped on a designer at runtime i.e control can be moved freely on the designer at runtime.
used delegate to raise the event but not working...
|
|
|
|
|
Hello,
Looks like you forgot to call the base.xxx Method of the overriden events.
like:
protected override void OnPaint(System.Windows.Forms.PaintEventArgs e)
{
base.OnPaint;
}
Hope that helps!
All the best,
Martin
|
|
|
|
|
I have called base.xxx method.
Eventhough i have kept a breakpoint at the beginning of the method ,it doesn't go to the method itself.
|
|
|
|
|
snoby wrote: The control is dropped on a designer at runtime
Ohh, now I understand.
Youre control is in design mode, or not?
Don't think that the event's are fired in this mode.
Sorry for not realy helping.
All the best,
Martin
|
|
|
|
|
Tell me how to get updated Coordinate position when control is dragged & dropped on any part of designer without using events.On designer also events are not getting raised.
|
|
|
|
|
I want to open mdi form from login form ....im using following code....
in Login form..but its not working.....
private void cmdsubmit_Click(object sender, System.EventArgs e)
{
frmmdi frm = new frmmdi();
this.Dispose();
this.Close();
frm.Show();
frm.Enabled=true;
frm.Visible=true;
}
ahmad.osama1984@gmail.com
|
|
|
|
|
Hello,
Osama123 wrote: this.Dispose();
This is not going to work, because you are Disposing the form wich holds the reference to your new form.
Osama123 wrote: this.Close();
Same here, because the Close method calls the Dispose method.
Osama123 wrote: frm.Enabled=true;
frm.Visible=true;
This is normaly the default setting, so you shouldn't need it.(But it's not wrong)
Osama123 wrote: this.Dispose();
this.Close();
You should use this.Hide() instead.
Hope that helps.
All the best,
Martin
|
|
|
|
|
Thanx Martin.........
|
|
|
|
|
Youre always welcome!
All the best,
Martin
|
|
|
|
|
try this.Hide() instead of close and Dispose.
In the closing event of frmmdi use Application.Exit().
Hope this satisfies ur needs...
|
|
|
|
|
How to create thumbnail Image of video file(.wav etc) in asp.net 2.0 with c#.
|
|
|
|
|
yogesh_v12 wrote: How to create thumbnail Image of video file(.wav etc)
You won't get very far making a thumbnail of a wav file because it contains no image elements - it is an audio format.
|
|
|
|
|
Hi, All.
My application have to generate a text bitmap. The text string is inputted by user, and will be drawn on a panel witin a fixed region. so the string is auto wrapped with multi-line.
I would like to save the display text into a bitmap file (same as the preview with auto wrapped). Does anyone know how to do ? Could you please provide me some examples ? Thank you so much !!
|
|
|
|
|
Hello,
Do I understand it write, that you have the Text allready in your panel and make a bitmap (like screenshot) from the panel?
Martin
|
|
|
|
|
yes, correct.
I have already used the drawString to draw text on Panel. But don't know how to generate a bitmap.
Here is my example code for drawing the string:
<br />
string txt = "AbcdefgHigklmnopqrstuvWxyz.AbcdefgHigklmnopqrstuvWxyz.***(AbcdefgHigklmnopqrstuvWxyz)@#!!!) (AbcdefgHigklmnopqrstuvWxyZ)ZZZZZZZ";<br />
StringFormat drawFormat = new StringFormat();<br />
<br />
drawFormat.FormatFlags = StringFormatFlags.DisplayFormatControl;<br />
drawFormat.Trimming = StringTrimming.Character;<br />
drawFormat.LineAlignment = StringAlignment.Near;
<br />
g.DrawRectangle(Pens.Red, new Rectangle(100, 100, 200, 500));<br />
g.DrawString(txt, f, Brushes.Black, new RectangleF(100, 100, 200, 500), drawFormat);<br />
<br />
|
|
|
|
|
Hello,
You could use the CreateBitmap Method of the panel class.
All the best,
Martin
|
|
|
|
|
Create a new Graphis object and use DrawString function....
|
|
|
|
|
But use DrawString just draw the text on the screen...
how can I generate a bitmap as same as the preview on screen?
thank you
|
|
|
|
|
Use the DrawToBitmap method to draw the control on a Bitmap.
---
b { font-weight: normal; }
|
|
|
|
|
Thank you Guffa,
I'm sorry, can you give me some example code?
|
|
|
|
|
Dear All,
I am making web based Application.There i am making one master page where i am saving, delete data. I need to know how i can prompt message before saving or deleting data(Asking whether user want to save data or not). how i can do it in C#.
thanks
regards
imran khan
|
|
|
|