Groups | Blog | Home
all groups > sql server dts > july 2003 >

sql server dts : Register Custom Task automatically



Frank Matthiesen
7/3/2003 10:49:48 PM
hi ng,

is there any other way to register a custom task (written in VB) in the
DTS-Designer as register it within the DTS-Task-UI?
I've read something about the "Register Custom Task command" on msdn but i
don't find any further information.
Any suggests, hints or informations?


regards

Frank
www.xax.de

Darren Green
7/4/2003 3:12:00 PM
Never seen a command to do this, but it can be done by writing some registry
entries.
There is a topic in Books online "Registering a DTS Custom Task".
Unfortunately VB does not offer way to automatically register the task as
per C++, but the registry info is the same
Personally I've manually build the reg entries into a VSI solution and use
the resulting MSI to do my installs. Works quite well even through it can be
a bit fiddly to build.


--
Darren Green
http://www.sqldts.com

[quoted text, click to view]

Darren Green
7/4/2003 3:59:44 PM

[quoted text, click to view]

I think it means the manual way using the "Register Custom Task" menu item
within the designer.

[quoted text, click to view]

Not with me now, I'll try and dig something out later.

[quoted text, click to view]
Pretty much as per the books online topic.

Do i need to refresh the cache after registering
[quoted text, click to view]

Yes, pretty sure you would, but cannot remember to be honest.


--
Darren Green
http://www.sqldts.com


Frank Matthiesen
7/4/2003 4:38:18 PM
[quoted text, click to view]

hi Darren,

thx for your answer.
Original textline on msdn:
"You also can create custom tasks programmatically, and then integrate them
into DTS Designer using the Register Custom Task command."

Link:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnsql2k/htm
l/dts_overview.asp

Anyway:
Do you got a little code snippet/some infos about the registry entries fpr
me?
Wich entries are needed? Do i need to refresh the cache after registering
the new task?

regards

Frank
www.xax.de


Frank Matthiesen
7/4/2003 6:40:10 PM

"Darren Green" >
[quoted text, click to view]

Doesn't matter. I will setup regmon,register some custom task and will see.
Should be possible to get the needed entries.

best regards from bextown/germany

do you interest in beer, do you?


Frank



Darren Green
7/5/2003 9:36:39 AM
In article <be4aks$13c18$1@ID-151790.news.dfncis.de>, Frank Matthiesen
<fm@xax.de> writes
[quoted text, click to view]
Of course!

I used Visual Studio Installer (VSI) to create my MSI packages, from a
VB project. I set the compiled DLL to self-register, and also add the
following registry keys manually to the VSI solution-

HKEY_CLASSES_ROOT
-----------------

Key: CLSID\{Class ID for Component.CTaskClass}

Name: (default)
Value: Component.CTaskClass
Type: String

Name: AppID
Value: {Class ID for Component.CTaskClass}
Type: String

Name: DTSIconFile
Value: \path\iconfile.ext|\path\customtask.dll
Type: String

Name: DTSIconIndex
Value: 0
Type: DWORD

Name: DTSTasKDescription
Value: Default Task Description
Type: String


Key: CLSID\{Class ID for Component.CTaskClass}\Implemented
Categories\{Class ID for DTS Library}

HKEY_CURRENT_USER
-----------------
(SQL Server 2000 Only)

Key: SOFTWARE\Microsoft\Microsoft SQL
Server\80\DTS\Enumeration\Tasks\{Class ID for Component.CTaskClass}

HKEY_LOCAL_MACHINE
------------------
Same keys and values as HKEY_CLASSES_ROOT above


I'm not that good on COM, but if you register the custom task manually,
and then use the "OLE View" tool that comes with Visual Studo 6..0 you
will see a nice section for custom tasks. Compare yours with the others
for interest, and it will also give your the CLSID.

--
Darren Green (SQL Server MVP)
DTS - http://www.sqldts.com

AddThis Social Bookmark Button