How to create a COM object for the Task-Scheduler!

How to create a COM object for the Task-Scheduler!

bradeneuropeArthur
Mentor Mentor
384 Views
0 Replies
Message 1 of 1

How to create a COM object for the Task-Scheduler!

bradeneuropeArthur
Mentor
Mentor

Hi,

 

How to create a COM object for the Task-Scheduler using ServiceModuleInterfaceDef.tlb?

Are there any examples available?

 

Found this in the Help but I need some more support on this:

"Definine COM interface

If you want to use the custom task functionality with COM, first create a COM component which is derived from IServiceModules. The file ServiceModuleInterfaceDef.tlb, which defines the COM interface -- IServiceModules, is installed at Program Files 

 

 Autodesk 

 

 Inventor [version] 

 

 

 Bin. There are five methods defined in the interface:

  • HRESULT StartTask() -- Must be implemented to start the actual custom work at a scheduled time.
  • HRESULT KillTask(void) -- Reserved.
  • HRESULT SetOptions ([in] VARIANT varOptions) -- Passes in the options specified on the UI.
  • HRESULT GetInventorProcessID([in, out] SAFEARRAY(long)* ppsaInventorProcIDs) -- Retrieves Inventor process IDs for monitor usage.
  • HRESULT SetCommand)(*[in} enumTaskCmd enumTaskCmd) -- Sets the commands for pause, stop, and resume task.
Note: Reference the file ServiceModuleInterfaceDef.tlb within your project for access to the COM interface."

 

Regards,

Regards,

Arthur Knoors

Autodesk Affiliations & Links:
blue LinkedIn LogoSquare Youtube Logo Isolated on White Background


Autodesk Software:Inventor Professional 2025 | Vault Professional 2024 | Autocad Mechanical 2024
Programming Skills:Vba | Vb.net (Add ins Vault / Inventor, Applications) | I-logic
Programming Examples:
Drawing List!|
Toggle Drawing Sheet!|
Workplane Resize!|
Drawing View Locker!|
Multi Sheet to Mono Sheet!|
Drawing Weld Symbols!|
Drawing View Label Align!|
Open From Balloon!|
Model State Lock!
Posts and Ideas:
My Ideas|
Dimension Component!|
Partlist Export!|
Derive I-properties!|
Vault Prompts Via API!|
Vault Handbook/Manual!|
Drawing Toggle Sheets!|
Vault Defer Update!

! For administrative reasons, please mark a "Solution as solved" when the issue is solved !


 


EESignature

0 Likes
385 Views
0 Replies
Replies (0)