locked
Help - Video tutorial - Active doesnot exit in current context RRS feed

  • Question

  • Dear all,

    I am new to Robotics and

    was following one of the video tutorial on C# - Dialog Drive

    "Microsoft Robotics Studio- Robotics Tutorials"

    I was about to compile, but I get the message.

     

    "Active doesnot exit in current context ".

     

    Part of code is

     

    private void SubscribeToDirectionDialog()

    {

    dialog.DirectionDialogOperations dialogNotifications =

    new dialog.DirectionDialogOperations();

    _dialogPort.Subscribe(dialogNotifications);

     

    Active<ITask> ((

    Arbiter.Receive<dialog.ButtonPress>(true,

    dialogNotifications, DialogButtonPressHandler)),

    (Arbiter.Receive<dialog.ButtonRelease>(true,

    dialogNotifications, DialogButtonReleaseHandler))

    );

    }

     

    I need help and appreciate it

     

    Thanks

     

     

     

    Monday, February 4, 2008 3:28 AM

Answers

  • The method to activate tasks is Activate: 

     

    Activate ((

    Arbiter.Receive<dialog.ButtonPress>(true,

    dialogNotifications, DialogButtonPressHandler)),

    (Arbiter.Receive<dialog.ButtonRelease>(true,

    dialogNotifications, DialogButtonReleaseHandler))

    );

    }

     

     

    Andreas

    Tuesday, February 5, 2008 8:23 AM