;; 
;;=====================================================================================----- 
;; 
;;FUNCTION       ReadUnicodeFile() 
;; 
;;ACTION         Reads a Unicode formated text file and returns an array 
;; 
;;AUTHOR         Allen Powell 
;; 
;;CONTRIBUTORS    
;; 
;;VERSION        1.0.0 - 2013/05/15 
;; 
;;HISTORY        1.0.0 - 2013/05/15 - Original Release 
;; 
;;SYNTAX         ReadUnicodeFile(File) 
;; 
;;PARAMETERS     File - REQUIRED - Fully-Qualified path and filename 
;; 
;;REMARKS         
;; 
;;RETURNS        Array of the Lines in the Text File, or nothing if the file does not exist 
;; 
;;DEPENDENCIES   none 
;; 
;;TESTED WITH    W2K8, W2K12, W2K16 
;; 
;;EXAMPLES        
;;              $aLines = ReadUnicodeFile(@scriptdir + '\unicodetest.txt')  
;;              For Each $Line in $aLines  
;;                $Line ? 
;;              Next  
; 
Function ReadUnicodeFile($_Fqfn)
 
  If Exist($_Fqfn)
    $ReadUnicodeFile=Split(CreateObject("Scripting.FileSystemObject").OpenTextFile($_Fqfn, 1,not 1,-1).ReadAll, @CRLF)
    Exit 0
  Else
    Exit 2
  EndIf
  
EndFunction