Click here to Skip to main content
15,918,178 members
Home / Discussions / C#
   

C#

 
AnswerRe: Syste.OutOfMemoryException Pin
Ennis Ray Lynch, Jr.11-Mar-09 19:46
Ennis Ray Lynch, Jr.11-Mar-09 19:46 
QuestionSetting Form2's start position as Form1's last position Pin
Paulo Toureiro11-Mar-09 13:05
Paulo Toureiro11-Mar-09 13:05 
AnswerRe: Setting Form2's start position as Form1's last position Pin
DaveyM6911-Mar-09 13:21
professionalDaveyM6911-Mar-09 13:21 
GeneralRe: Setting Form2's start position as Form1's last position Pin
Paulo Toureiro11-Mar-09 13:40
Paulo Toureiro11-Mar-09 13:40 
GeneralRe: Setting Form2's start position as Form1's last position Pin
Expert Coming11-Mar-09 14:16
Expert Coming11-Mar-09 14:16 
GeneralRe: Setting Form2's start position as Form1's last position Pin
Paulo Toureiro11-Mar-09 14:21
Paulo Toureiro11-Mar-09 14:21 
GeneralRe: Setting Form2's start position as Form1's last position Pin
DaveyM6911-Mar-09 14:31
professionalDaveyM6911-Mar-09 14:31 
GeneralRe: Setting Form2's start position as Form1's last position Pin
Paulo Toureiro11-Mar-09 14:40
Paulo Toureiro11-Mar-09 14:40 
Hi Dave,

I cannot believe how simple this solution really is - thank you so much.

I am still getting to terms with the jargon and so on, I was so close! Smile | :)

private void btnOpenForm2_Click_1(object sender, EventArgs e)
       {
           if (form2 == null || form2.IsDisposed)
           {
               form2 = new Form2();
               form2.Location = this.Location;    < ----- I just had to add this
               this.Visible = false;
               form2.Show();
           }
           else
           {
               MessageBox.Show("form2 already open,showing");
               form2.Focus();
           }

        }


I also had to change form2's start position within the code for form2, to
this.StartPosition = System.Windows.Forms.FormStartPosition.Manual;

Thanks so much again for the help, I really appreciate it!
GeneralRe: Setting Form2's start position as Form1's last position Pin
DaveyM6911-Mar-09 14:49
professionalDaveyM6911-Mar-09 14:49 
QuestionUsing Generic Method to Determine if All Elements in an Array is Zero Pin
mfcuser11-Mar-09 12:17
mfcuser11-Mar-09 12:17 
AnswerRe: Using Generic Method to Determine if All Elements in an Array is Zero Pin
Christian Graus11-Mar-09 12:27
protectorChristian Graus11-Mar-09 12:27 
AnswerRe: Using Generic Method to Determine if All Elements in an Array is Zero Pin
Adam Maras11-Mar-09 12:27
Adam Maras11-Mar-09 12:27 
GeneralRe: Using Generic Method to Determine if All Elements in an Array is Zero Pin
mfcuser11-Mar-09 12:47
mfcuser11-Mar-09 12:47 
GeneralRe: Using Generic Method to Determine if All Elements in an Array is Zero Pin
Adam Maras11-Mar-09 13:32
Adam Maras11-Mar-09 13:32 
GeneralRe: Using Generic Method to Determine if All Elements in an Array is Zero Pin
mfcuser12-Mar-09 4:29
mfcuser12-Mar-09 4:29 
GeneralRe: Using Generic Method to Determine if All Elements in an Array is Zero Pin
mfcuser12-Mar-09 5:08
mfcuser12-Mar-09 5:08 
QuestionHiding an empty Column in Gridview Pin
edcorusa11-Mar-09 11:31
edcorusa11-Mar-09 11:31 
AnswerRe: Hiding an empty Column in Gridview Pin
dataminers11-Mar-09 12:10
dataminers11-Mar-09 12:10 
GeneralRe: Hiding an empty Column in Gridview Pin
edcorusa13-Mar-09 7:51
edcorusa13-Mar-09 7:51 
GeneralRe: Hiding an empty Column in Gridview Pin
dataminers13-Mar-09 21:25
dataminers13-Mar-09 21:25 
QuestionDelegates for instance methods across appdomains... [modified] Pin
MrBhbk11-Mar-09 8:57
MrBhbk11-Mar-09 8:57 
Generali created VSTO 2003 addin for outlook inspector. i need help in Pin
Arun Kumar A.S11-Mar-09 7:57
Arun Kumar A.S11-Mar-09 7:57 
GeneralRe: i created VSTO 2003 addin for outlook inspector. i need help in Pin
dataminers16-Mar-09 7:03
dataminers16-Mar-09 7:03 
QuestionProblem with webservice! Pin
Bryan Karlsson11-Mar-09 7:56
Bryan Karlsson11-Mar-09 7:56 
AnswerRe: Problem with webservice! Pin
J$11-Mar-09 9:37
J$11-Mar-09 9:37 

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.