I would like to create a text file with from a report. here is my code so far....
'' Clear the existing Query Dim qryModel As QueryModel = proj.CreateQuery() qryModel.Clear() Dim qryBranch As New QueryBranch(Constants.JoinOperator.OperatorAnd) '' Property Condition Dim propertyCondition As PropertyCondition = New PropertyCondition propertyCondition.JoinOperator = Constants.JoinOperator.OperatorAnd propertyCondition.PropertyType = Constants.PropertyType.Layer propertyCondition.ConditionOperator = Constants.ConditionOperator.ConditionEqual propertyCondition.Value = "CP*" qryBranch.AppendOperand(propertyCondition) qryModel.Define(qryBranch) qryModel.Mode = Constants.QueryType.QueryReport qryModel.ReportTemplate.AddLine(":CIRCUIT@CIRCUIT"
) qryModel.ReportTemplate.AddLine(".DWGNAME") qryModel.Execute(dwgSet) qryModel.Run()
can you help me to send data to a text file?
Solved! Go to Solution.
is that the line you are missing (based on your code):
'last lines based on your code (after adding .DWGNAME):
'define your output file
qryModel.ReportTemplate.FileName = "C:\TEMP\ReportResult.TXT"
'removed ... qryModel.Execute(dwgSet)
- alfred -
Log into access your profile, ask and answer questions, share ideas and more. Haven't signed up yet? Register