Modify

Opened 16 years ago

Closed 16 years ago

#1215 closed Bug (Fixed)

_arrayDisplay() displays incorrectly when pipe character is is present in flelds.

Reported by: anonymous Owned by: J-Paul Mesnage
Milestone: 3.3.1.3 Component: Standard UDFs
Version: 3.3.1.1 Severity: None
Keywords: _arrayDisplay Cc:

Description

Environment = 3.3.1.1 under WIN_XP/Service Pack 3 X86

In AutoIt beta 3.3.1.1 _arrayDisplay() displays data incorrectly under specific conditions.
When the default separator character is "|" and is present in the array data, the _arrayDisplay() displays rows twice and columns that contain the separator character are truncated at the separator character.
AutoIt 3.3.0.0 truncates data in columns but does not display rows twice.
Reproduction Script

#include <array.au3>
;displays rows twice and only data up to pipe character in second column
Global $a[5][2] = [[1,"a|A"],[2,"b|B"],[3,"c|C"],[4,"d|D"],[5,"e|E"]]
_ArrayDisplay($a)

;displays correctly
Global $a[5][2] = [[1,"a,A"],[2,"b,B"],[3,"c,C"],[4,"d,D"],[5,"e,E"]]
_ArrayDisplay($a)

A possible fix is to add the following lines

  If $sSeparator = $sReplace Then
    If $sSeparator = Chr(124) Then
      $sReplace = Chr(126)
    Else
      $sReplace = Chr(124)
    EndIf
  EndIf

immediately after this line in _arrayDisplay().

  If $sSeparator = "" Then $sSeparator = Chr(124)

Attachments (0)

Change History (3)

comment:1 by Bowmore, 16 years ago

Forgot to add my name to the above report.

comment:2 by J-Paul Mesnage, 16 years ago

Owner: changed from Gary to J-Paul Mesnage
Status: newassigned

comment:3 by J-Paul Mesnage, 16 years ago

Milestone: 3.3.1.3
Resolution: Fixed
Status: assignedclosed

Fixed in version: 3.3.1.3

Modify Ticket

Action
as closed The owner will remain J-Paul Mesnage.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.