<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: is there any way to get all visible fields and visible variables on the form using a business ru in Developer forum</title>
    <link>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592884#M1262895</link>
    <description>&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;P class=""&gt;Yes, it’s possible, but a Business Rule can’t directly know the client-side visibility of fields. You can use GlideRecord and dictionary metadata for fields, and access the record producer variables separately.&lt;/P&gt;&lt;P&gt;I’d recommend having the Business Rule call a Script Include that collects the required label/value pairs, generates the PDF, and attaches it with GlideSysAttachment.&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Mon, 31 Aug 2026 06:31:36 GMT</pubDate>
    <dc:creator>masonreed11</dc:creator>
    <dc:date>2026-08-31T06:31:36Z</dc:date>
    <item>
      <title>is there any way to get all visible fields and visible variables on the form using a business rule</title>
      <link>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592755#M1262863</link>
      <description>&lt;P&gt;&lt;BR /&gt;Hi,&lt;BR /&gt;&lt;BR /&gt;I have a task record that being created using a record producer.&lt;BR /&gt;&lt;BR /&gt;Is there any way to get all visible &lt;STRONG&gt;fields&lt;/STRONG&gt; and all visible &lt;STRONG&gt;variables&lt;/STRONG&gt; on the form using a business rule.&lt;BR /&gt;The goal is to make a pdf file and attach it to the record that will contains all visible fields and visible variables and there corresponding values&lt;/P&gt;</description>
      <pubDate>Sun, 30 Aug 2026 16:06:12 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592755#M1262863</guid>
      <dc:creator>Alon Grod</dc:creator>
      <dc:date>2026-08-30T16:06:12Z</dc:date>
    </item>
    <item>
      <title>Re: is there any way to get all visible fields and visible variables on the form using a business ru</title>
      <link>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592771#M1262867</link>
      <description>&lt;P&gt;A business rule runs server-side and has no concept of "visible on the form" - visibility comes from the view/section layout, ACLs and client-side UI policies. The closest server-side definition is: fields in the form section layout, readable by the user, and non-empty. Variables are separate.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1) Fields on the form view - read the section layout:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;function getViewFields(tableName, viewName) {&lt;/P&gt;&lt;P&gt;&amp;nbsp; var out = [];&lt;/P&gt;&lt;P&gt;&amp;nbsp; var sec = new GlideRecord('sys_ui_section');&lt;/P&gt;&lt;P&gt;&amp;nbsp; sec.addQuery('name', tableName);&lt;/P&gt;&lt;P&gt;&amp;nbsp; sec.addQuery('view.name', viewName || 'Default view');&lt;/P&gt;&lt;P&gt;&amp;nbsp; sec.query();&lt;/P&gt;&lt;P&gt;&amp;nbsp; while (sec.next()) {&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; var el = new GlideRecord('sys_ui_element');&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; el.addQuery('sys_ui_section', sec.getUniqueValue());&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; el.addNotNullQuery('element');&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; el.orderBy('position');&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; el.query();&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; while (el.next()) out.push(el.getValue('element'));&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp; return out;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;2) In the rule, resolve label/value and respect read access:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;var rows = [];&lt;/P&gt;&lt;P&gt;var fields = getViewFields(current.getTableName(), 'Default view');&lt;/P&gt;&lt;P&gt;for (var i = 0; i &amp;lt; fields.length; i++) {&lt;/P&gt;&lt;P&gt;&amp;nbsp; var ge = current.getElement(fields[i]);&lt;/P&gt;&lt;P&gt;&amp;nbsp; if (!ge || !ge.canRead()) continue;&lt;/P&gt;&lt;P&gt;&amp;nbsp; var val = current.getDisplayValue(fields[i]);&lt;/P&gt;&lt;P&gt;&amp;nbsp; if (!val) continue;&lt;/P&gt;&lt;P&gt;&amp;nbsp; rows.push({label: ge.getLabel(), value: val});&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If layout does not matter, just loop current.getFields() with canRead() and nil() checks.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;3) Record producer variables: mapped ones are already fields. Unmapped ones live in question_answer against the created record:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;var qa = new GlideRecord('question_answer');&lt;/P&gt;&lt;P&gt;qa.addQuery('table_name', current.getTableName());&lt;/P&gt;&lt;P&gt;qa.addQuery('table_sys_id', current.getUniqueValue());&lt;/P&gt;&lt;P&gt;qa.query();&lt;/P&gt;&lt;P&gt;while (qa.next()) rows.push({label: qa.question.getDisplayValue(), value: qa.getDisplayValue('value')});&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Skip Label/Container/HTML variable types.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;4) PDF: build HTML from rows and convert/attach with sn_pdfgeneratorutils.PDFGenerationAPI (or GlideDocumentV2 on older releases). Do it in an async business rule so the record and its question_answer rows are committed.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Caveat: fields hidden only by a UI policy or client script cannot be detected server-side. If that matters, collect the list client-side by looping g_form.getFieldNames() with g_form.isVisible(), pass it in via a hidden field or GlideAjax, and have the rule use that list.&lt;/P&gt;</description>
      <pubDate>Sun, 30 Aug 2026 18:51:49 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592771#M1262867</guid>
      <dc:creator>mohithreddy</dc:creator>
      <dc:date>2026-08-30T18:51:49Z</dc:date>
    </item>
    <item>
      <title>Re: is there any way to get all visible fields and visible variables on the form using a business ru</title>
      <link>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592822#M1262882</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/406401"&gt;@Alon Grod&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;As far as i know&amp;nbsp;&lt;SPAN&gt;no, because Business Rules run entirely on the server and have no awareness of client-side form layouts or visibility.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;You must use a client-side script (such as an &lt;/SPAN&gt;&lt;SPAN&gt;⁠onSubmit⁠&lt;/SPAN&gt;&lt;SPAN&gt; script using &lt;/SPAN&gt;&lt;SPAN&gt;⁠g_form.isVisible()⁠&lt;/SPAN&gt;&lt;SPAN&gt;) to gather visible fields and pass them to the server.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 30 Aug 2026 23:38:04 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592822#M1262882</guid>
      <dc:creator>Rafael Batistot</dc:creator>
      <dc:date>2026-08-30T23:38:04Z</dc:date>
    </item>
    <item>
      <title>Re: is there any way to get all visible fields and visible variables on the form using a business ru</title>
      <link>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592834#M1262887</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/406401"&gt;@Alon Grod&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P class=""&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes, you can achieve this, but there is an important distinction: &lt;STRONG&gt;a Business Rule runs server-side, so it cannot directly know which fields are visually visible on the user's form&lt;/STRONG&gt;. Visibility controlled by UI Policies, Client Scripts, or form configuration is a client-side concept.&lt;/P&gt;&lt;P&gt;For the &lt;STRONG&gt;record fields&lt;/STRONG&gt;, you can use getElements() / getFields() to iterate through the fields on the record. ServiceNow's GlideRecord.getElements() returns the fields available on the GlideRecord.&lt;/P&gt;&lt;P&gt;For the &lt;STRONG&gt;Record Producer variables&lt;/STRONG&gt;, you can access them through current.variables. ServiceNow also provides current.variables.getElements() to iterate through the variables associated with the record, including their labels and values.&lt;/P&gt;&lt;P&gt;For example:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;PRE&gt;&lt;SPAN class=""&gt;// Record fields&lt;/SPAN&gt;
