1. What is neoFile?
neoFile is a native, modern file and directory management system for VisualNEO Win.
It replaces obsolete 16/32-bit legacy file tools with a modern, Unicode-first engine that natively supports:
- Full Text Encoding Control: Read and write files in UTF-8 (with or without BOM), ANSI, UTF-16LE, and UTF-16BE with automatic encoding detection.
- Line-Based File Editing: Insert, replace, delete, or read specific lines while preserving the selected encoding. These editing actions load the text file in memory.
- Modern JSON Directory Listings: Scan folders and search for files with complete metadata (exact bytes, human-formatted size
"2.4 MB", modified dates, attributes). - Grep File Search: Search for text strings inside hundreds of files simultaneously, returning matching line numbers and snippets in JSON.
- Low-Level Binary Operations: Read and patch raw bytes in Hexadecimal or Base64, search for binary byte signatures, truncate files, and identify real file formats via Magic Bytes (PNG, PDF, ZIP, SQLite, etc.).
- Large File Split & Join: Split massive files into manageable parts (
.part001,.part002) and reassemble them anywhere.
2. Quick Start: Everyday File Operations in 3 Steps
Step 1: Read and Write UTF-8 Text Files
TEXT
. Write a UTF-8 text file (creates file if missing)
neoFileWriteText "[PubDir]config.txt" "Setting1=Enabled[#13]Setting2=High" "UTF-8"
. Append a new line
neoFileAppendText "[PubDir]config.txt" "Setting3=100" "UTF-8"
. Read the entire file back into a variable
neoFileReadText "[PubDir]config.txt" "Auto" "[FullConfigText]"
AlertBox "Config" "[FullConfigText]"
Step 2: Edit Specific Lines in a File
TEXT
. Get total number of lines
neoFileGetLineCount "[PubDir]config.txt" "[TotalLines]" "UTF-8"
. Replace line 2 with new text
neoFileReplaceLine "[PubDir]config.txt" "2" "Setting2=Ultra" "UTF-8"
. Delete line 3
neoFileDeleteLine "[PubDir]config.txt" "3" "UTF-8"
Step 3: Scan a Folder and Get JSON
TEXT
. List all .png images sorted by size
neoFileList "C:\Photos" "*.png" "True" "size_desc" "[ImagesJson]"
3. Real-World Practical Examples
Example 1: Grep Text Search Across Project Files
Search for a specific customer ID across all log files in a directory:
TEXT
neoFileFindInFiles "C:\AppLogs" "CustomerID=94821" "*.log" "False" "True" "[SearchMatchesJson]"
. [SearchMatchesJson] returns an array of matches:
. [{"file":"C:\\AppLogs\\2026-08-10.log","lineNumber":42,"lineContent":"[INFO] CustomerID=94821 logged in."}]
Example 2: Inspecting Real File Formats (Magic Bytes / MIME)
Never trust file extensions alone (e.g. a user renaming virus.exe to photo.jpg). Identify real file signatures:
TEXT
neoFileGetMagic "C:\Downloads\document.file" "[MimeType]" "[HexSig]" "[Description]"
. [MimeType] -> "application/pdf"
. [HexSig] -> "25504446" (%PDF)
. [Description] -> "PDF Document"
Example 3: Low-Level Binary Inspection (Read First 16 Bytes as Hex)
TEXT
neoFileReadBytesHex "C:\Windows\notepad.exe" "0" "16" "[HexHeader]"
. [HexHeader] will contain: "4D5A90000300000004000000FFFF0000" (MZ header)
Example 4: Splitting and Reassembling Large Files
Split a 500 MB video file into 50 MB chunks for easy transfer, then join them back:
TEXT
. Split into 50 MB parts
neoFileSplit "C:\Videos\presentation.mp4" "C:\Videos\Parts" "50" "[ChunkCount]"
AlertBox "Split Done" "Created [ChunkCount] parts."
. Reassemble back on destination computer
neoFileJoin "C:\Videos\Parts\presentation.mp4.part001" "C:\Restored\presentation.mp4" "[Success]"
4. Complete Action Reference
Text & Line Operations
| Action | Parameters | Description |
|---|---|---|
neoFileReadText | "[File]" "[Encoding]" "[VarContent]" | Reads file with autodetection or specified encoding (Auto, UTF-8, ANSI, UTF-16LE). |
neoFileWriteText | "[File]" "[Text]" "[Encoding]" | Writes/overwrites file (UTF-8, UTF-8-BOM, ANSI, UTF-16LE). |
neoFileAppendText | "[File]" "[Text]" "[Encoding]" | Appends text to end of file. |
neoFileReadLines | "[File]" "[StartLine]" "[Count]" "[VarResult]" "[Enc]" | Reads a specific range of lines. |
neoFileGetLineCount | "[File]" "[VarCount]" "[Encoding]" | Counts total lines in file. |
neoFileReplaceLine | "[File]" "[LineNum]" "[NewText]" "[Encoding]" | Replaces a single line (1-based index). |
neoFileDeleteLine | "[File]" "[LineNum]" "[Encoding]" | Deletes a single line by index. |
neoFileInsertLine | "[File]" "[LineNum]" "[Text]" "[Encoding]" | Inserts a new line at position. |
File & Folder Operations
| Action | Parameters | Description |
|---|---|---|
neoFileCopy | "[Source]" "[Dest]" "[Overwrite]" | Copies a file with overwrite control. |
neoFileMove | "[Source]" "[Dest]" "[Overwrite]" | Moves or renames a file or folder. |
neoFileDelete | "[File]" | Deletes a file permanently. |
neoFileExists | "[File]" "[VarExists]" | Checks if a file exists (True/False). |
neoFileFolderExists | "[Folder]" "[VarExists]" | Checks if a folder exists (True/False). |
neoFileFolderCreate | "[Folder]" | Creates folder and all intermediate directories. |
neoFileFolderDelete | "[Folder]" "[Recursive]" | Deletes folder (with or without contents). |
neoFileFolderEmpty | "[Folder]" | Clears folder contents keeping directory intact. |
Directory Listing & Search (JSON)
| Action | Parameters | Description |
|---|---|---|
neoFileList | "[Folder]" "[Mask]" "[Recursive]" "[Sort]" "[VarJSON]" | Lists files with sizes, dates, and attributes in JSON. |
neoFileFolderList | "[Folder]" "[Recursive]" "[VarJSON]" | Lists subdirectories in JSON array. |
neoFileFindInFiles | "[Folder]" "[Text]" "[Mask]" "[Case]" "[Rec]" "[VarJSON]" | Grep text search returning matching lines in JSON. |
Metadata & Binary Tools
| Action | Parameters | Description |
|---|---|---|
neoFileGetInfo | "[File]" "[VarJSON]" | Gets file attributes, timestamps, and size in JSON. |
neoFileSetAttributes | "[File]" "[ReadOnly]" "[Hidden]" "[Sys]" "[Arch]" | Modifies file attributes (1=Set, 0=Clear, -1=Keep). |
neoFileSetTimestamps | "[File]" "[Created]" "[Modified]" "[Accessed]" | Updates file timestamps (YYYY-MM-DD HH:MM:SS). |
neoFileCompare | "[File1]" "[File2]" "[VarIdentical]" | Compares two files byte-by-byte (True/False). |
neoFilePathParse | "[Path]" "[VarDir]" "[VarName]" "[VarExt]" "[VarBase]" | Parses path into components. |
neoFilePathCombine | "[BasePath]" "[Relative]" "[VarCombined]" | Combines and normalizes paths. |
neoFileTempCreate | "[Prefix]" "[Ext]" "[VarTempPath]" | Generates unique temp file in Windows Temp. |
neoFileReadBytesHex | "[File]" "[Offset]" "[Count]" "[VarHex]" | Reads binary bytes into Hex string. |
neoFileWriteBytesHex | "[File]" "[Offset]" "[HexData]" "[Create]" | Patches or writes binary bytes from Hex string. |
neoFileReadBytesBase64 | "[File]" "[Offset]" "[Count]" "[VarBase64]" | Reads binary bytes into Base64 string. |
neoFileWriteBytesBase64 | "[File]" "[Offset]" "[Base64]" "[Create]" | Writes binary bytes from Base64 string. |
neoFileFindHex | "[File]" "[HexPattern]" "[StartOffset]" "[VarOffset]" | Searches for binary byte sequence. |
neoFileTruncate | "[File]" "[NewSizeBytes]" | Truncates or resizes file to exact byte length. |
neoFileGetMagic | "[File]" "[VarMime]" "[VarSig]" "[VarDesc]" | Identifies real file format via Magic Header Bytes. |
neoFileSplit | "[File]" "[OutDir]" "[PartSizeMB]" "[VarCount]" | Splits large file into chunk parts. |
neoFileJoin | "[FirstPart001]" "[ReassembledFile]" "[VarSuccess]" | Reassembles chunk parts into original file. |
5. Interactive Demo
Open demo/neoFile-demo.pub in VisualNEO Win to test text encodings, directory scanning, grep search, binary hex reading, magic byte detection, and file splitting interactively.
6. Validation and Limits
- Text reads and writes preserve the exact text;
neoFileWriteTextno longer appends an implicit final newline. - Binary offsets and file sizes cannot be negative. Hexadecimal input must contain complete, valid byte pairs.
- Hex/Base64 read actions return at most 16 MB per call to protect the Win32 host and its variables.
neoFileFindHexsupports patterns that cross internal read-buffer boundaries.neoFileJoinrequires a contiguous sequence beginning with.part001and writes the result atomically.