Adding more fields

Homepage Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Adding more fields

  • Creator
    Topic
  • #54129
    Jawad Chaudhry
    Participant

    How can I add more fields at the end of a segment? I am trying to append pipes up to field 46 if fields 37-46 are blank for IN1. Any ideas? I am using tcl.

Viewing 1 reply thread
  • Author
    Replies
    • #80271
      Levy Lazarre
      Participant

      Hello Jawad,

      I assume that you have broken the segment into a list of fields, based on the field separator. For example, with PV2

      set PV2flds [split $seg $fldSep]

      All you have to do is append empty fields to the list, up to the desired number. The code is like:

      Code:



      while {[llength $PV2flds] < 46} { lappend PV2flds {} }

      The segment will now have the number of fields you want.

      I hope this helps.

    • #80272
      Russ Ross
      Participant

      Take a look at our tps_pad_segment proc examples and other approaches at this URL:

      <a href="http://clovertech.infor.com/viewtopic.php?t=1330&#8243; class=”bbcode_url”>http://clovertech.infor.com/viewtopic.php?t=1330

      Bob Richardson also posted a proc called tps_add_blank_fields at the URL above.

      Russ Ross
      RussRoss318@gmail.com

Viewing 1 reply thread
  • The forum ‘Cloverleaf’ is closed to new topics and replies.

Forum Statistics

Registered Users
5,129
Forums
28
Topics
9,301
Replies
34,447
Topic Tags
288
Empty Topic Tags
10