Modify

Opened 17 years ago

Closed 17 years ago

#1069 closed Bug (No Bug)

Check _PathSplit Function.

Reported by: ZNote Owned by:
Milestone: Component: AutoIt
Version: 3.3.0.0 Severity: None
Keywords: Cc:

Description

; Written By ZNote ( ZNOTE9 aT yAhoO dOt CoM )

; Check _PathSplit Function.

; Array Returns Incorrect Values For Folder Names Having Dot(s) Present.

; Example:-

#include <file.au3>
#include <array.au3>


Dim $szDrive, $szDir, $szFName, $szExt

$ZNote = @DesktopDir & "\New Folder.l.l.l.l.l..l.l.l.l.l"

; DirCreate($ZNote) ; ( optional )

$TestPath = _PathSplit($ZNote, $szDrive, $szDir, $szFName, $szExt)


_ArrayDisplay($TestPath,"Demo _PathSplit()")

;====================================================

; Output Currently Present:-

;====================================================

; @DesktopDir = "C:\Documents and Settings\<user>\Desktop" (say)

; $TestPath[0] = "C:\Documents and Settings\<user>\Desktop\New Folder.l.l.l.l.l..l.l.l.l.l"

; $TestPath[1] = "C:"

; $TestPath[2] = "\Documents and Settings\<user>\Desktop\"

; $TestPath[3] = "New Folder.l.l.l.l.l..l.l.l.l"

; $TestPath[4] = ".l"

;====================================================

; Output Should Be:-

;====================================================

; @DesktopDir = "C:\Documents and Settings\<user>\Desktop" (say)

; $TestPath[0] = "C:\Documents and Settings\<user>\Desktop\New Folder.l.l.l.l.l..l.l.l.l.l"

; $TestPath[1] = "C:"

; $TestPath[2] = "\Documents and Settings\<user>\Desktop\"

; $TestPath[3] = "New Folder.l.l.l.l.l..l.l.l.l.l"

; $TestPath[4] = ""

;==========================END=======================

; Use FileGetAttrib() function to determine whether
; entered path represents a folder or file.

; You can also add this example in help file for folder;
; For file - @ScriptFullPath is already present.

Attachments (0)

Change History (1)

comment:1 by Valik, 17 years ago

Resolution: No Bug
Status: newclosed

This is not a bug and will not be changed.

Modify Ticket

Action
as closed The ticket will remain with no owner.

Add Comment


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