NavigatingCancelEventArgs has no "Cancel" property

2 posts, 0 answers
  1. Justin
    Justin avatar
    18 posts
    Member since:
    Oct 2008

    Posted 11 Sep 2009 Link to this post

    I'm using Telerik.Windows.Controls.NavigationService

    I'm also using the "Navigating" event which has "NavigationCancelEventArgs" as a parameter.  I have some logic in this event in which I wish to cancel the navigation if a condition exists.  However there is no "Cancel" property on the "NavigatingCancelEventArgs" parameter.  I get this compiler error:

    Error   1   'Telerik.Windows.Controls.NavigatingCancelEventArgs' does not contain a definition for 'Cancel' and no extension method 'Cancel' accepting a first argument of type 'Telerik.Windows.Controls.NavigatingCancelEventArgs' could be found (are you missing a using directive or an assembly reference?)   C:\Users\jmyers\Desktop\TimeTracker2\trunk\TimeTracker2\TTMainApplication\TTMaster.xaml.cs  62  19  TTMainApplication 
     

    Any idea why?  If this is by design, I suggest you change the name or class of the "e" parameter.
  2. Bobi
    Admin
    Bobi avatar
    513 posts

    Posted 14 Sep 2009 Link to this post

    Hello Justin,

    We apologize for the caused inconvenience. Navigating event if fired after the navigation is completed.
    As a workaround you can add the desired validation before calling the Navigate method.
    On another note our plans are to obsolete this component, since there is now a page navigation inside the SL3 framework. So if you are using SL3 it is recommended to convert to the Microsoft page navigation model.



    Sincerely yours,
    Boryana
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. DevCraft banner
Back to Top