&lt;SPAN class=""&gt;var&lt;/SPAN&gt; &lt;SPAN class=""&gt;fields&lt;/SPAN&gt; &lt;SPAN class=""&gt;=&lt;/SPAN&gt; &lt;SPAN class=""&gt;current&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;getElements();

&lt;/SPAN&gt;&lt;SPAN class=""&gt;for&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN&gt;&lt;SPAN class=""&gt;var&lt;/SPAN&gt; &lt;SPAN class=""&gt;i&lt;/SPAN&gt; &lt;SPAN class=""&gt;=&lt;/SPAN&gt; &lt;SPAN class=""&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;; &lt;/SPAN&gt;&lt;SPAN class=""&gt;i&lt;/SPAN&gt; &lt;SPAN class=""&gt;&amp;lt;&lt;/SPAN&gt; &lt;SPAN class=""&gt;fields&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;size(); &lt;/SPAN&gt;&lt;SPAN class=""&gt;i&lt;/SPAN&gt;&lt;SPAN class=""&gt;++&lt;/SPAN&gt;&lt;SPAN&gt;) {
    &lt;/SPAN&gt;&lt;SPAN class=""&gt;var&lt;/SPAN&gt; &lt;SPAN class=""&gt;field&lt;/SPAN&gt; &lt;SPAN class=""&gt;=&lt;/SPAN&gt; &lt;SPAN class=""&gt;fields&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;get(&lt;/SPAN&gt;&lt;SPAN class=""&gt;i&lt;/SPAN&gt;&lt;SPAN&gt;);

    &lt;/SPAN&gt;&lt;SPAN class=""&gt;gs&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;info(
        &lt;/SPAN&gt;&lt;SPAN class=""&gt;field&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;getLabel() &lt;/SPAN&gt;&lt;SPAN class=""&gt;+&lt;/SPAN&gt; &lt;SPAN class=""&gt;' = '&lt;/SPAN&gt; &lt;SPAN class=""&gt;+&lt;/SPAN&gt;
        &lt;SPAN class=""&gt;field&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;getDisplayValue()
    );
}

