I realised this shortly after posting that Example 2 is how my application should be being called & went searching for all the command line calls to the exe & added the double quotes around the entire 1 command line argument (as in Example 2) & it's been working well since.
The VB6 app code was...
Environment.GetCommandLineArgs() splits string with spaces in it sometimes but not others, want to avoid this.
EXAMPLE 1: command Line Arg (WRONG)
@rpt=D:Test.rpt,@dsn=Test.dsn,@export=pdf,@destination=D:\AutoRpt\Test.pdf,@@startd=-1,@@endd=0,@@whichclient=Joe Bloggs,@Email=no,@EmailParam=1...
Found & fixed problem... AddCurrentValue was expecting a date object but I was passing it a string, so the parameters weren't being set.
EXTRACTS of the PrintReport Sub in the VB.net code:
Case crDateTimeField
If UCase(strParamName2) =...
Command Line Project:
Export crystal report to file in pdf/excel/word format & optionally email it.
Command line args incl input parameters for the crystal report.
VB6 being converted to VB.net using Visual Basic 2005 Express Edition.
Creator has since left & I need to fix/edit the application...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.