Open PropertySheet of TaskScheduler 2.0 [Vista & above]

G

Guest

Hi,

This is not a real WinForms-Question, but
it is in context of a WinForms Applikation and
other managed newsgroups do not apply really.

So:
"How to Show the Dialog of the PropertySheet of
a task (say the name is known) the TaskScheduler 2.0
(normally Vista and above)? Preferable in C#".

I know the managed Microsoft.ManagementConsole - SnapIn-Extensions like:

[The managed MMC 3.0 snap-in cookbook - B# .NET Blog]
http://bartdesmet.net/blogs/bart/archive/2008/02/27/the-managed-mmc-3-0-snap-in-cookbook.aspx

But how do I extend the TaskScheduler SnapIn that
a given Task is shown? I also did try some Windows SDK
samples for extending these MMC SnapIns, but i didnt reach
my aim so far.

It would be also good (or perhaps better) if i would
have an API-function, which opens this task-PropertySheet-
Dialog for a task with a given name [for TaskSchuler 2.0].
(for TaskScheduler 1.0 its no problem).


ciao Frank
 
L

Linda Liu[MSFT]

Hi Frank,

The property sheet of a task in the TaskScheduler is not exposed, which
means we cannot open it programmatically.

Task Scheduler 2.0 provides interfaces for C++ and objects for scripting
development respectively. We can use these APIs to interact with the Task
Scheduler service.

The following article introduces programming with Task Schedular 2.0:

"WINDOWS WITH C++ Task Scheduler 2.0"
http://msdn.microsoft.com/en-us/magazine/cc163350.aspx

The following sample provides a .NET class library for Task Scheduler APIs:

"A New Task Scheduler Class Library for .NET"
http://www.codeproject.com/KB/cs/tsnewlib.aspx

For more information on Task Scheduler, refer to the following MSDN
document:
"About the Task Scheduler"
http://msdn.microsoft.com/en-us/library/aa446802(VS.85).aspx

Hope this helps.
If you have any question, please feel free to let me know.

Sincerely,
Linda Liu
Microsoft Online Community Support

Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
(e-mail address removed).

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
 
F

Frank Dzaebel

Hi Linda,

thanks for your response.
The property sheet of a task in the TaskScheduler is
not exposed, which means we cannot open it programmatically.

ok (you mean 2.0), so no API or such direct thing there provided.

But my question was going further. You provide
a good managed Extension interface to MMC.
The Question there was:

"how do I extend the TaskScheduler SnapIn that
a given Task is shown?"

I think there are possibilities going
over the Root and ScopeNode's in the MMC snapin,
which are provided managed as well. The snapin is
called "taskschd.msc" (as you of course know) which
i want to extend, to show the PropertySheet of a task.
So the solution might be more in the direction
of Bart De Smet's blog.
You have functionality like this:

[MMC Code Directory]
http://msdn.microsoft.com/en-us/library/ms692749(VS.85).aspx

[MMC Programming Elements]
http://msdn.microsoft.com/en-us/library/ms692747(VS.85).aspx

Look in the above link to "or it can be an extension snap-in
that extends the operations of a specific snap-in, and is
dependent on the parent snap-in to operate.". And
"taskscheduler snapins" exists in the registry.
Or the "ExtensionToPropertySheetSample".
But so far i do not know, how to extend the taskschd.msc.
_______________



Task Scheduler 2.0 provides interfaces for C++ and objects for scripting
development respectively. We can use these APIs to interact with the Task
Scheduler service.

these links are well known, but they do not provide
a means, to show a PropertySheet as you already
mentioned above.
_________



The following sample provides a .NET class library for Task Scheduler APIs:

"A New Task Scheduler Class Library for .NET"
http://www.codeproject.com/KB/cs/tsnewlib.aspx

Linda, this is for TaskScheduler 1.0. I asked for
2.0. I already use, extended and corrected this
lib to show a PropertySheet on Server 2008 64 Bit.
But this is a PropertySheet 1.0 which do not
have the features of 2.0.
______



yes, known, but no PropertySheet functionality.

So, the question remains - may be you could give
me more advices in relation to MMC SnapIns,
where i "suppose" lies the solution.
Thanks for the help.


ciao Frank
 
L

Linda Liu[MSFT]

Hi Frank,

Thank you for your prompt reply!

This is a quick note to let you know that I'm performing research on this
issue. I will get back to you ASAP.

I appreciate your patience!

Sincerely,
Linda Liu
Microsoft Online Community Support
 
L

Linda Liu[MSFT]

Hi Frank,

I performed a test on the Windows SDK sample
"ExtensionToPropertySheetSample". I build this project and install the snap
in. Then I run mmc.exe and add Computer Management snap-in in it.

But I couldn't find where I can see the custom property sheet. Can you tell
me if you know?

Sincerely,
Linda Liu
Microsoft Online Community Support
 
L

Linda Liu[MSFT]

Hi Frank,

I did more research on this issue and had a new finding.

We can call the ScopeNode.ShowPropertySheet method or the
SelectionData.ShowPropertySheet method to show the property sheet.

Is it helpful to you?

Sincerely,
Linda Liu
Microsoft Online Community Support
 
G

Guest

Hi Linda,
I did more research on this issue and had a new finding.
We can call the ScopeNode.ShowPropertySheet method or the
SelectionData.ShowPropertySheet method to show the property sheet.

Thanks for your research.
Yes, this is the way i thought the PropertySheet should/could be shown
eventually.
*But* what do i have to do, to have the "taskschd.msc" (or a subfolder) in
my context (of my new or extended or original SnapIn), that i am able to
*acess* this ScopeNode from my wished task.
I think, now *i* should make some research of this question.
I will post if i do not come any further.


ciao Frank
 
L

Linda Liu[MSFT]

Hi Frank,

How about your progress on this issue now?

I finish reading some material about MMC programming. Before extending the
Task Scheduler snap-in, we need to find the extensible node type GUID of
this snap-in.

Open Registry Editor and navigate to
\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MMC\SnapIns\FX:{c7b8fb06-bfe1-4c2e-92
17-7a69a95bbac4}. However, I find that the sub key NodeTypes under this key
contains 0 {GUID} keys, which means that no nodes are published by the Task
Scheduler snap-in. IMO, this means that we couldn't extend the Task
Scheduler snap-in.

Do you agree with me?

Sincerely,
Linda Liu
Microsoft Online Community Support
 
G

Guest

Hi Linda,
How about your progress on this issue now?

First of all i have to say thanks for your effort
and that this is not an urgent issue.

i did not had no time to do work on this.
At moment i simply show the customer the
"taskschd.msc", so he has to navigate to the
task on his own.
Of course, i could manage to do some
FindWindow/SendMessage-stuff, to reach
my goal, but that would be a workaround.
_________
I finish reading some material about MMC programming. Before
extending the Task Scheduler snap-in, we need to find the extensible
node type GUID of this snap-in.
Open Registry Editor and navigate to
\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MMC\SnapIns\FX:{c7b8fb06-bfe1-4c2e-92
17-7a69a95bbac4}. However, I find that the sub key NodeTypes under
this key contains 0 {GUID} keys, which means that no nodes are
published by the Task Scheduler snap-in. IMO, this means that we
couldn't extend the Task Scheduler snap-in.
Do you agree with me?

Well, because MMC 3.0 is quite a big thing, i can not
honestly say "agree", but have to believe i think ;-)
So, we can close this issue, with the wish that
customers should be able to do some of this things i
asked for here in a later version.
Thank you for your effort.