&lt;/SPAN&gt;&lt;SPAN class=""&gt;// Record Producer variables&lt;/SPAN&gt;
&lt;SPAN class=""&gt;var&lt;/SPAN&gt; &lt;SPAN class=""&gt;variables&lt;/SPAN&gt; &lt;SPAN class=""&gt;=&lt;/SPAN&gt; &lt;SPAN class=""&gt;current&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;variables&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;getElements();

&lt;/SPAN&gt;&lt;SPAN class=""&gt;for&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN&gt;&lt;SPAN class=""&gt;var&lt;/SPAN&gt; &lt;SPAN class=""&gt;j&lt;/SPAN&gt; &lt;SPAN class=""&gt;=&lt;/SPAN&gt; &lt;SPAN class=""&gt;0&lt;/SPAN&gt;&lt;SPAN&gt;; &lt;/SPAN&gt;&lt;SPAN class=""&gt;j&lt;/SPAN&gt; &lt;SPAN class=""&gt;&amp;lt;&lt;/SPAN&gt; &lt;SPAN class=""&gt;variables&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;length; &lt;/SPAN&gt;&lt;SPAN class=""&gt;j&lt;/SPAN&gt;&lt;SPAN class=""&gt;++&lt;/SPAN&gt;&lt;SPAN&gt;) {
    &lt;/SPAN&gt;&lt;SPAN class=""&gt;var&lt;/SPAN&gt; &lt;SPAN class=""&gt;variable&lt;/SPAN&gt; &lt;SPAN class=""&gt;=&lt;/SPAN&gt; &lt;SPAN class=""&gt;variables&lt;/SPAN&gt;&lt;SPAN&gt;[&lt;/SPAN&gt;&lt;SPAN class=""&gt;j&lt;/SPAN&gt;&lt;SPAN&gt;];

    &lt;/SPAN&gt;&lt;SPAN class=""&gt;gs&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;info(
        &lt;/SPAN&gt;&lt;SPAN class=""&gt;variable&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;getLabel() &lt;/SPAN&gt;&lt;SPAN class=""&gt;+&lt;/SPAN&gt; &lt;SPAN class=""&gt;' = '&lt;/SPAN&gt; &lt;SPAN class=""&gt;+&lt;/SPAN&gt;
        &lt;SPAN class=""&gt;variable&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;getQuestion()&lt;/SPAN&gt;&lt;SPAN class=""&gt;.&lt;/SPAN&gt;&lt;SPAN&gt;getValue()
    );
}&lt;/SPAN&gt;&lt;/PRE&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;PRE&gt;&amp;nbsp;&lt;/PRE&gt;&lt;P&gt;However, I &lt;STRONG&gt;wouldn't recommend trying to determine "visible" fields from the Business Rule&lt;/STRONG&gt;. If you need the PDF to represent exactly what the user saw on the Record Producer, you should base the PDF generation on the &lt;STRONG&gt;Record Producer/variable configuration&lt;/STRONG&gt;, rather than the resulting task form.&lt;/P&gt;&lt;P&gt;A cleaner architecture would be:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Record Producer → Task created → After Business Rule/Flow → Generate document → Attach PDF&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;You can build the PDF content from:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Task fields you want to include&lt;/LI&gt;&lt;LI&gt;Record Producer variables&lt;/LI&gt;&lt;LI&gt;Variable labels&lt;/LI&gt;&lt;LI&gt;Display values&lt;/LI&gt;&lt;LI&gt;Conditional logic for variables that were actually answered&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Also, ServiceNow provides GlideSPScriptable.getRecordVariables() specifically for retrieving Service Catalog variables associated with records created through a Record Producer.&lt;/P&gt;&lt;P&gt;So, &lt;STRONG&gt;yes, dynamically collecting the fields and variables is possible&lt;/STRONG&gt;, but &lt;STRONG&gt;"visible on the form" cannot reliably be determined by a server-side Business Rule&lt;/STRONG&gt; because UI Policies and Client Scripts aren't evaluated there.&lt;/P&gt;&lt;P&gt;For a PDF requirement, I'd recommend creating a &lt;STRONG&gt;Script Include/utility that builds a field-variable data structure&lt;/STRONG&gt;, then passing that to your PDF/document generation logic. This will be much easier to maintain than putting all the PDF logic directly inside the Business Rule.&lt;/P&gt;</description>
      <pubDate>Mon, 31 Aug 2026 04:19:21 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592834#M1262887</guid>
      <dc:creator>ajmalmuhamm</dc:creator>
      <dc:date>2026-08-31T04:19:21Z</dc:date>
    </item>
    <item>
      <title>Re: is there any way to get all visible fields and visible variables on the form using a business ru</title>
      <link>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592859#M1262892</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/406401"&gt;@Alon Grod&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;Business Rule runs server-side, it cannot directly determine whether a field or Record Producer variable was visible on the user's form.you can use client side&amp;nbsp; APIs &lt;/SPAN&gt;&lt;SPAN&gt;g_form.isVisible()&lt;/SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;For&amp;nbsp; task fields using &lt;/SPAN&gt;&lt;SPAN&gt;current.getElements()&lt;/SPAN&gt;&lt;SPAN&gt; and the Record Producer variables using:&lt;/SPAN&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;var variables = current.variables.getElements();

