C1MessageBoxResult

  • -1p
    lenchase-1p 8 years, 3 months ago

    HI:

    I am working thru the Silverlight C# quickstart("StudioForSilverLight.pdf")

    All was well until I reached the MessageBox Tutorial Page 42

    I get C1MessageBoxResult does not exist in the current context.

    The zaml and code were pasted in from the pdf.

    The C1 references and Using statements are set.

    Also The first 41 pages of examples work.

    Any Idea on what I am missing?

    Thanks

    Len

    Zaml: 

    />

  • 6p
    C1_MaxM6p 8 years, 3 months ago

    C1MessageBox now uses the builtin MessageBoxResult enumeration instead of C1MessageBoxResult. We will update the QuickStart doc. Thanks for your feedback.

  • 1p
    Seratti1p 4 years, 9 months ago

    I dont found the C1MessageBoxResult. Look my case:

                if (C1MessageBox.Show("Do you want to go?", "Question", C1MessageBoxButton.OKCancel) == C1MessageBoxResult.OK)

    SomeBody can help me ?!

  • 22p
    C1_Deepankar22p 4 years, 9 months ago

    Hi,

    As mentioned in the above response, there is a change in the MessageBox result handler.
    Instead of C1MessageBoxResult object, it now works on default MesssageBoxResult
    Class. See the suggested code below.

    
    
    C1MessageBox.Show("Do you want to delete?", "The question", C1MessageBoxButton.YesNoCancel, C1MessageBoxIcon.Question,
                    new System.Action<MessageBoxResult>((result) =>
                    {
                        switch (result)
                        {
                            case MessageBoxResult.Yes:
                                MessageBox.Show("You Pressed Yes");
                                break;
                            case MessageBoxResult.No:
                                MessageBox.Show("You Pressed No");
                                break;
                            case MessageBoxResult.Cancel:
                                MessageBox.Show("Are you sure you want to cancel");
                                break;
                        }
                    }));
    
    

    Regards,

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

Questions?

Have questions? Use our Customer Portal at

supportone.componentone.com