chevron-thin-right chevron-thin-left brand cancel-circle search youtube-icon google-plus-icon linkedin-icon facebook-icon twitter-icon toolbox download check linkedin phone twitter-old google-plus facebook profile-male chat calendar profile-male
Welcome to Typemock Answers. Here you can ask and receive answers from other community members. And if you liked or disliked an answer or thread: react with an up- or downvote Enjoy!
0 votes
How to create stub for ShowDialog?

 if (Isenable|| sfd.ShowDialog(this) == DialogResult.OK)
     {
                    if ((sfd != null) && FileIsInUse(sfd.FileName) )
                    {
                        MessageBox.Show(Localize.LocalMessage(\"localized_msg_Unable_Open_File\"));
                        return;
                    }
asked by (2.1k points)

1 Answer

0 votes

Hi ganam, 

What did you mean by \"create stub for ShowDialog\"?

ShowDialog is a method, so you can use Isolate.WhenCalled() in order to modify it\'s behavior.

Cheers,

Sapir.

answered by (3.1k points)
+++++++++++++++1
...