for (var i = 0; i &amp;lt; variables.length; i++) {

    gs.info(variables[i].getLabel() + ' = ' + variables[i].getValue());

}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;For&amp;nbsp; PDF to contain exactly what was visible to the user at submission time, the better approach is to capture the visible fields/variables on the client side and store them .&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Then the Business Rule can read that data, generate the PDF, and attach it to the task.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;*************************************************************************************************************************************&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;If this response helps, please mark it as Accept as Solution and Helpful.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Doing so helps others in the community and encourages me to keep contributing.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Regards&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Vaishali Singh&lt;/STRONG&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;STRONG&gt;Linkedin - &lt;/STRONG&gt;&lt;A href="https://www.linkedin.com/in/vaishali-singh-2273361bb" target="_blank"&gt;&lt;STRONG&gt;https://www.linkedin.com/in/vaishali-singh-2273361bb&lt;/STRONG&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 31 Aug 2026 05:35:46 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592859#M1262892</guid>
      <dc:creator>vaishali231</dc:creator>
      <dc:date>2026-08-31T05:35:46Z</dc:date>
    </item>
    <item>
      <title>Re: is there any way to get all visible fields and visible variables on the form using a business ru</title>
      <link>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592864#M1262893</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;What's the use of a PDF containing all the visible fields on the form ? &lt;BR /&gt;All the data is already there, visible on the form, then why the PDF ?&lt;/P&gt;</description>
      <pubDate>Mon, 31 Aug 2026 05:52:34 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592864#M1262893</guid>
      <dc:creator>OlaN</dc:creator>
      <dc:date>2026-08-31T05:52:34Z</dc:date>
    </item>
    <item>
      <title>Re: is there any way to get all visible fields and visible variables on the form using a business ru</title>
      <link>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592884#M1262895</link>
      <description>&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;P class=""&gt;Yes, it’s possible, but a Business Rule can’t directly know the client-side visibility of fields. You can use GlideRecord and dictionary metadata for fields, and access the record producer variables separately.&lt;/P&gt;&lt;P&gt;I’d recommend having the Business Rule call a Script Include that collects the required label/value pairs, generates the PDF, and attaches it with GlideSysAttachment.&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 31 Aug 2026 06:31:36 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592884#M1262895</guid>
      <dc:creator>masonreed11</dc:creator>
      <dc:date>2026-08-31T06:31:36Z</dc:date>
    </item>
    <item>
      <title>Re: is there any way to get all visible fields and visible variables on the form using a business ru</title>
      <link>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592886#M1262896</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Yes, but not directly from a Business Rule. A Business Rule can read the record fields and variable values, but the form/UI controls visibility&lt;/SPAN&gt;&lt;SPAN&gt;. You’ll need to reproduce the visibility logic server-side or use a suitable PDF/reporting approach to generate the attachment.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 31 Aug 2026 06:33:17 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592886#M1262896</guid>
      <dc:creator>masonreed11</dc:creator>
      <dc:date>2026-08-31T06:33:17Z</dc:date>
    </item>
    <item>
      <title>Re: is there any way to get all visible fields and visible variables on the form using a business ru</title>
      <link>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592899#M1262897</link>
      <description>&lt;P&gt;&lt;a href="https://www.servicenow.com/community/user/viewprofilepage/user-id/406401"&gt;@Alon Grod&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;what's the business requirement here?&lt;/P&gt;
&lt;P&gt;In server side you won't know which variables are visible or not.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-unicode-emoji" title=":light_bulb:"&gt;💡&lt;/span&gt; If my response helped, please mark it as correct &lt;span class="lia-unicode-emoji" title=":white_heavy_check_mark:"&gt;✅&lt;/span&gt; and close the thread &lt;span class="lia-unicode-emoji" title=":locked:"&gt;🔒&lt;/span&gt;— this helps future readers find the solution faster! &lt;span class="lia-unicode-emoji" title=":folded_hands:"&gt;🙏&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 31 Aug 2026 07:06:16 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/is-there-any-way-to-get-all-visible-fields-and-visible-variables/m-p/3592899#M1262897</guid>
      <dc:creator>Ankur Bawiskar</dc:creator>
      <dc:date>2026-08-31T07:06:16Z</dc:date>
    </item>
  </channel>
</rss>

