<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Documentation – How to Use Smart Marker Variables and Expressions</title>
    <link>https://docs.aspose.com/cells/net/smartmarker-variable-expression-usage/</link>
    <description>Recent content in How to Use Smart Marker Variables and Expressions on Documentation</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    
	  <atom:link href="https://docs.aspose.com/cells/net/smartmarker-variable-expression-usage/index.xml" rel="self" type="application/rss+xml" />
    
    
      
        
      
    
    
    <item>
      <title>Net: Smartly Importing Master and Details Data into Excel With Smart Markers</title>
      <link>https://docs.aspose.com/cells/net/how-to-use-master-and-details-with-smart-markers/</link>
      <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate>
      
      <guid>https://docs.aspose.com/cells/net/how-to-use-master-and-details-with-smart-markers/</guid>
      <description>
        
        
        &lt;h2 id=&#34;possible-usage-scenarios&#34;&gt;&lt;strong&gt;Possible Usage Scenarios&lt;/strong&gt;&lt;/h2&gt;
&lt;p&gt;Sometimes, you want to generate dynamic Excel reports; it includes a comprehensive main dashboard and multiple fine‑grained detailed worksheets. Among them, a single main table presents an overview, which may showcase various product variants, and each corresponding detailed worksheet provides specific and in‑depth data for a single variant. Aspose.Cells can perfectly meet your needs through master and details with smart markers.&lt;/p&gt;
&lt;h2 id=&#34;smart-marker-parameters-for-master-and-details&#34;&gt;&lt;strong&gt;Smart Marker Parameters for Master and Details&lt;/strong&gt;&lt;/h2&gt;
&lt;p&gt;To import master and details data into Excel, you need to use the following smart marker parameters:&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Parameter&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;th&gt;Acceptable Values (Syntax)&lt;/th&gt;
&lt;th&gt;Restrictions&lt;/th&gt;
&lt;th&gt;Optionality&lt;/th&gt;
&lt;th&gt;Default Behavior&lt;/th&gt;
&lt;th&gt;Excel Constraints&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;DetailSheet&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Specify the name of the detail worksheet stored in the template file.&lt;/td&gt;
&lt;td&gt;String value&lt;/td&gt;
&lt;td&gt;Value must be null or the name of a worksheet. If null, this is a detail sheet. It should be a simple string value. Variable is not supported.&lt;/td&gt;
&lt;td&gt;If omitted, it is not a master or detail sheet.&lt;/td&gt;
&lt;td&gt;Normal worksheet, not a master or detail sheet.&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;DetailTable&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Specify the table name of the detail worksheet in the template file.&lt;/td&gt;
&lt;td&gt;String value&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;If omitted, the smart marker in the detail sheet should be similar to the master sheet; otherwise we cannot find the data source.&lt;/td&gt;
&lt;td&gt;If omitted, the smart marker in the detail sheet should be similar to the master sheet; otherwise we cannot find the data source.&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;DetailSheetNewName&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Specify the name of the newly created detail worksheet.&lt;/td&gt;
&lt;td&gt;Excel formula‑like expression&lt;/td&gt;
&lt;td&gt;It should be a valid Excel formula if we replace the variable ({a.bc}) with a simple value.&lt;/td&gt;
&lt;td&gt;If omitted, new sheets will be Sheet1, Sheet2…&lt;/td&gt;
&lt;td&gt;If omitted, new sheets will be Sheet1, Sheet2…&lt;/td&gt;
&lt;td&gt;The name must be a valid worksheet name.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;DetailLink&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Indicate whether to add hyperlinks to the location of the imported data.&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;If omitted, hyperlinks are not added to the location of the imported data.&lt;/td&gt;
&lt;td&gt;If omitted, hyperlinks are not added to the location of the imported data.&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2 id=&#34;how-to-use-master-and-details-when-master-and-details-are-in-one-worksheet&#34;&gt;&lt;strong&gt;How to Use Master and Details When Master and Details Are in One Worksheet&lt;/strong&gt;&lt;/h2&gt;
&lt;p&gt;Sometimes, you need to import master and details data to Excel in SmartMarkers. Aspose.Cells makes it possible to use master and details parameters in SmartMarkers. Please check the &lt;a href=&#34;MasterDetailInOneSheet.xlsx&#34;&gt;template file&lt;/a&gt;, the &lt;a href=&#34;MasterDetailData.json&#34;&gt;JSON file&lt;/a&gt;, and the screenshots of the output Excel file generated with the following code.&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;&lt;strong&gt;The first worksheet of the template.xlsx.&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;&lt;img src=&#34;1.png&#34; alt=&#34;todo:image_alt_text&#34;&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;&lt;strong&gt;The first worksheet of the output Excel file.&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;&lt;img src=&#34;2.png&#34; alt=&#34;todo:image_alt_text&#34;&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;&lt;strong&gt;The second worksheet of the output Excel file.&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;&lt;img src=&#34;3.png&#34; alt=&#34;todo:image_alt_text&#34;&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;strong&gt;JSON data as follows:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-json&#34; data-lang=&#34;json&#34;&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
	&lt;span class=&#34;nt&#34;&gt;&amp;#34;node&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
		&lt;span class=&#34;nt&#34;&gt;&amp;#34;Styles1&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleID&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;1style001&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleName&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;StyleName1&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;Quantity&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;6&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;UnitPrice&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mf&#34;&gt;18.45&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;MaterialType&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Cotton&amp;#34;&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
		&lt;span class=&#34;p&#34;&gt;],&lt;/span&gt;
		&lt;span class=&#34;nt&#34;&gt;&amp;#34;Styles2&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleID&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;2style001&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleName&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Cotton StyleName2&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;Quantity&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;6&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;UnitPrice&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mf&#34;&gt;18.45&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;MaterialType&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Cotton&amp;#34;&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;},&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleID&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;2style002&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleName&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Denim StyleName2&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;Quantity&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;8&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;UnitPrice&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mf&#34;&gt;58.8&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;MaterialType&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Denim&amp;#34;&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
		&lt;span class=&#34;p&#34;&gt;]&lt;/span&gt;
	&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The example that follows shows how this works.&lt;/p&gt;
