ResourceForkMBS properties

Online Documentation   -   Statistics   -   FAQ   -   Plugin Parts (All, Dependencies)   -   Class hierarchy

New in Version 22.2 22.3 22.4 22.5 23.0 23.1 23.2 23.3 23.4 23.5 24.0 24.1

The list of the   topics,   classes,   interfaces,   controls,   modules,   global methods by category,   global methods by name,   screenshots,   licenses   and   examples.

Platforms to show: All Mac Windows Linux Cross-Platform

Back to ResourceForkMBS class.

ResourceForkMBS.Handle as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Files MBS MacClassic Plugin 13.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The internal handle to the resource fork.

(Read only property)

ResourceForkMBS.LastError as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Files MBS MacClassic Plugin 13.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The last error code.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.rsrc")
dim r as ResourceForkMBS = ResourceForkMBS.Open(f, false) // open read only

r.AddResource "Hello World", "TEXT", 128, "just a test"
MsgBox str(R.LastError) // shows -61, write permission error

All methods set this property.
(Read and Write property)

ResourceForkMBS.Modified as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Files MBS MacClassic Plugin 13.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Whether the resource fork has been modified by you.

(Read only property)

ResourceForkMBS.TypeCount as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Files MBS MacClassic Plugin 13.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
The number of resource types present in the resource fork.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.rsrc")
dim r as ResourceForkMBS = ResourceForkMBS.create(f)

r.AddResource "Hello World", "TEXT", 128, "just a test"

MsgBox str(r.TypeCount) // shows 1

(Read only property)

ResourceForkMBS.Writable as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property Files MBS MacClassic Plugin 13.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Whether the resourcefork was opened writable.

(Read only property)

The items on this page are in the following plugins: MBS MacClassic Plugin.


💬 Ask a question or report a problem