Click here to Skip to main content
15,893,622 members
Home / Discussions / Windows Forms
   

Windows Forms

 
AnswerRe: Change Background image of form runtime Pin
April Fans21-Sep-09 21:44
April Fans21-Sep-09 21:44 
Questionlogical expression editor Pin
r.ps9-Sep-09 19:00
r.ps9-Sep-09 19:00 
QuestionDifferent Icon on the title bar than on the application tab Pin
andy4009-Sep-09 10:50
andy4009-Sep-09 10:50 
AnswerRe: Different Icon on the title bar than on the application tab Pin
Luc Pattyn9-Sep-09 10:57
sitebuilderLuc Pattyn9-Sep-09 10:57 
GeneralRe: Different Icon on the title bar than on the application tab Pin
andy4009-Sep-09 11:24
andy4009-Sep-09 11:24 
GeneralRe: Different Icon on the title bar than on the application tab Pin
Luc Pattyn9-Sep-09 11:32
sitebuilderLuc Pattyn9-Sep-09 11:32 
AnswerRe: Different Icon on the title bar than on the application tab Pin
April Fans21-Sep-09 21:45
April Fans21-Sep-09 21:45 
QuestionA problem with Generics [modified] Pin
Henry Minute9-Sep-09 8:03
Henry Minute9-Sep-09 8:03 
I have been wrestling with a problem for about four days now, and quite honestly I think it's winning. I'm down by two falls to one at the moment.
Since song parodies were mentioned in The Lounge recently, I thought I'd have a go.

My application won't compile
I've searched the thing all over the place
Googled till I was black in the face
I'm a big disgrace t' the Programmer race
My Application won't compile

You see what it's done, it's reduced me to a gibbering wreck.

Here's the problem.

I have a generic class, to save you reading through loads of code, for this explanation pretend that it is a Stack<T>, since the result is the same.

Now I want to create a Control StackVisualizer that can show a graphical representation of any Stack<T>. You know a set of vertically aligned boxes representing the items in the Stack<T>, so that you can see what happens with Push and Pop etc.

public partial class StackVisualizer : UserControl
{
  private Stack<T> workingStack = null;
  ..................
  ..................
  ..................
  ..................
}


That doesn't work, because T is not known at compile time.

OK so lets try:
public partial class StackVisualizer<T> : UserControl where T : IEnumerable<T>
{
  private Stack<T> workingStack = null;
  ..................
  ..................
  ..................
  ..................
}


Now this works, but StackVisualizer is no longer a visual control. I can put it on a Form and set its properties etc. but I have to do it in code, I cannot do it in the Designer.

Does anybody have any ideas?
Plzzzzzzzzzzz give me teh codezzzzzzzzzzzzzzzzzz!

Henry Minute

Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”

modified on Wednesday, September 9, 2009 2:13 PM

QuestionRegions with in a function Pin
εїзεїзεїз8-Sep-09 15:37
εїзεїзεїз8-Sep-09 15:37 
AnswerRe: Regions with in a function Pin
dan!sh 8-Sep-09 22:52
professional dan!sh 8-Sep-09 22:52 
QuestionForm Resizing and Docked Controls Pin
farzadmf8-Sep-09 12:48
farzadmf8-Sep-09 12:48 
AnswerRe: Form Resizing and Docked Controls Pin
Henry Minute8-Sep-09 13:04
Henry Minute8-Sep-09 13:04 
GeneralRe: Form Resizing and Docked Controls Pin
farzadmf8-Sep-09 20:05
farzadmf8-Sep-09 20:05 
GeneralRe: Form Resizing and Docked Controls Pin
Henry Minute9-Sep-09 7:35
Henry Minute9-Sep-09 7:35 
AnswerRe: Form Resizing and Docked Controls Pin
farzadmf9-Sep-09 10:05
farzadmf9-Sep-09 10:05 
GeneralRe: Form Resizing and Docked Controls Pin
Henry Minute9-Sep-09 10:56
Henry Minute9-Sep-09 10:56 
GeneralRe: Form Resizing and Docked Controls Pin
farzadmf9-Sep-09 11:45
farzadmf9-Sep-09 11:45 
GeneralRe: Form Resizing and Docked Controls [Hold the Front Page] Pin
Henry Minute9-Sep-09 11:10
Henry Minute9-Sep-09 11:10 
AnswerRe: Form Resizing and Docked Controls Pin
Zoki Manas8-Sep-09 23:06
Zoki Manas8-Sep-09 23:06 
AnswerRe: Form Resizing and Docked Controls Pin
farzadmf8-Sep-09 23:55
farzadmf8-Sep-09 23:55 
AnswerRe: Form Resizing and Docked Controls Pin
geali_dor9-Sep-09 19:46
geali_dor9-Sep-09 19:46 
GeneralRe: Form Resizing and Docked Controls Pin
farzadmf9-Sep-09 23:02
farzadmf9-Sep-09 23:02 
QuestionShow Notification Pin
sri_00998-Sep-09 1:12
sri_00998-Sep-09 1:12 
AnswerRe: Show Notification Pin
Richard MacCutchan8-Sep-09 5:31
mveRichard MacCutchan8-Sep-09 5:31 
GeneralRe: Show Notification Pin
sri_00998-Sep-09 22:20
sri_00998-Sep-09 22:20 

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.