&lt;script type=&#34;application/javascript&#34; src=&#34;https://gist.github.com/aspose-cells-gists/59a1901d62ea9ceb08456a818431a898.js?file=SmartMarkers-Using-Master-Details-InOneSheet.cs&#34;&gt;&lt;/script&gt;

&lt;h2 id=&#34;how-to-use-master-and-details-when-master-and-details-are-in-different-worksheets&#34;&gt;&lt;strong&gt;How to Use Master and Details When Master and Details Are in Different Worksheets&lt;/strong&gt;&lt;/h2&gt;
&lt;p&gt;Sometimes, you need to import master and details data to Excel in SmartMarkers. Aspose.Cells makes it possible to use master and details parameters in SmartMarkers. Please check the &lt;a href=&#34;MasterDetailInTwoSheets.xlsx&#34;&gt;template file&lt;/a&gt;, the &lt;a href=&#34;MasterDetailData.json&#34;&gt;JSON file&lt;/a&gt;, and the screenshots of the output Excel file generated with the following code.&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;&lt;strong&gt;The first master worksheet of the template.xlsx.&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;&lt;img src=&#34;4.png&#34; alt=&#34;todo:image_alt_text&#34;&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;&lt;strong&gt;The second master worksheet of the template.xlsx.&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;&lt;img src=&#34;5.png&#34; alt=&#34;todo:image_alt_text&#34;&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;&lt;strong&gt;The detail worksheet of the template.xlsx.&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;&lt;img src=&#34;6.png&#34; alt=&#34;todo:image_alt_text&#34;&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;&lt;strong&gt;The first master worksheet of the output Excel file.&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;&lt;img src=&#34;7.png&#34; alt=&#34;todo:image_alt_text&#34;&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;&lt;strong&gt;The second master worksheet of the output Excel file.&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;&lt;img src=&#34;8.png&#34; alt=&#34;todo:image_alt_text&#34;&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;&lt;strong&gt;The detail worksheet of the first master worksheet in the output Excel file.&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;&lt;img src=&#34;9.png&#34; alt=&#34;todo:image_alt_text&#34;&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;&lt;strong&gt;The first detail worksheet of the second master worksheet in the output Excel file.&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;&lt;img src=&#34;10.png&#34; alt=&#34;todo:image_alt_text&#34;&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th style=&#34;text-align:left&#34;&gt;&lt;strong&gt;The second detail worksheet of the second master worksheet in the output Excel file.&lt;/strong&gt;&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td style=&#34;text-align:left&#34;&gt;&lt;img src=&#34;11.png&#34; alt=&#34;todo:image_alt_text&#34;&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;strong&gt;JSON data as follows:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-json&#34; data-lang=&#34;json&#34;&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
	&lt;span class=&#34;nt&#34;&gt;&amp;#34;node&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
		&lt;span class=&#34;nt&#34;&gt;&amp;#34;Styles1&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleID&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;1style001&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleName&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;StyleName1&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;Quantity&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;6&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;UnitPrice&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mf&#34;&gt;18.45&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;MaterialType&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Cotton&amp;#34;&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
		&lt;span class=&#34;p&#34;&gt;],&lt;/span&gt;
		&lt;span class=&#34;nt&#34;&gt;&amp;#34;Styles2&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleID&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;2style001&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleName&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Cotton StyleName2&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;Quantity&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;6&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;UnitPrice&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mf&#34;&gt;18.45&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;MaterialType&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Cotton&amp;#34;&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;},&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleID&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;2style002&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;StyleName&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Denim StyleName2&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;Quantity&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;8&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;UnitPrice&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mf&#34;&gt;58.8&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
				&lt;span class=&#34;nt&#34;&gt;&amp;#34;MaterialType&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Denim&amp;#34;&lt;/span&gt;
			&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
		&lt;span class=&#34;p&#34;&gt;]&lt;/span&gt;
	&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The example that follows shows how this works.&lt;/p&gt;
