dbTalk Databases Forums  

Passing a Variable from VB.NET to a DTS Package

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss Passing a Variable from VB.NET to a DTS Package in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Jim James
 
Posts: n/a

Default Passing a Variable from VB.NET to a DTS Package - 04-04-2005 , 01:07 PM






I'd like to pass two date variables from a VB app to a "Transform Data
Task" in my DTS package. This seems to be an easy request, but I can't
find any documentation for it.

Does anyone have any snippets or docs?

Thanks.

*** Sent via Developersdex http://www.developersdex.com ***

Reply With Quote
  #2  
Old   
David Portas
 
Posts: n/a

Default Re: Passing a Variable from VB.NET to a DTS Package - 04-04-2005 , 01:18 PM






You can pass the value in a Global Variable:

http://msdn.microsoft.com/library/en...papps_7rj7.asp

--
David Portas
SQL Server MVP
--


Reply With Quote
  #3  
Old   
Alejandro Mesa
 
Posts: n/a

Default RE: Passing a Variable from VB.NET to a DTS Package - 04-04-2005 , 01:19 PM



Jim,

Create glbal variables in your DTS package and pass values from the vb.net
application.

Execute a package from Visual Basic (VB)
http://www.sqldts.com/default.aspx?208,1

There is an example in Page 3.


AMB


"Jim James" wrote:

Quote:
I'd like to pass two date variables from a VB app to a "Transform Data
Task" in my DTS package. This seems to be an easy request, but I can't
find any documentation for it.

Does anyone have any snippets or docs?

Thanks.

*** Sent via Developersdex http://www.developersdex.com ***


Reply With Quote
  #4  
Old   
Jim James
 
Posts: n/a

Default RE: Passing a Variable from VB.NET to a DTS Package - 04-04-2005 , 05:04 PM



Thanks for the help. However, I can't even get to that point...

I am saving my DTS package as a VB file, but I can't get it to compile.
I'm receiving an error.

"Interface 'DTS.OleDBProperties' cannot be indexed because it has no
default property.

Do you know what this error could be in reference to?

Thanks.

*** Sent via Developersdex http://www.developersdex.com ***

Reply With Quote
  #5  
Old   
Jamie Thomson
 
Posts: n/a

Default Re: Passing a Variable from VB.NET to a DTS Package - 04-05-2005 , 01:32 PM



Jim,
If you want to execute a package from VB.Net there is no requirement to save
your package as a VB file.

Regards
Jamie Thomson
An SSIS blog - http://blogs.conchango.com/jamiethom...tegory/71.aspx


"Jim James" <rrichards (AT) exabyte (DOT) com> wrote

Quote:
Thanks for the help. However, I can't even get to that point...

I am saving my DTS package as a VB file, but I can't get it to compile.
I'm receiving an error.

"Interface 'DTS.OleDBProperties' cannot be indexed because it has no
default property.

Do you know what this error could be in reference to?

Thanks.

*** Sent via Developersdex http://www.developersdex.com ***



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.