I am using this basic code to run a DTS package. Dim oPKG As New DTS.Package With oPKG .LoadFromSQLServer("DEV", , , _ DTS.DTSSQLServerStorageFlags.DTSSQLStgFlag_UseTrustedConnection, _ , , , "HR_LoadData") oPKG.Execute() oPKG.UnInitialize() oPKG = Nothing End With It works so great I would now like to run some DTS packages that reside in sql server on a different domain. What code do I need to get to a different domain?
leezardd
Posts
-
run dts package on different domain -
FTP using WININET.DLLHelp! I am using something I don't understand and need some direction. I am trying to use "WININET.DLL" to ftp a file. I know the function FtpPutFile returns false but I don't know why. How can I find out why? Below is a code snippet of what I am doing. All help is greatly appreciated!
Public Function bolFtpUpload(ByVal............... bolFtpAction = FtpPutFile(intNetConn, _ strLocalFile, _ strRemoteDirectory, _ intTransferTypeFlag, _ intContext) If bolFtpAction = False Then "Transfer failed " Else "Transfer Succeeded " End If End Function Private Declare Function FtpPutFile Lib "WININET.DLL" _ Alias "FtpPutFileA" (ByVal intFtpSession As Integer, _ ByVal strLocalFile As String, _ ByVal strRemoteFile As String, _ ByVal intFlags As Integer, _ ByVal intContext As Integer) As Boolean
-
passing a dataset...where's my data?Using item still places SpcInstr in the text of the label. I am trying to get the value from the column named "SpcInstr". Any other suggestions?
-
passing a dataset...where's my data?Using the rows property makes sense, but now it brings up the question of how I actually retrieve the data from the dataset. As you can probably tell I am new at this. What code do I need to add to my form to get this to work? Thanks!
-
passing a dataset...where's my data?I am trying to separate my data access code from my form code. I have a created a data access class containing a function to accept an EmployeeID and return a dataset containing just information for that employee. When I try to display the employee information on the form I am getting the column name rather than the value contained in the column. What am I doing wrong? Form Code
Private Sub frmMaint_Load(ByVal sender As Object, _ ByVal e As System.EventArgs) Handles MyBase.Load Try dsSpcInstrFRM = m_DAL.SpecialInstructions(strEmpIdFromChooseFrm) dtSpcInstrFRM = dsSpcInstrFRM.Tables("SpcInstructions") lblSpcInstructions.Text = dtSpcInstrFRM.Columns("SpcInstr").ToString Catch ex As Exception ‘Error Routine End Try End Sub
Data Access CodeFriend Function SpecialInstructions(ByVal m_strEmpID As String) As Dataset Dim sqlRiskDR As SqlDataReader Dim SpecialInstructionsDS As New DataSet Dim SpcInstrDT As New DataTable Dim SpcInstrDR As DataRow Try sqlRiskCN = New SqlConnection(My.Settings.SQLRiskCNString) sqlRiskCN.Open() 'Use Stored Procedure strSql = "GetSpecialInstructions " & "'" & m_strEmpID & " '" sqlCM = New SqlCommand(strSql, sqlRiskCN) sqlRiskDR = sqlCM.ExecuteReader() SpecialInstructionsDS.DataSetName = "SpecialInstructions" SpecialInstructionsDS.Tables.Add(SpcInstrDT) SpcInstrDT.TableName = "SpcInstructions" SpcInstrDT.Columns.Add("EmpID").Unique = False SpcInstrDT.Columns.Add("SpcInstr") Do While sqlRiskDR.Read() SpcInstrDR = SpcInstrDT.NewRow SpcInstrDR.Item("EmpID") = sqlRiskDR.Item("EmpID").ToString SpcInstrDR.Item("SpcInstr") = sqlRiskDR.Item("EmergInstructions").ToString.TrimEnd SpcInstrDT.Rows.Add(SpcInstrDR) Loop sqlRiskDR.Close() sqlRiskCN.Close() Catch ex As Exception ‘Error Routine End Try Return SpecialInstructionsDS End Function
-
update Access DBYour "write access" tip led me in the right direction. Turns out "users" did not have write permission to one of the folders in the path to the database. Thanks a bunch!
-
update Access DBWhen I try to run an update query via ASP to an Access DB, I get the error below. The insert query works fine when I run it from Access, but not ASP. I can read from the DB fine, but can't write to it. Error Type: Microsoft OLE DB Provider for ODBC Drivers (0x80004005) [Microsoft][ODBC Microsoft Access Driver] Operation must use an updateable query. /Tutorial/guestbook.asp, line 43 Code: <% @Language=VBScript %> Guest Book <% IF request.form ("Message")="True" THEN strTB1=request.form("To") strTB2=request.form("EMailAdd") strTB3=request.form("CC") strTB4=request.form("Subject") strMB1=request.form("Memo") IF strMB1 = "" THEN iLenMB1=255 ELSE iLenMB1 = Len(strMB1) END IF 'Connects to the Access driver and Access database in the Inetpub 'directory where the database is saved strProvider = "Driver={Microsoft Access Driver (*.mdb)};DBQ=C:\Inetpub\Wwwroot\Tutorial\guestbook.mdb;" 'Creates an instance of an Active Server component set objConn = server.createobject("ADODB.Connection") 'Opens the connection to the data store objConn.Open strProvider 'Instantiate Command object and use ActiveConnection property to 'attach connection to Command object set cm = Server.CreateObject("ADODB.Command") cm.ActiveConnection = objConn 'Define SQL query cm.CommandText ="INSERT INTO Guestbook (TB1,TB2,TB3,TB4,MB1) VALUES (?,?,?,?,?)" 'Define query parameter configuration information for guestbook fields set objparam=cm.createparameter(, 200, , 255, strTB1) cm.parameters.append objparam set objparam=cm.createparameter(, 200, , 255, strTB2) cm.parameters.append objparam set objparam=cm.createparameter(, 200, , 255, strTB3) cm.parameters.append objparam set objparam=cm.createparameter(, 200, , 255, strTB4) cm.parameters.append objparam set objparam=cm.createparameter(, 201, , iLenMB1, strMB1) cm.parameters.append objparam cm.execute response.write("Thank you!") ELSE%>
Guestbook
To
Email Address
CC
Subject
Message
<%En
-
Errors from DTS packageI used the DTS wizard to create a DTS package transforming data from a text file into a Sql table. I have a client trying to run the package that does not have access rights to where the data source is located. The package does not give me any indication of an error, just doesn’t do the transformation. How do I handle errors in packages?
-
"COM object with CLSID {10020200-EB1C-11CF-AE6E-00AA004A34D5} is either notExactly what I needed. Thanks :-D
-
"COM object with CLSID {10020200-EB1C-11CF-AE6E-00AA004A34D5} is either notI created a dts package that imports data into sqlserver. I run the dts package from a vb.net application on a machine that does not have sqlserver installed. I get the error quoted above. I used an installer project to install my vb.net application on the machine running the application. Included in the folder with my exe is dtspkg.dll, Interop.DTS.dll, as well as some other config and dll files. Why am I getting this error?
-
Center image in picture box?Worked perfectly. Thanks! :)
-
Center image in picture box?I have the following simple code to place a background image and an animated image in a picture box. How can I get the animated image to be centered in the picture box? Dim myPBImage As Bitmap = New Bitmap("Dog.gif") Dim myPBBkgrd As Bitmap = New Bitmap("BackYardBkgrd.jpg") PictureBox1.BackgroundImage = CType((myPBBkgrd), System.Drawing.Image) ImageAnimator.Animate(myPBImage, New EventHandler(AddressOf OnFrameChange)) PictureBox1.Image = CType((myPBImage), System.Drawing.Image)
-
Install windows service applicationThank you...again.
-
Install windows service applicationI have developed a windows service application that I want to deploy on another machine. The machine does not have Visual Studio installed, it does have the framework redistributable installed. When I try to install the service I am receiving the following error: “Installutil” is not recognized as an internal or external command, operable program or batch file. How do I get the Installutil on the machine?
-
Windows Service App starting other appsThanks for your help. Now that I understand the choices I can decide how to set up the service. :-D
-
Windows Service App starting other appsI understand why am getting the error. I don't want my service to interact with the desktop. How can my service start a new application so that the new application can interact with the desktop not my service? Thanks!
-
Windows Service App starting other appsI am writing a windows service app to monitor for files that change. If I determine a file has changed I want to start another application that runs independent of the service app. Currently I have tried to use the Process.Start. When the newly started application encountered an error (that displays a message box) the error message ”It is invalid to show a modal dialog or form when the application is not running in UserInteractive mode. Specify the ServiceNotification or DefaultDesktopOnly style to display a notification from a service application” was returned. I only want the service app to be responsible for starting the new application. How can I kick off the new application with no ties back to the service app?
-
Crystal Reports using Formula Editor to format dateDo you have the answer?
-
Crystal Reports using Formula Editor to format dateDoes anyone know how to format a date to October 02, 2004 when the incoming data is 10/02/2004? (Using Basic Syntax not Crystal Syntax) The following code works in vb.net but I can't figure out what the correct syntax would be in the formula editor. Dim dteSDate As Date = csvDataRow.Item("SDATE") Dim strFormatSDate As String = Format(dteSDate, "MMMM dd, yyyy")") All help is greatly appreciated!
-
? how to create a link in emailThe application sends an email using SMTP. The recipient is using Outlook.