ciao Frank
 
L

Linda Liu[MSFT]

Hi Frank,

Thank you for your response!

Ok, I will close this issue now. If you need our further assistance on this
issue in the future, please feel free to re-open this issue and I will
continue to work with you.

Thank you for using our MSDN Managed Newsgroup Support Service!

Sincerely,
Linda Liu
Microsoft Online Community Support
 
M

MarkD

Hi,

This is not a real WinForms-Question, but
it is in context of a WinForms Applikation and
other managed newsgroups do not apply really.

So:
"How to Show the Dialog of the PropertySheet of
a task (say the name is known) the TaskScheduler 2.0
(normally Vista and above)? Preferable in C#".

I know the managed Microsoft.ManagementConsole - SnapIn-Extensions like:

[The managed MMC 3.0 snap-in cookbook - B# .NET Blog]
http://bartdesmet.net/blogs/bart/archive/2008/02/27/the-managed-mmc-3-0-snap-in-cookbook.aspx

But how do I extend the TaskScheduler SnapIn that
a given Task is shown? I also did try some Windows SDK
samples for extending these MMC SnapIns, but i didnt reach
my aim so far.

It would be also good (or perhaps better) if i would
have an API-function, which opens this task-PropertySheet-
Dialog for a task with a given name [for TaskSchuler 2.0].
(for TaskScheduler 1.0 its no problem).


ciao Frank
--
Dipl.Inf. Frank Dzaebel [MCP/MVP C#]
http://Dzaebel.NET

Search Microsoft Information Rights Management (IRM) in Visual Basic 2008
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top