title: How to show selected start row and end row using javascript?
body: <p>I want to show selected start row and end row in print preview page using javascript.If I checked data in console.log is correct but it can`t show row datas in print preview .How can I do that ? </p>
  
  <p><strong>Here is part of my code</strong></p>
  
  <pre><code> var work = $("#rom-table-id").find("tr");
                          var i = 0;
                          for (var i = selected_start_row; i &lt;= selected_end_row; i++) {
  
                              $(work[i]).addClass('print-selected-row');
                              console.log(work[i]);
                          } 
  
  window.open('', 'new_window', 'fullscreen=1,resizable=1,scrollbars=1');
  
                          // SochiKubun:TD orATC or ALL、SelectedStartKoban:選択開始行の項番、SelectedEndKoban：選択終了行の項番
                          var form = document.createElement('form');
                          var printRomVerAction = location.pathname.substring(0, location.pathname.toUpperCase().lastIndexOf("WSM24G01") + 8) + '/PrintRomVer';
                          form.setAttribute('action', printRomVerAction);
                          form.setAttribute('method', 'post');
                          form.setAttribute('target', 'new_window');
                          form.setAttribute('id', 'SochiButton');
                          form.style.display = 'none';
                          document.body.appendChild(form);
                          var input = document.createElement('input');
                          input.setAttribute('type', 'hidden');
                          input.setAttribute('name', 'SochiKubun');
                          var sochi = $('.sochi-kind').text();
                          input.setAttribute('value', sochi);
                          form.appendChild(input);
  
  
                          input = document.createElement('input');
                          input.setAttribute('type', 'hidden');
                          input.setAttribute('name', 'SelectedStartKoban');
                          var kanbo = $(work[selected_start_row]).children(' td:first').text();                           
                          console.log("start is ", kanbo)
                          input.setAttribute('value', kanbo);
                          form.appendChild(input);
  
                          input = document.createElement('input');
                          input.setAttribute('type', 'hidden');
                          input.setAttribute('name', 'SelectedEndKoban');
                          var kanbo2 = $(work[selected_end_row]).children('td:first').text();
                          console.log("end is ", kanbo2)
                          input.setAttribute('value', kanbo2);
                          form.appendChild(input);
  </code></pre>