VS 2008 [RESOLVED] Can't get Process.Start to work on IIS7/Server 2008 (oops it's SBS 2011!)-VBForums
Results 1 to 11 of 11

Thread: [RESOLVED] Can't get Process.Start to work on IIS7/Server 2008 (oops it's SBS 2011!)

Threaded View

  1. #1

    Thread Starter
    MS SQL Powerposter szlamany's Avatar
    Join Date
    Mar 2004

    Resolved [RESOLVED] Can't get Process.Start to work on IIS7/Server 2008 (oops it's SBS 2011!)

    [edit]actually it's SBS 2011[/edit]

    I cannot get PROCESS.START to work on a Server 2008 box - tried all kinds of credential settings - getting no where.

    I recently added the un/pw stuff - if I put a bad username it gives me an error - but with a good one nothing happens - the process never starts.

                    Dim strFile As String = "Report_" & rptid & ".bat"
                    Dim strBatFile As String = Path.Combine(strReportFolder, strFile)
                    Using fileWrtr = New StreamWriter(strBatFile, False)
                        fileWrtr.WriteLine("CD /D " & strReportFolder)
                        fileWrtr.WriteLine("set path=" & strReportFolder)
                        'fileWrtr.WriteLine("amc rpt/printers")
                    End Using
                    Dim psusername As String = "xxxxx"
                    Dim pspassword As SecureString = ConvertToSecureString("passwordxxxx")
                    Dim psdomain As String = "somedomain"
                    If blnSubmit Then
                            Process.Start(strBatFile, psusername, pspassword, psdomain)
                            .NewObject("rptid", rptid)
                            .NewObject("queued", IIf(blnSubmit, "N", "Y").ToString)
                        Catch ex As Win32Exception
                            .NewObject("%%dalerror%%", ex.Message)
                        Catch ex As Exception
                            .NewObject("%%dalerror%%", ex.Message)
                        End Try
                    End If
    Last edited by szlamany; Apr 1st, 2012 at 06:49 PM.

    *** Read the sticky in the DB forum about how to get your question answered quickly!! ***

    Please remember to rate posts! Rate any post you find helpful - even in old threads! Use the link to the left - "Rate this Post".

    Some Informative Links:
    [ SQL Rules to Live By ] [ Reserved SQL keywords ] [ When to use INDEX HINTS! ] [ Passing Multi-item Parameters to STORED PROCEDURES ]
    [ Solution to non-domain Windows Authentication ] [ Crazy things we do to shrink log files ] [ SQL 2005 Features ] [ Loading Pictures from DB ]

    MS MVP 2006, 2007, 2008

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts


Click Here to Expand Forum to Full Width