i have following problem:
I'm trying to run your software via command line, so you can give the program parameters, but the problem is, when i'm trying to show the report, the preview-windo crashes. If i do it via GUI it works fine. Unfortunatly i have no Idea where the mistake is, maybe you can tell me. This is the sourcecode:
Code: Select all
Imports Stimulsoft.Report
Imports Stimulsoft.Report.Dictionary
Imports Stimulsoft.Base.Drawing
Imports Stimulsoft.Report.Components
Imports Stimulsoft.Base
Imports Stimulsoft.Base.Serializing
Imports Stimulsoft.Controls
Imports Stimulsoft.Report.CodeDom
Imports Stimulsoft.Report.Design
Module Module1
Dim paraDic As New Dictionary(Of String, String)
Sub Main()
Dim parm = Command()
Parameter(parm)
Dim Report As New StiReport
Report.Load(paraDic.Item("dir"))
Report.Show()
'Console.WriteLine(CompiledReportFileName)
Console.ReadLine()
End Sub
Sub Parameter(ByVal args As String)
Dim words As String() = args.ToString.Split("|")
Dim word As String
For Each word In words
'Console.WriteLine(word)
If word.Contains("dir") Then
Dim splitted As String() = word.Split("=")
paraDic.Add(splitted(0), splitted(1))
Console.WriteLine(splitted(1))
End If
If word.Contains("target") Then
Dim splitted As String() = word.Split("=")
paraDic.Add(splitted(0), splitted(1))
End If
Next
End Sub
End Module