i have a requirement, i need to show the Lookup data to user in the Windows Form (able to show the data through Windows form), but When windows form is up like Dialog box & BOT should be wait for user action on the window form based on the user clicks(Yes or NO) BOT will move further based on user input..
im able to show the WindowsForm as Dialog box using show dialog method but how to handle the Yes or NO buttons and if user clicks Yes i need to move through some automation if user clicks NO, need to move through some automation.
@BaratamRGreat question. The ShowDialog method returns a DialogResult (which tells you which button was pressed). On your form, you assign that value to each of your buttons via the “DialogResult” property on the button.
or we can do this way right - In Windows form, Add two Buttons and assign the dialogResult as Ok or Cancel. Based on Button action Windowsform act as Dialog.