none
How to implement TaskScheduler Type Library in vs2005?

    Question

  • I add a reference of TaskScheduler Type Library 1.1 in my c# project(just a simple project created by vs2005), and i find vs2005 create a Interop.TaskScheduler.dll for me . So , i try to use it:
    using TaskScheduler;
    public class a
    {
    public void someFunction()
    {
    ITaskService service = new TaskScheduler.TaskSchedulerClass();
    }
    }
    When i complie, it fails and show error:A get or set accessor expected(CS1014).
    Why? How do i implement Com in my project?

    Tuesday, September 18, 2007 11:01 AM

Answers

  • Hi milex,

    I test the code you provided on my machine (Vista, Visual Studio 2005 with SP1 and latest pack for vista), but I found no problem. Have you applied the latest service pack?

    And I guess only part of your application source code were posted here, for the Compiler Error CS1014 which is a common grammar error. I suggest that you can check the parts of Using Properties in your code.

    Thanks!

    Thursday, September 20, 2007 5:59 AM

All replies

  • The Windows XP version of mstask.dll doesn't contain a type library.  Where did you get it?
    Tuesday, September 18, 2007 1:07 PM
    Moderator
  • My platform is vista. And it's contain a type library.
    Wednesday, September 19, 2007 1:56 AM
  • Hi milex,

    I test the code you provided on my machine (Vista, Visual Studio 2005 with SP1 and latest pack for vista), but I found no problem. Have you applied the latest service pack?

    And I guess only part of your application source code were posted here, for the Compiler Error CS1014 which is a common grammar error. I suggest that you can check the parts of Using Properties in your code.

    Thanks!

    Thursday, September 20, 2007 5:59 AM