XSal
Namespace: PPJ.Runtime.XSal
Assembly: PPJ.Web.XSal.50 (5.0.0.0)
Provides XSal compatibility operations for tables, splitters, toolboxes, strings, scripts, and archive data.
- C#
- VB.NET
public class XSal
Public Class XSal
Example:
SalString token = XSal.StrGetFirstToken("red,green,blue", ",");
while (!token.IsNull)
{
System.Console.WriteLine(token);
token = XSal.StrGetNextToken();
}
Fields
| Name | Type | Description | Value |
|---|---|---|---|
| SAM_HotSpotClick | Int32 | Compatibility message identifier for a hotspot click. | |
| SAM_HotSpotMouseMove | Int32 | Compatibility message identifier for mouse movement over a hotspot. | |
| SAM_SwapRows | Int32 | Message identifier used when table rows are exchanged. | |
| SAM_ToolboxSetPosition | Int32 | Compatibility message identifier for a toolbox-position change. | |
| SAM_ToolboxUpdateMenu | Int32 | Compatibility message identifier for updating a toolbox menu. | |
| SAM_TooltipClose | Int32 | Compatibility message identifier for closing a tooltip. | |
| SAM_TooltipSetText | Int32 | Compatibility message identifier for supplying tooltip text. |
Methods
GetClientWindow(form)
Gets the SAL client-area control associated with a form.
| Parameter | Type | Description |
|---|---|---|
| form | Control | The form or control to inspect. |
Returns: SalWindowHandle. The client-area handle returned by SalWindow.GetClientArea.
GetWindowHotSpot(ctrl, id, x, y, width, height)
Provides an unimplemented hotspot query compatibility entry point.
| Parameter | Type | Description |
|---|---|---|
| ctrl | Control | Reserved; ignored. |
| id | SalNumber | Reserved; ignored. |
| x | SalNumber | Not modified. |
| y | SalNumber | Not modified. |
| width | SalNumber | Not modified. |
| height | SalNumber | Not modified. |
Returns: SalBoolean. Always false.
GZipClose(Param1)
Provides an unsupported compatibility entry point for closing a gzip stream.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; not modified. |
Returns: SalBoolean. Always false.
Logs that the operation is unavailable and performs no operation.
GZipEof(Param1)
Provides an unsupported compatibility entry point for testing gzip end-of-file.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; ignored. |
Returns: SalBoolean. Always false.
Logs that the operation is unavailable and performs no operation.
GZipFlush(Param1)
Provides an unsupported compatibility entry point for flushing a gzip stream.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; ignored. |
Returns: SalBoolean. Always false.
Logs that the operation is unavailable and performs no operation.
GZipGetChar(Param1)
Provides an unsupported compatibility entry point for reading a gzip character.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; ignored. |
Returns: SalNumber. Always zero.
Logs that the operation is unavailable and performs no operation.
GZipGetError(Param1, Param2)
Provides an unsupported compatibility entry point for querying a gzip error.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; ignored. |
| Param2 | SalNumber | Reserved for compatibility; not modified. |
Returns: SalString. Always SalString.Null.
Logs that the operation is unavailable and performs no operation.
GZipGetStr(Param1, Param2, Param3)
Provides an unsupported compatibility entry point for reading a gzip string.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; ignored. |
| Param2 | SalString | Reserved for compatibility; not modified. |
| Param3 | SalNumber | Reserved for compatibility; ignored. |
Returns: SalNumber. Always zero.
Logs that the operation is unavailable and performs no operation.
GZipOpen(Param1, Param2, Param3)
Provides an unsupported compatibility entry point for opening a gzip stream.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; not modified. |
| Param2 | SalString | Reserved for compatibility; ignored. |
| Param3 | SalString | Reserved for compatibility; ignored. |
Returns: SalBoolean. Always false.
Logs that the operation is unavailable and performs no operation.
GZipPutChar(Param1, Param2)
Provides an unsupported compatibility entry point for writing a gzip character.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalFileHandle | Reserved for compatibility; ignored. |
| Param2 | SalNumber | Reserved for compatibility; ignored. |
Returns: SalBoolean. Always false.
Logs that the operation is unavailable and performs no operation.
GZipPutStr(Param1, Param2)
Provides an unsupported compatibility entry point for writing a gzip string.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; ignored. |
| Param2 | SalString | Reserved for compatibility; ignored. |
Returns: SalNumber. Always zero.
Logs that the operation is unavailable and performs no operation.
GZipRead(Param1, Param2, Param3)
Provides an unsupported compatibility entry point for reading gzip data.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; ignored. |
| Param2 | SalString | Reserved for compatibility; not modified. |
| Param3 | SalNumber | Reserved for compatibility; ignored. |
Returns: SalNumber. Always zero.
Logs that the operation is unavailable and performs no operation.
GZipRewind(Param1)
Provides an unsupported compatibility entry point for rewinding a gzip stream.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; ignored. |
Returns: SalBoolean. Always false.
Logs that the operation is unavailable and performs no operation.
GZipSeek(Param1, Param2, Param3)
Provides an unsupported compatibility entry point for seeking within a gzip stream.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; ignored. |
| Param2 | SalNumber | Reserved for compatibility; ignored. |
| Param3 | SalNumber | Reserved for compatibility; ignored. |
Returns: SalNumber. Always zero.
Logs that the operation is unavailable and performs no operation.
GZipTell(Param1)
Provides an unsupported compatibility entry point for querying a gzip position.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; ignored. |
Returns: SalNumber. Always zero.
Logs that the operation is unavailable and performs no operation.
GZipWrite(Param1, Param2, Param3)
Provides an unsupported compatibility entry point for writing gzip data.
| Parameter | Type | Description |
|---|---|---|
| Param1 | SalNumber | Reserved for compatibility; ignored. |
| Param2 | SalString | Reserved for compatibility; ignored. |
| Param3 | SalNumber | Reserved for compatibility; ignored. |
Returns: SalNumber. Always zero.
Logs that the operation is unavailable and performs no operation.
ScriptAddLine(handle, line)
Appends a script line and recompiles the program.
| Parameter | Type | Description |
|---|---|---|
| handle | SalNumber | A live script handle, or zero. |
| line | SalString | The line to append. |
Returns: SalBoolean. The compilation result, or false for a null handle.
ScriptCreate(source)
Creates and compiles a script and allocates its handle.
| Parameter | Type | Description |
|---|---|---|
| source | SalString | The script source; a complete brace-delimited block enables C# syntax. |
Returns: SalNumber. The allocated script handle. Compilation errors are recorded and can be queried separately.
ScriptFree(handle)
Releases the script’s context and allocated handle.
| Parameter | Type | Description |
|---|---|---|
| handle | SalNumber | A live script handle, or zero. |
Returns: SalBoolean. True if a script was released; false for a null handle.
ScriptGetErrors(handle, errorsList)
Retrieves a script’s recorded error text.
| Parameter | Type | Description |
|---|---|---|
| handle | SalNumber | A live script handle, or zero. |
| errorsList | SalString | Receives error text when an error exists; otherwise unchanged. |
Returns: SalNumber. The error-text length, or zero when no script or error exists.
ScriptGetLocalName(handle, localName, varName)
Deprecated: Not supported.
Provides an unsupported compatibility entry point for resolving a script-local variable name.
| Parameter | Type | Description |
|---|---|---|
| handle | SalNumber | Reserved for compatibility; ignored. |
| localName | SalString | Reserved for compatibility; ignored. |
| varName | SalString | Reserved for compatibility; not modified. |
Returns: SalBoolean. Always false.
Logs that the operation is unavailable and performs no operation.
ScriptRun(handle, result)
Executes a compiled script and retrieves its textual result.
| Parameter | Type | Description |
|---|---|---|
| handle | SalNumber | A live script handle, or zero. |
| result | SalString | Receives the result text when a script exists. |
Returns: SalBoolean. True if the script has no recorded errors after execution; false for a null handle or recorded error.
ScriptSetContext(handle, context)
Assigns the object used for script member lookup during execution.
| Parameter | Type | Description |
|---|---|---|
| handle | SalNumber | A live script handle, or zero. |
| context | Object | The execution context object. |
Returns: SalBoolean. True if the context was assigned; false for a null handle.
ScriptSetDebugMode(handle, debugOn)
Controls whether parser and interpreter exceptions propagate from a script.
| Parameter | Type | Description |
|---|---|---|
| handle | SalNumber | A live script handle, or zero. |
| debugOn | SalBoolean | True to rethrow errors instead of recording them. |
Returns: SalBoolean. True if the setting was applied; false for a null handle.
ScriptSetTimeout(handle, timeout)
Deprecated: Not supported.
Provides an unsupported compatibility entry point for setting a script execution timeout.
| Parameter | Type | Description |
|---|---|---|
| handle | SalNumber | Reserved for compatibility; ignored. |
| timeout | SalNumber | Reserved for compatibility; ignored. |
Returns: SalBoolean. Always false.
Logs that the operation is unavailable and performs no operation.
SetWindowHotSpot(ctrl, id, x, y, width, height)
Provides an unimplemented hotspot configuration compatibility entry point.
| Parameter | Type | Description |
|---|---|---|
| ctrl | Control | Reserved; ignored. |
| id | SalNumber | Reserved; ignored. |
| x | SalNumber | Reserved; ignored. |
| y | SalNumber | Reserved; ignored. |
| width | SalNumber | Reserved; ignored. |
| height | SalNumber | Reserved; ignored. |
Returns: SalBoolean. Always false.
SetWindowImageFile(ctrl, fileName, flags)
Loads a background image and applies its layout to a control or its client-area control.
| Parameter | Type | Description |
|---|---|---|
| ctrl | Control | The target control. |
| fileName | SalString | The image-file path. |
| flags | BackgroundImageFlags | The image layout. Transparent is ignored. |
Returns: SalBoolean. True if the image and layout are assigned; false for a caught loading or assignment error.
SplitGetBarPosition(split)
Gets an XSal splitter’s current or deferred position.
| Parameter | Type | Description |
|---|---|---|
| split | SalWindowHandle | The splitter handle. |
Returns: SalNumber. The position in pixels or thousandths according to its style, or zero for an invalid splitter.
SplitGetFrameChild(split, frame)
Gets a control hosted in an XSal splitter panel.
| Parameter | Type | Description |
|---|---|---|
| split | SalWindowHandle | The XSal splitter handle. |
| frame | SalNumber | Zero for the first panel, one for the second. |
Returns: SalWindowHandle. The child handle, or a null handle for an invalid splitter, frame, or empty panel.
SplitGetStyle(split)
Gets the splitter’s orientation, absolute-position, and resizing flags.
| Parameter | Type | Description |
|---|---|---|
| split | SalWindowHandle | The splitter handle. |
Returns: SplitterStyles. The supported style mask, excluding Invisible, or zero for an invalid splitter.
SplitSetBarPosition(split, pos)
Sets an XSal splitter’s position.
| Parameter | Type | Description |
|---|---|---|
| split | SalWindowHandle | The splitter handle. |
| pos | SalNumber | The position in pixels for absolute mode or thousandths for proportional mode. |
Returns: SalBoolean. True if assigned or deferred; false for an invalid splitter.
SplitSetBarSize(split, size)
Sets an XSal splitter bar’s width.
| Parameter | Type | Description |
|---|---|---|
| split | SalWindowHandle | The splitter handle. |
| size | SalNumber | The width in pixels. |
Returns: SalBoolean. True on assignment; false if the handle is not an XSal splitter.
SplitSetFrameChild(split, child, frame)
Assigns a control to one of an XSal splitter’s panels.
| Parameter | Type | Description |
|---|---|---|
| split | SalWindowHandle | The XSal splitter handle. |
| child | SalWindowHandle | The child-control handle, or a null handle to clear the panel. |
| frame | SalNumber | Zero for the first panel, one for the second. |
Returns: SalBoolean. True if assigned; false for an invalid splitter or frame number.
SplitSetMinMax(split, min, max)
Sets minimum sizes for the first and second splitter panels.
| Parameter | Type | Description |
|---|---|---|
| split | SalWindowHandle | The splitter handle. |
| min | SalNumber | The first panel’s minimum size in pixels. |
| max | SalNumber | The second panel’s minimum size in pixels. |
Returns: SalBoolean. True on assignment; false for an invalid splitter.
SplitSetStyle(split, Style, on)
Applies supported XSal splitter style flags.
| Parameter | Type | Description |
|---|---|---|
| split | SalWindowHandle | The splitter handle. |
| Style | SplitterStyles | The flags to change. |
| on | SalBoolean | True to enable the selected flags; false to disable them. |
Returns: SalBoolean. True on assignment; false for an invalid splitter.
StrAny(text, chars)
Finds the first character belonging to a specified character set.
| Parameter | Type | Description |
|---|---|---|
| text | SalString | The text to scan. |
| chars | SalString | The characters to match. |
Returns: SalNumber. The zero-based index, or -1 if no character matches.
StrCompare(source, compare, start, size, caseSensitive)
Compares a source segment with the beginning of another string using the current culture.
| Parameter | Type | Description |
|---|---|---|
| source | SalString | The source text. |
| compare | SalString | The comparison text. |
| start | SalNumber | The starting source index. |
| size | SalNumber | The maximum number of characters to compare. |
| caseSensitive | SalBoolean | True to distinguish case; false to ignore case. |
Returns: SalBoolean. True if the compared segments are equal; false on mismatch or an out-of-range argument.
StrCompress(sIn, nLevel, sOut)
Compresses the input bytes into an XSal-prefixed binary string.
| Parameter | Type | Description |
|---|---|---|
| sIn | SalString | The binary string to compress. |
| nLevel | SalNumber | The requested compression level; the current clamping expression always selects level 9. |
| sOut | SalString | Receives the compressed binary string, or SalString.Null when no bytes are produced. |
Returns: SalBoolean. True if compression completes; false for null input or a caught compression error.
StrCount(sText, sSearch, nStart, nLength, bLeft)
Counts nonoverlapping, case-insensitive substring matches within a selected text segment.
| Parameter | Type | Description |
|---|---|---|
| sText | SalString | The text to search. |
| sSearch | SalString | The nonempty substring to count. |
| nStart | SalNumber | The segment’s starting index for a forward search or ending index for a leftward search. |
| nLength | SalNumber | The segment length. |
| bLeft | SalBoolean | True to select a segment ending at nStart; false to select one starting there. |
Returns: SalNumber. The number of matches, or zero for empty input or an unusable segment.
StrFormat(text, mask)
Builds text using underscore placeholders and percent remainder markers.
| Parameter | Type | Description |
|---|---|---|
| text | SalString | The source characters. |
| mask | SalString | An underscore consumes one source character; percent appends all remaining source text; other characters are copied literally. |
Returns: SalString. The constructed text followed by the unused mask suffix.
The percent marker itself remains in the appended mask suffix in this implementation.
StrFormatDateTime(date, format, language)
Provides an unsupported compatibility entry point for formatting a date with a language.
| Parameter | Type | Description |
|---|---|---|
| date | SalDateTime | Reserved for compatibility; ignored. |
| format | SalString | Reserved for compatibility; ignored. |
| language | SalString | Reserved for compatibility; ignored. |
Returns: SalString. Always SalString.Null.
Logs that the operation is unavailable and performs no operation.
StrFormatDateTimeX(date, format, days, shortDays, months, shortMonths)
Provides an unsupported compatibility entry point for formatting a date with custom names.
| Parameter | Type | Description |
|---|---|---|
| date | SalDateTime | Reserved for compatibility; ignored. |
| format | SalString | Reserved for compatibility; ignored. |
| days | SalString | Reserved for compatibility; ignored. |
| shortDays | SalString | Reserved for compatibility; ignored. |
| months | SalString | Reserved for compatibility; ignored. |
| shortMonths | SalString | Reserved for compatibility; ignored. |
Returns: SalString. Always SalString.Null.
Logs that the operation is unavailable and performs no operation.
StrFromHex(hex)
Decodes pairs of uppercase hexadecimal digits into a SAL binary string.
| Parameter | Type | Description |
|---|---|---|
| hex | SalString | The hexadecimal text, optionally prefixed with lowercase 0x. |
Returns: SalString. The decoded bytes, or SalString.Null for input shorter than two characters.
An unmatched final digit is ignored. Digits are not validated, and lowercase hexadecimal letters are not normalized.
StrGetCharAt(text, index)
Gets the numeric value of a character at a zero-based index.
| Parameter | Type | Description |
|---|---|---|
| text | SalString | The source text. |
| index | SalNumber | The character index. |
Returns: SalNumber. The character value, or zero for empty text or an invalid index.
StrGetFirstToken(list, separators)
Replaces the shared token sequence and returns its first nonempty token.
| Parameter | Type | Description |
|---|---|---|
| list | SalString | The text to split. |
| separators | SalString | The delimiter characters. |
Returns: SalString. The first token, or SalString.Null if none exists.
StrGetNextToken()
Advances the shared token sequence created by StrGetFirstToken.
Returns: SalString. The next token, or SalString.Null when no sequence or tokens remain.
StrMetaphone(text)
Provides an unsupported compatibility entry point for computing a Metaphone code.
| Parameter | Type | Description |
|---|---|---|
| text | SalString | Reserved for compatibility; ignored. |
Returns: SalString. Always SalString.Null.
Logs that the operation is unavailable and performs no operation.
StrNAny(text, chars)
Finds the first character outside a specified character set.
| Parameter | Type | Description |
|---|---|---|
| text | SalString | The text to scan. |
| chars | SalString | The allowed characters. |
Returns: SalNumber. The zero-based index, or -1 when every character belongs to the set.
StrScan(sText, search, nIndex)
Searches forward using ordinal case-insensitive comparison.
| Parameter | Type | Description |
|---|---|---|
| sText | SalString | The text to search. |
| search | SalString | The nonempty substring to find. |
| nIndex | SalNumber | The starting index, clamped to the text length; negative values fail. |
Returns: SalNumber. The matching zero-based index, or -1 for no match or invalid input.
StrScanR(sText, search, nIndex)
Searches backward using ordinal case-insensitive comparison.
| Parameter | Type | Description |
|---|---|---|
| sText | SalString | The text to search. |
| search | SalString | The nonempty substring to find. |
| nIndex | SalNumber | The starting index; a negative value searches from the end, and larger values are clamped to the text length. |
Returns: SalNumber. The matching zero-based index, or -1 for no match or invalid input.
StrSetCharAt(text, index, character)
Replaces a character at a zero-based index.
| Parameter | Type | Description |
|---|---|---|
| text | SalString | The text to modify. |
| index | SalNumber | The character index. |
| character | SalNumber | The numeric character value to insert. |
Returns: SalNumber. The previous character value, or zero for empty text or an invalid index.
StrToHex(text)
Encodes the string’s binary buffer as uppercase hexadecimal prefixed with 0x.
| Parameter | Type | Description |
|---|---|---|
| text | SalString | The string whose bytes are encoded. |
Returns: SalString. The hexadecimal text, or SalString.Null for empty input.
StrToNumber(text)
Parses a number after adapting the first period or comma to the current decimal separator when needed.
| Parameter | Type | Description |
|---|---|---|
| text | SalString | The numeric text. |
Returns: SalNumber. The parsed SAL number, or SalNumber.Null for empty or unparseable input.
StrUncompress(sIn, sOut)
Decompresses bytes after the three-byte XSal compression prefix.
| Parameter | Type | Description |
|---|---|---|
| sIn | SalString | The binary string beginning with XZ. |
| sOut | SalString | Receives decompressed data, or SalString.Null for an empty output. |
Returns: SalBoolean. False for invalid input or a caught decompression error; otherwise, true.
A trailing zero terminator from compatible CTD strings may be removed when the result is converted to ordinary text.
TblCopyRows(table, flagsOn, flagsOff, copyFlags)
Copies matching table rows in display-column order to the clipboard.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| flagsOn | SalNumber | The flags required on copied rows. |
| flagsOff | SalNumber | The flags that must be clear on copied rows. |
| copyFlags | TableWindowClipboardFlags | Options to skip hidden columns and include captions. |
Returns: SalBoolean. True if some text was produced; false for an invalid table or no output.
Uses the configured literal delimiters without quoting or escaping. The row context is restored. A caught copy error can leave partial output.
TblCopyRowsToString(table, flagsOn, flagsOff, copyFlags, csvText)
Copies matching table rows in display-column order to delimited text.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| flagsOn | SalNumber | The flags required on copied rows. |
| flagsOff | SalNumber | The flags that must be clear on copied rows. |
| copyFlags | TableWindowClipboardFlags | Options to skip hidden columns and include captions. |
| csvText | SalString | Receives the delimited rows on success. |
Returns: SalBoolean. True if some text was produced; false for an invalid table or no output.
Uses the configured literal delimiters without quoting or escaping. The row context is restored. A caught copy error can leave partial output.
TblGetCellBackColor(column, color)
Retrieves the current-context cell’s explicit background color as a SAL color.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| color | SalNumber | Receives the translated color, including translated Color.Empty when the query fails. |
Returns: SalBoolean. True if a nonempty explicit background color exists; otherwise, false.
TblGetCellBackColor(column)
Gets the current-context cell’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
Returns: Color. The explicit color, or Color.Empty if no explicit color or target style exists.
TblGetCellFont(column)
Gets the current-context cell’s explicit font.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
Returns: Font. The style font, or null when no font or target style exists.
TblGetCellImage(column, position)
Gets the current-context cell’s background image.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| position | TableWindowImageFlags | Receives the converted layout and alignment when an image exists; otherwise unchanged. |
Returns: Image. The image, or null when the target style or image is absent.
TblGetColHeaderFont(column)
Gets the main-grid column header’s explicit font.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
Returns: Font. The style font, or null when no font or target style exists.
TblGetColHeaderImage(column, image, position)
Retrieves the background image through the compatibility column-header image query.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| image | Image | Receives the image, or null when absent. |
| position | TableWindowImageFlags | Receives the converted layout and alignment when an image exists; otherwise unchanged. |
Returns: SalBoolean. True if an image is returned.
The underlying implementation reads the current-context cell style rather than the column-header style.
TblGetColumnBackColor(column, color)
Retrieves the main-grid column’s explicit background color as a SAL color.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| color | SalNumber | Receives the translated color, including translated Color.Empty when the query fails. |
Returns: SalBoolean. True if a nonempty explicit background color exists; otherwise, false.
TblGetColumnBackColor(column)
Gets the main-grid column’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
Returns: Color. The explicit color, or Color.Empty if no explicit color or target style exists.
TblGetColumnFont(column)
Gets the main-grid column’s explicit font.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
Returns: Font. The style font, or null when no font or target style exists.
TblGetRowBackColor(table, row, color)
Retrieves the table row’s explicit background color as a SAL color.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| color | SalNumber | Receives the translated color, including translated Color.Empty when the query fails. |
Returns: SalBoolean. True if a nonempty explicit background color exists; otherwise, false.
TblGetRowBackColor(table, row)
Gets the table row’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
Returns: Color. The explicit color, or Color.Empty if no explicit color or target style exists.
TblGetRowFont(table, nRow)
Gets the table row’s explicit font.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| nRow | SalNumber | The SAL row context. |
Returns: Font. The style font, or null when no font or target style exists.
TblGetRowHeaderBackColor(table, row, color)
Retrieves the row header’s explicit background color as a SAL color.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| color | SalNumber | Receives the translated color, including translated Color.Empty when the query fails. |
Returns: SalBoolean. True if a nonempty explicit background color exists; otherwise, false.
TblGetRowHeaderBackColor(table, row)
Gets the row header’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
Returns: Color. The explicit color, or Color.Empty if no explicit color or target style exists.
TblPasteRows(table, copyFlags)
Appends rows from clipboard text using the configured delimiters.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| copyFlags | TableWindowClipboardFlags | Options to skip the caption row and hidden columns. |
Returns: SalBoolean. False for an invalid table or unavailable clipboard text; otherwise, true, including partial processing after a caught error.
Empty delimited rows are retained. The implementation begins column lookup at position zero, although table positions are one-based, so inserted rows may remain empty. The previous row context is restored.
TblPasteRowsFromString(table, flags, csvText)
Appends rows from delimited text using the configured delimiters.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| flags | TableWindowClipboardFlags | Options to skip the caption row and hidden columns. |
| csvText | SalString | The unescaped delimited row text. |
Returns: SalBoolean. False for an invalid table; otherwise, true, including partial processing after a caught error.
Empty delimited rows are retained. The implementation begins column lookup at position zero, although table positions are one-based, so inserted rows may remain empty. The previous row context is restored.
TblSetCellBackColor(column, color)
Sets the current-context cell’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| color | SalNumber | The SAL color value to translate. |
Returns: SalBoolean. True if the target style exists and is changed; otherwise, false.
TblSetCellBackColor(column, color)
Sets the current-context cell’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| color | Color | The new color. |
Returns: SalBoolean. True if the target style exists and is changed; otherwise, false.
TblSetCellFont(column, font)
Sets the current-context cell’s explicit font.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| font | Font | The font, or null to clear the explicit style font. |
Returns: SalBoolean. True if the target style is available; otherwise, false.
TblSetCellImage(column, image, flags)
Sets the current-context cell’s background image.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| image | Image | A bitmap to assign, or null to clear the image. Other Image implementations leave the style unchanged. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style exists, even when the image is not a bitmap; otherwise, false.
TblSetCellImageFile(column, fileName, flags)
Loads a background image from a file and assigns it to the current-context cell.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| fileName | SalString | The image-file path. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false, including caught image-loading errors.
TblSetCellImageResource(column, name, flags)
Loads a background image from a named SAL resource and assigns it to the current-context cell.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| name | SalString | The SAL resource name. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false.
A missing resource supplies null and clears the cell image.
TblSetCellImageString(column, imageBlob, flags)
Loads a background image from bitmap binary data and assigns it to the current-context cell.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| imageBlob | SalString | The bitmap bytes in a SAL binary string. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false.
TblSetColHeaderFont(column, font)
Sets the main-grid column header’s explicit font.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| font | Font | The font, or null to clear the explicit style font. |
Returns: SalBoolean. True if the target style is available; otherwise, false.
TblSetColHeaderFontName(column, fontName, fontSize, fontStyle)
Creates a font and assigns it to the main-grid column header.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| fontName | SalString | The font family name. |
| fontSize | SalNumber | The font size in points. |
| fontStyle | SalNumber | The SAL font-style flags. |
Returns: SalBoolean. True if the target style is available; otherwise, false.
TblSetColHeaderImage(column, image, flags)
Sets the main-grid column header’s background image.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| image | Image | A bitmap to assign, or null to clear the image. Other Image implementations leave the style unchanged. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style exists, even when the image is not a bitmap; otherwise, false.
TblSetColHeaderImageFile(column, fileName, flags)
Loads a background image from a file and assigns it to the main-grid column header.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| fileName | SalString | The image-file path. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false, including caught image-loading errors.
TblSetColHeaderImageResource(column, resName, flags)
Loads a background image from a named SAL resource and assigns it to the main-grid column header.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| resName | SalString | The SAL resource name. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false.
A missing or non-bitmap resource returns false.
TblSetColHeaderImageString(column, imageBlob, flags)
Loads a background image from bitmap binary data and assigns it to the main-grid column header.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| imageBlob | SalString | The bitmap bytes in a SAL binary string. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false.
TblSetColumnBackColor(column, color)
Sets the main-grid column’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| color | SalNumber | The SAL color value to translate. |
Returns: SalBoolean. True if the target style exists and is changed; otherwise, false.
TblSetColumnBackColor(column, color)
Sets the main-grid column’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| color | Color | The new color. |
Returns: SalBoolean. True if the target style exists and is changed; otherwise, false.
TblSetColumnFont(column, font)
Sets the main-grid column’s explicit font.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| font | Font | The font, or null to clear the explicit style font. |
Returns: SalBoolean. True if the target style is available; otherwise, false.
TblSetColumnFontName(column, fontName, fontSize, fontStyle)
Creates a font and assigns it to the main-grid column.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| fontName | SalString | The font family name. |
| fontSize | SalNumber | The font size in points. |
| fontStyle | SalNumber | The SAL font-style flags. |
Returns: SalBoolean. True if the target style is available; otherwise, false.
TblSetColumnImage(column, image, flags)
Sets the main-grid column’s background image.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| image | Image | A bitmap to assign, or null to clear the image. Other Image implementations leave the style unchanged. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style exists, even when the image is not a bitmap; otherwise, false.
TblSetColumnImageFile(column, fileName, flags)
Loads a background image from a file and assigns it to the main-grid column.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| fileName | SalString | The image-file path. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false, including caught image-loading errors.
TblSetColumnImageResource(column, name, flags)
Loads a background image from a named SAL resource and assigns it to the main-grid column.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| name | SalString | The SAL resource name. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false.
A missing or non-bitmap resource returns false.
TblSetColumnImageString(column, sImage, flags)
Loads a background image from bitmap binary data and assigns it to the main-grid column.
| Parameter | Type | Description |
|---|---|---|
| column | Control | An attached SalTableColumn. |
| sImage | SalString | The bitmap bytes in a SAL binary string. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false.
TblSetDelimiters(colDelimiter, rowDelimiter)
Sets the shared literal delimiters used for table text and clipboard transfers.
| Parameter | Type | Description |
|---|---|---|
| colDelimiter | SalString | The string separating columns. |
| rowDelimiter | SalString | The string separating rows. |
Returns: SalBoolean. True.
TblSetRowBackColor(table, row, color)
Sets the table row’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| color | SalNumber | The SAL color value to translate. |
Returns: SalBoolean. True if the target style exists and is changed; otherwise, false.
TblSetRowBackColor(table, row, color)
Sets the table row’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| color | Color | The new color. |
Returns: SalBoolean. True if the target style exists and is changed; otherwise, false.
TblSetRowFont(table, row, font)
Sets the table row’s explicit font.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| font | Font | The font, or null to clear the explicit style font. |
Returns: SalBoolean. True if the target style is available; otherwise, false.
TblSetRowFontName(table, row, fontName, fontSize, fontStyle)
Creates a font and assigns it to the table row.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| fontName | SalString | The font family name. |
| fontSize | SalNumber | The font size in points. |
| fontStyle | SalNumber | The SAL font-style flags. |
Returns: SalBoolean. True if the target style is available; otherwise, false.
TblSetRowHeaderBackColor(table, row, color)
Sets the row header’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| color | SalNumber | The SAL color value to translate. |
Returns: SalBoolean. True if the target style exists and is changed; otherwise, false.
TblSetRowHeaderBackColor(table, row, color)
Sets the row header’s explicit background color.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| color | Color | The new color. |
Returns: SalBoolean. True if the target style exists and is changed; otherwise, false.
TblSetRowImage(table, row, image, flags)
Sets the table row’s background image.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| image | Image | A bitmap to assign, or null to clear the image. Other Image implementations leave the style unchanged. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style exists, even when the image is not a bitmap; otherwise, false.
TblSetRowImageFile(table, row, fileName, flags)
Loads a background image from a file and assigns it to the table row.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| fileName | SalString | The image-file path. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false, including caught image-loading errors.
TblSetRowImageResource(table, row, resName, flags)
Loads a background image from a named SAL resource and assigns it to the table row.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| resName | SalString | The SAL resource name. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false.
A missing or non-bitmap resource returns false.
TblSetRowImageString(table, row, imageBlob, flags)
Loads a background image from bitmap binary data and assigns it to the table row.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| row | SalNumber | The SAL row context. |
| imageBlob | SalString | The bitmap bytes in a SAL binary string. |
| flags | TableWindowImageFlags | The image alignment or FillAll option. FillAll uses best-fit sizing; combined or unsupported values use centered original-size layout. |
Returns: SalBoolean. True if the target style accepts the operation; otherwise, false.
TblSortRows(table, colID, flags)
Sorts main-grid rows by a SAL column and updates its sort glyph and row context.
| Parameter | Type | Description |
|---|---|---|
| table | Control | The SAL table or table-form control. |
| colID | SalNumber | The SAL column identifier. |
| flags | TableWindowSort | The direction and comparison options; numeric and date columns add their respective comparison flags. |
Returns: SalBoolean. False if the table or column cannot be resolved; otherwise, true.
The comparer sends SAM_SwapRows notifications for out-of-order comparisons.
ToolboxCreate(parent, name, position, flags)
Creates a named XSal toolbox and attaches it to a form’s toolbar system.
| Parameter | Type | Description |
|---|---|---|
| parent | Control | The parent form. |
| name | SalString | The toolbox template class name. |
| position | ToolboxPositions | The docking edge. |
| flags | ToolboxFlags | The creation flags; Visible sets initial visibility. |
Returns: SalWindowHandle. The new toolbox handle, or a null handle when parent is not a form or creation returns no control.
ToolboxDestroy(parent, name)
Disposes a named toolbox associated with a form.
| Parameter | Type | Description |
|---|---|---|
| parent | Control | The containing form. |
| name | SalString | The case-sensitive toolbox name. |
Returns: SalBoolean. True if the toolbox was found and processed; otherwise, false.
ToolboxGetPosition(parent, name)
Gets a named toolbox’s docking edge.
| Parameter | Type | Description |
|---|---|---|
| parent | Control | The containing form. |
| name | SalString | The case-sensitive toolbox name. |
Returns: ToolboxPositions. The toolbox position, or None if the toolbox is absent or has no recognized toolbar parent.
ToolboxHide(parent, name)
Hides a named toolbox associated with a form.
| Parameter | Type | Description |
|---|---|---|
| parent | Control | The containing form. |
| name | SalString | The case-sensitive toolbox name. |
Returns: SalBoolean. True if the toolbox was found and processed; otherwise, false.
ToolboxHideAll(parent)
Hides all docked and owned floating toolboxes in a form’s initialized toolbar system.
| Parameter | Type | Description |
|---|---|---|
| parent | Control | The form containing the toolbar system. |
Returns: SalBoolean. True if the toolbar system exists; false when it is absent.
ToolboxIsVisible(parent, name)
Tests whether a named toolbox is visible.
| Parameter | Type | Description |
|---|---|---|
| parent | Control | The containing form. |
| name | SalString | The case-sensitive toolbox name. |
Returns: SalBoolean. True if the toolbox exists and is visible; otherwise, false.
ToolboxSetMetrics(value, type)
Sets a shared toolbar dimension or toolbox layout offset.
| Parameter | Type | Description |
|---|---|---|
| value | SalNumber | The value in pixels. |
| type | ToolbarMetrics | The metric to change; unknown values are ignored. |
Returns: SalBoolean. True.
ToolboxSetMetrics(type)
Retrieves a shared toolbar metric despite the setter-style method name.
| Parameter | Type | Description |
|---|---|---|
| type | ToolbarMetrics | The metric to read. |
Returns: SalNumber. The value in pixels, or zero for an unknown metric.
ToolboxSetPosition(parent, name, position)
Moves a named toolbox to a supported toolbar edge.
| Parameter | Type | Description |
|---|---|---|
| parent | Control | The containing form. |
| name | SalString | The case-sensitive toolbox name. |
| position | ToolboxPositions | Top, Right, Bottom, or Left; other values do not move the toolbox. |
Returns: SalBoolean. True if the toolbox exists; false when it is absent.
ToolboxShow(parent, name)
Shows a named toolbox associated with a form.
| Parameter | Type | Description |
|---|---|---|
| parent | Control | The containing form. |
| name | SalString | The case-sensitive toolbox name. |
Returns: SalBoolean. True if the toolbox was found and processed; otherwise, false.
ToolboxShowAll(parent)
Shows all docked and owned floating toolboxes in a form’s initialized toolbar system.
| Parameter | Type | Description |
|---|---|---|
| parent | Control | The form containing the toolbar system. |
Returns: SalBoolean. True if the toolbar system exists; false when it is absent.
UdvArrayDelete(Array, index)
Removes the element at the specified array index.
| Parameter | Type | Description |
|---|---|---|
| Array | SalArray | The SAL array to modify. |
| index | SalNumber | The element index. |
Returns: SalBoolean. True if the operation completes; false for an IndexOutOfRangeException.
UdvArrayInsert(Array, index)
Inserts an empty element at the specified array index.
| Parameter | Type | Description |
|---|---|---|
| Array | SalArray | The SAL array to modify. |
| index | SalNumber | The element index. |
Returns: SalBoolean. True if the operation completes; false for an IndexOutOfRangeException.
UdvArrayMove(Array, sourceIndex, targetIndex)
Inserts a copy of an array element at the target position and removes the original.
| Parameter | Type | Description |
|---|---|---|
| Array | SalArray | The array to modify. |
| sourceIndex | SalNumber | The source element index. |
| targetIndex | SalNumber | The insertion index before the original element is removed. |
Returns: SalBoolean. True on success or when the indices are equal; false for an IndexOutOfRangeException.
UdvArraySort(Array, fieldName, dataType, sortOrder)
Sorts a one-dimensional object array by a public field or property.
| Parameter | Type | Description |
|---|---|---|
| Array | SalArray | The array to sort. |
| fieldName | SalString | The public field or property name on the element type. |
| dataType | SalNumber | Reserved for compatibility; ignored. |
| sortOrder | SalNumber | The sort order consumed by the member comparer. |
Returns: SalBoolean. True when sorting completes or the array has fewer than two elements; false for a multidimensional array, empty member name, or missing member.
UdvArraySwap(Array, index1, index2)
Exchanges two array elements.
| Parameter | Type | Description |
|---|---|---|
| Array | SalArray | The SAL array to modify. |
| index1 | SalNumber | The first element index. |
| index2 | SalNumber | The second element index. |
Returns: SalBoolean. True if the exchange completes; false for an IndexOutOfRangeException.
UdvClone(source, target)
Clones a functional-class object by binary serialization and deserialization.
| Parameter | Type | Description |
|---|---|---|
| source | SalFunctionalClass | The serializable object to copy. |
| target | SalFunctionalClass | Receives the deserialized copy. |
Returns: SalBoolean. True if both operations succeed; false for a null source.
UdvFromString(obj, source)
Deserializes a functional-class object from a BinaryFormatter binary string.
| Parameter | Type | Description |
|---|---|---|
| obj | SalFunctionalClass | Receives the deserialized object. |
| source | SalString | The serialized binary data. |
Returns: SalBoolean. False for null or empty binary data; true after deserialization.
The input must be trusted serialized application data. Deserialization and cast errors propagate.
UdvToString(obj, target)
Serializes a functional-class object into a SAL binary string using BinaryFormatter.
| Parameter | Type | Description |
|---|---|---|
| obj | SalFunctionalClass | The serializable object. |
| target | SalString | Receives the serialized stream buffer. |
Returns: SalBoolean. False for a null object; true after serialization.
Serialization exceptions propagate to the caller.
ZipCloseArchive(zipFile)
Closes the archive and releases its allocated handle.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | The live archive handle; its numeric value is not reset after release. |
Returns: SalBoolean. True if archive closure succeeds; false for a zero handle or a caught closure error.
The handle is released in the finally block even when archive closure fails. Do not reuse the released value.
ZipCloseFile(zipFile)
Closes the current archive entry.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | The archive handle whose entry is open. |
Returns: SalBoolean. True if closure succeeds; false for a caught archive error.
ZipCreateFile(zipFile, fileName, date, comment, compressionLevel)
Creates a writable entry in an output ZIP archive.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | The open output-archive handle. |
| fileName | SalString | The entry path within the archive. |
| date | SalDateTime | The entry timestamp. |
| comment | SalString | The entry comment. |
| compressionLevel | SalNumber | The compression level passed to the ZIP implementation. |
Returns: SalBoolean. True if an entry is created; false for a zero handle or a caught error.
ZipFindFile(zipFile, fileName)
Selects an archive entry by name.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | The open input-archive handle. |
| fileName | SalString | The archive entry name to find. |
Returns: SalBoolean. True if the entry is found; false for a zero handle, no match, or a caught archive error.
ZipFindFirstFile(zipFile)
Selects the first entry and resets archive enumeration.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | The open input-archive handle. |
Returns: SalBoolean. True if an entry exists; false for a zero handle, no matching entry, or a caught archive error.
ZipFindNextFile(zipFile)
Advances to the next archive entry.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | The open input-archive handle. |
Returns: SalBoolean. True if an entry exists; false for a zero handle, no matching entry, or a caught archive error.
ZipGetFileInfo(zipFile, fileName, comment, date, compressedSize, uncompressedSize)
Retrieves metadata for the currently selected ZIP entry.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | The input-archive handle. |
| fileName | SalString | Receives the entry name. |
| comment | SalString | Receives the entry comment. |
| date | SalDateTime | Receives the entry timestamp. |
| compressedSize | SalNumber | Receives the compressed size in bytes. |
| uncompressedSize | SalNumber | Receives the uncompressed size in bytes. |
Returns: SalBoolean. True if metadata is retrieved; false for a zero handle, no selected entry, or a caught error.
ZipOpenArchive(zipFile, fileName, mode)
Opens an existing ZIP archive for reading or creates a new archive for writing.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | Receives an allocated archive handle on success. |
| fileName | SalString | The archive path. |
| mode | SalNumber | OF_Read to open or OF_Write to create and overwrite the file. |
Returns: SalBoolean. True if the archive handle is allocated; false for another mode or a caught archive error.
Requires the dynamically loaded SharpZipLib archive support. Close the archive handle when finished.
ZipOpenFile(zipFile)
Opens the currently selected archive entry for reading.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | The input-archive handle with an entry selected. |
Returns: SalBoolean. True if an entry stream is opened; otherwise, false.
ZipRead(zipFile, content, count)
Reads bytes from the currently open archive entry.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | The input-archive handle. |
| content | SalString | Receives the bytes read, or empty text when no bytes are read. A nonpositive count leaves it unchanged. |
| count | SalNumber | The maximum number of bytes to read. |
Returns: SalNumber. The number of bytes read, or zero for a nonpositive count or a caught read error.
ZipWrite(zipFile, buffer, length)
Writes bytes to the current output ZIP entry.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | The open output-archive handle. |
| buffer | SalString | The SAL string whose binary buffer is written. |
| length | SalNumber | The number of bytes to write from the beginning of the buffer. |
Returns: SalBoolean. True if writing succeeds; false for a zero archive handle or a caught write error.
ZipWrite(zipFile, buffer, length)
Writes bytes to the current output ZIP entry.
| Parameter | Type | Description |
|---|---|---|
| zipFile | SalNumber | The open output-archive handle. |
| buffer | Byte[] | The source byte array. |
| length | SalNumber | The number of bytes to write from the beginning of the buffer. |
Returns: SalBoolean. True if writing succeeds; false for a zero archive handle or a caught write error.