Questions tagged [dialogresult]

DialogResult is returned by dialogs after dismissal. It indicates which button was clicked on the dialog by the user. It is used with the MessageBox.Show method. It is a value. It can be switched upon and tested in an if-statement.

DialogResult is returned by dialogs after dismissal. It indicates which button was clicked on the dialog by the user. It is used with the MessageBox.Show method. It is a value. It can be switched upon and tested in an if-statement.

97 questions
-1
votes
1 answer

VB.NET: DialogResult.No is not closing the form

Using Message Box DialogResult.No Condition for closing the form doesnot perform as expected. The formclosing event aske user whether to save the document or not before closing. The following is my FormClosing event. Private Sub…
Asif Hussain
  • 67
  • 11
-1
votes
1 answer

Receiving password input using DialogShow() not working

I am writing a WinForm application in C#. There is a Form A that opens Form C on Button click. Now, I want to add a password input screen Form B before opening Form C. Only if the password entered is correct will Form C open, and otherwise, show an…
Mika Jones
  • 287
  • 1
  • 5
  • 13
-1
votes
1 answer

Use DialogResult in windows Form application c#

I want to use DialogResult to go to next Form and visible or invisible any control in next form with radio button is checked. In the first form I use this code: this.DialogResult = DialogResult.OK; loader.Enabled =…
Mr.AA
  • 15
  • 1
  • 5
-1
votes
1 answer

c# Delete dialogresult

How can I delete DialogResult object ? I am using it as a confirmation for clearing form (removing all controls and reinitializing of controls). The problem is that when I hit yes it recreates the second DialogResult, then third one, then fourth,…
marhyno
  • 677
  • 1
  • 8
  • 20
-1
votes
1 answer

How to bring DialogResult result on front

How to bring DialogResult on front. Below is my Form. i want to bring it to front of all other application run. But it is working in debug mode but not working in "Run without debug mode". using System; using System.Collections.Generic; using…
MD TAHMID HOSSAIN
  • 1,581
  • 7
  • 29
  • 54
-1
votes
1 answer

How to Use The Form Opened When Using ShowDialog()?

Currently I am working with the ShowDialog() method and trying to figure out how it is supposed to work. I have a form, testDialog, that has a text box that will take an input string. I followed the code on the MSDN page as follows: string…
Justin
  • 35
  • 8
-2
votes
2 answers

How to loop the dialogresult

Form1 frm = new Form1(); frm1.ShowDialog(); I use this to create new form to do some stuff(not important), and then after i'm done with the form i display dialogresult to open that same form again. Question: how can i continue to open the same…
Michael27
  • 161
  • 1
  • 13
1 2 3 4 5 6
7