&lt;script type=&#34;application/javascript&#34; src=&#34;https://gist.github.com/aspose-cells-gists/59a1901d62ea9ceb08456a818431a898.js?file=SmartMarkers-Using-Master-Details-InDifferentSheets.cs&#34;&gt;&lt;/script&gt;


      </description>
    </item>
    
    <item>
      <title>Net: How to Use If Parameter and Variables in SmartMarkers</title>
      <link>https://docs.aspose.com/cells/net/how-to-use-if-parameter-and-variables-in-smart-markers/</link>
      <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate>
      
      <guid>https://docs.aspose.com/cells/net/how-to-use-if-parameter-and-variables-in-smart-markers/</guid>
      <description>
        
        
        &lt;h1 id=&#34;how-to-use-smartmarker-if-variable-conditions-to-filter-data&#34;&gt;How to Use SmartMarker IF Variable Conditions to Filter Data&lt;/h1&gt;
&lt;h2 id=&#34;1-feature-overview&#34;&gt;1. Feature Overview&lt;/h2&gt;
&lt;p&gt;SmartMarker supports dynamic data filtering through &lt;strong&gt;IF conditions&lt;/strong&gt; to control whether row data is rendered in reports. This feature fully supports two standard IF condition methods: direct field expression writing and boolean variable writing defined in the variable worksheet. Users can reference boolean expression variables preset in the variable worksheet directly in IF judgments.&lt;/p&gt;
&lt;p&gt;Users can either write filter expressions directly in cells or encapsulate complex range judgments, status checks, and multi-condition combination logic into global variables for reuse in templates, effectively organizing scattered conditional logic and simplifying the maintenance of complex report templates.&lt;/p&gt;
&lt;h2 id=&#34;2-feature-benefits&#34;&gt;2. Feature Benefits&lt;/h2&gt;
&lt;p&gt;IF variable condition filtering optimizes the data filtering capability of SmartMarker, bringing the following core advantages:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Unified conditional logic management&lt;/strong&gt;: All data filtering rules, boolean judgments and range checks are centrally configured in the variable worksheet, instead of being scattered in display cells.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Global reuse of filter rules&lt;/strong&gt;: Defined boolean condition variables can be referenced repeatedly across the entire report template without rewriting complex expressions.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Lower maintenance costs&lt;/strong&gt;: When business filter rules change, only the variable worksheet configuration needs to be updated, without modifying template markers in batches.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Support for complex combined conditions&lt;/strong&gt;: Custom multi-field and multi-logic composite judgments are supported, and variables can be nested in AND / OR logical functions.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Cleaner template structure&lt;/strong&gt;: Display cells only reference variable names without lengthy judgment expressions, making templates neat and readable.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&#34;3-usage-guide&#34;&gt;3. Usage Guide&lt;/h2&gt;
&lt;p&gt;General workflow: Define boolean condition variables in the variable worksheet → Reference variables through IF conditions in template cells → Enable the variable worksheet and render with code.&lt;/p&gt;
&lt;h3 id=&#34;31-variable-worksheet-configuration-rules&#34;&gt;3.1 Variable Worksheet Configuration Rules&lt;/h3&gt;
&lt;p&gt;In the independent variables worksheet, define all data filtering logic as&lt;strong&gt;expression-type variables&lt;/strong&gt;, supporting single-condition judgment and complex multi-field combined judgment.&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Scope&lt;/th&gt;
&lt;th&gt;Name&lt;/th&gt;
&lt;th&gt;Variable Name&lt;/th&gt;
&lt;th&gt;Variable Value&lt;/th&gt;
&lt;th&gt;Type&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Worksheet&lt;/td&gt;
&lt;td&gt;Template&lt;/td&gt;
&lt;td&gt;booksUpto100Check&lt;/td&gt;
&lt;td&gt;{node.books.price} &amp;amp;lt;= 100&lt;/td&gt;
&lt;td&gt;Expression&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Worksheet&lt;/td&gt;
&lt;td&gt;Template&lt;/td&gt;
&lt;td&gt;booksAbove200Check&lt;/td&gt;
&lt;td&gt;{node.books.price} &amp;amp;gt; 200&lt;/td&gt;
&lt;td&gt;Expression&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Worksheet&lt;/td&gt;
&lt;td&gt;Template&lt;/td&gt;
&lt;td&gt;bookAvailable&lt;/td&gt;
&lt;td&gt;{node.books.isAvailable} = true&lt;/td&gt;
&lt;td&gt;Expression&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h3 id=&#34;32-template-marker-syntax&#34;&gt;3.2 Template Marker Syntax&lt;/h3&gt;
&lt;p&gt;SmartMarker IF conditions support multiple standard syntaxes. You can use direct field expressions or reference pre-defined boolean variables and composite logic variables in the variable worksheet to adapt to different template development scenarios.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;1. Field Expression Condition&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Marker Syntax: &lt;code&gt;\&amp;amp;amp;=node\.books\.price\(if:\{node\.books\.price\} \&amp;amp;lt;= 100\)&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Marker Syntax: &lt;code&gt;\&amp;amp;amp;=bookPrice\(if:\{bookPrice\} \&amp;amp;lt;= 100\)&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Function: Write complete field judgment expressions directly in IF parameters to implement data filtering.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;2. Boolean Variable Condition&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Marker Syntax: &lt;code&gt;\&amp;amp;amp;=node\.books\.price\(if:\{booksUpto100Check\}\)&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Function: Reference pre-defined boolean expression variables in the variable worksheet to reuse conditional logic and simplify template markers.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;3. Direct Boolean Variable Output&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Marker Syntax: &lt;code&gt;\&amp;amp;amp;=\{booksUpto100\}&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Marker Syntax: &lt;code&gt;\&amp;amp;amp;=booksUpto100&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Function: Directly render boolean variable results to display conditional judgment values.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;4. Multi-Variable Combined Condition&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Marker Syntax: &lt;code&gt;\&amp;amp;amp;=node\.books\.price\(if:AND\(\{bookAvailable\},\{booksAbove200Check\}\)\)&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;Function: Combine multiple boolean variables with AND/OR logical functions to implement complex multi-condition data filtering.&lt;/p&gt;
&lt;h3 id=&#34;33-core-implementation-code&#34;&gt;3.3 Core Implementation Code&lt;/h3&gt;
&lt;p&gt;Specify the variable worksheet name to enable variable parsing, allowing SmartMarker to recognize custom boolean variables in IF conditions correctly.&lt;/p&gt;
&lt;h2 id=&#34;4-important-notes&#34;&gt;4. Important Notes&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Exact Worksheet Name Matching&lt;/strong&gt;: The name assigned to &lt;code&gt;VariablesWorksheetName&lt;/code&gt; must strictly match the name of the custom variable worksheet. Otherwise, the engine cannot resolve custom boolean variables in IF conditions.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Valid Boolean Expression Definition&lt;/strong&gt;: Variables used in IF conditions must return standard boolean results (true/false). Ensure the configured expression logic is complete and correct to avoid empty or incorrect filtering results.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Standard Logical Function Usage&lt;/strong&gt;: When combining multiple variables with &lt;code&gt;AND\(\)&lt;/code&gt; or &lt;code&gt;OR\(\)&lt;/code&gt;, all parameters inside the function must be valid boolean variables or boolean expressions to ensure normal parsing.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Correct Variable Reference Syntax&lt;/strong&gt;: When referencing variables in IF parameters, use the standard format &lt;code&gt;if:\{variableName\}&lt;/code&gt;. Missing braces or incorrect variable names will lead to parsing failure.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Unified Data Source Prefix&lt;/strong&gt;: The field prefix defined in the variable expression must be consistent with the root data source name bound by &lt;code&gt;SetDataSource&lt;/code&gt;, preventing field resolution errors caused by inconsistent data source paths.&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;

      </description>
    </item>
    
  </channel>
</rss>
