code_junkie

Reporting Services keeps erasing my dataset parameters

Nov 13th, 2011
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.95 KB | None | 0 0
  1. <Query>
  2. <Method Namespace="http://www.abc.com/" Name="TWRPerformanceSummary"/>
  3. <SoapAction>http://www.abc.com/TWRPerformanceSummary</SoapAction>
  4. <ElementPath IgnoreNamespaces="true">
  5. TWRPerformanceSummaryResponse/TWRPerformanceSummaryResult/diffgram/NewDataSet/table{StockPerc,RiskBudget,Custodian,ProductName,StartValue(decimal),EndValue(decimal),CostBasis(decimal)}
  6. </ElementPath>
  7. </Query>
  8.  
  9. Guid passedGuid = new Guid(sessionID);
  10.  
  11. private static void addDummyRow(DataTable dt) {
  12. var row = dt.NewRow();
  13.  
  14. for (int i = 0; i < dt.Columns.Count; i++) {
  15. if (dt.Columns[i].DataType == typeof(string)) {
  16. row[i] = dt.Columns[i].ColumnName;
  17. }
  18. else if (dt.Columns[i].DataType == typeof(DateTime)) {
  19. row[i] = new DateTime(1900, 1, 1);
  20. }
  21. else {
  22. row[i] = 0;
  23. }
  24. }
  25.  
  26. dt.Rows.Add(row);
  27. }
Add Comment
Please, Sign In to add comment