Xojo Conferences
XDCMay2019MiamiUSA

Platforms to show: All Mac Windows Linux Cross-Platform

NSAppleEventDescriptorMBS.aeDesc as Ptr
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns a pointer to the AEDesc structure that is encapsulated by the receiver, if it has one.
Notes:
If the receiver has a valid AEDesc structure, returns a pointer to it; otherwise returns nil.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.applicationURLValue as String
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 16.2 Yes No No Yes, macOS only No
Function: The application URL.
Example:
dim f as FolderItem = SpecialFolder.Applications.Child("Stickies.app")
dim u as string = f.URLPath
dim d as NSAppleEventDescriptorMBS = NSAppleEventDescriptorMBS.descriptorWithApplicationURL(u)
MsgBox d.applicationURLValue
Notes: (Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.booleanValue as boolean
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the contents of the receiver as a Boolean value, coercing (to typeBoolean) if necessary.
Example:
dim lines(-1) as string

lines.Append "set a to 1"
lines.Append "set b to 1"
lines.Append "return a = b" // return a boolean result

// compile, run and show value
dim source as string = Join(lines,EndOfLine)
dim n as new NSAppleScriptMBS(source)

dim error as Dictionary
dim d as NSAppleEventDescriptorMBS = n.execute(Error)

MsgBox str(d.booleanValue)
Notes:
Returns the contents of the descriptor, as a Boolean value, or false if an error occurs.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.bundleIDValue as String
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 16.2 Yes No No Yes, macOS only No
Function: Queries the bundle identifier.
Example:
dim d as NSAppleEventDescriptorMBS = NSAppleEventDescriptorMBS.descriptorWithBundleIdentifier("com.apple.iCal")
MsgBox d.bundleIDValue
Notes: (Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.data as Memoryblock
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the receiver's data as a memoryblock.
Notes:
Returns an instance of memoryblock containing the receiver's data, or nil if an error occurs.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.dateValue as date
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the contents of the receiver as a date value.
Example:
dim d as new date
dim n as NSAppleEventDescriptorMBS = NSAppleEventDescriptorMBS.descriptorWithDate(d)

dim x as date = n.dateValue
MsgBox x.LongDate+" "+x.LongTime // shows today
Notes: (Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.description as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 12.1 Yes No No Yes, macOS only No
Function: The descriptor for this event.
Example:
dim n as NSAppleEventDescriptorMBS = NSAppleEventDescriptorMBS.descriptorWithString("Hello")
MsgBox n.description
Notes:
This is a text representation for debugging.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.descriptorType as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the descriptor type of the receiver.
Notes: (Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.doubleValue as Double
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the contents of the receiver as a double.
Example:
dim a as NSAppleEventDescriptorMBS
a = NSAppleEventDescriptorMBS.descriptorWithString("5")
MsgBox str(a.doubleValue) // shows 5
Notes: (Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.enumCodeValue as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the contents of the receiver as an enumeration type, coercing (to typeEnumerated) if necessary.
Notes:
Returns the contents of the descriptor, as an enumeration type, or 0 if an error occurs.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.eventClass as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the event class for the receiver.
Notes:
Returns the event class (a four-character code) for the receiver, or 0 if an error occurs.

The receiver must be an Apple event. An Apple event is identified by its event class and event ID, a pair of four-character codes stored as 32-bit integers. For example, most events in the Standard suite have the four-character code 'core' (defined as the constant kAECoreSuite in AE.framework, a subframework of ApplicationServices.framework). For more information on event classes and event IDs, see Building an Apple Event in Apple Events in Apple Events Programming Guide.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.eventID as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the event ID for the receiver.
Notes:
The event ID (a four-character code) for the receiver, or 0 if an error occurs.

The receiver must be an Apple event. An Apple event is identified by its event class and event ID, a pair of four-character codes stored as 32-bit integers. For example, the open Apple event from the Standard suite has the four-character code 'odoc' (defined as the constant kAEOpen in AE.framework, a subframework of ApplicationServices.framework).
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.fileURLValue as String
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 16.2 Yes No No Yes, macOS only No
Function: The file URL.
Example:
dim f as FolderItem = SpecialFolder.Applications.Child("Stickies.app")
dim d as NSAppleEventDescriptorMBS = NSAppleEventDescriptorMBS.descriptorWithFileURL(f)
MsgBox d.fileURLValue
Notes: (Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.FSRefValue as folderitem
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.3 Yes No No Yes, macOS only No
Function: Resolves a folderitem reference.
Example:
// pick a folderitem
dim folder as FolderItem = SpecialFolder.Desktop

// create value with file reference
dim d as NSAppleEventDescriptorMBS = NSAppleEventDescriptorMBS.descriptorWithFSRef(folder)

// show path
MsgBox d.stringValue

// convert back to FolderItem
dim file as FolderItem = d.FSRefValue

// show path
MsgBox file.AbsolutePath
Notes:
NSAppleEventDescriptorMBS objects with strings, FSRef or Alias data are converted automatically.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.Handle as Integer
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the internal reference to the NSAppleEventDescriptor object.
Notes: (Read and Write property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.int16Value as Int16
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the contents of the receiver as an int16.
Example:
dim a as NSAppleEventDescriptorMBS
a = NSAppleEventDescriptorMBS.descriptorWithString("5")
MsgBox str(a.int16Value) // shows 5
Notes: (Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.int32Value as Int32
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the contents of the receiver as an integer, coercing (to typeSInt32) if necessary.
Example:
dim a as NSAppleEventDescriptorMBS
a = NSAppleEventDescriptorMBS.descriptorWithString("5")
MsgBox str(a.int32Value) // shows 5
Notes:
Returns the contents of the descriptor, as an integer value, or 0 if an error occurs.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.isRecordDescriptor as Boolean
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 16.2 Yes No No Yes, macOS only No
Function: Return whether or not a descriptor is a record-like descriptor.
Notes:
Record-like descriptors function as records, but may have a descriptorType other than AERecord, such as ObjectSpecifier.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.numberOfItems as Integer
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the number of descriptors in the receiver's descriptor list.
Example:
dim n as NSAppleEventDescriptorMBS = NSAppleEventDescriptorMBS.listDescriptor
dim d as NSAppleEventDescriptorMBS = NSAppleEventDescriptorMBS.descriptorWithString("Hello")
dim e as NSAppleEventDescriptorMBS = NSAppleEventDescriptorMBS.descriptorWithString("World")

n.insertDescriptor(d,1)
n.insertDescriptor(e,2)

MsgBox str(n.numberOfItems)

dim x1 as NSAppleEventDescriptorMBS = n.descriptorAtIndex(1)
dim x2 as NSAppleEventDescriptorMBS = n.descriptorAtIndex(2)
MsgBox x1.stringValue+" "+x2.stringvalue
Notes:
Returns the number of descriptors in the receiver's descriptor list (possibly 0); returns 0 if an error occurs.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.processIDValue as Integer
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 16.2 Yes No No Yes, macOS only No
Function: Queries the process ID.
Example:
// get my PID
dim p as new ProcessMBS
p.GetCurrentProcess
dim pid as Integer = p.ProcessID

// make process ID descriptor
dim n as NSAppleEventDescriptorMBS = NSAppleEventDescriptorMBS.descriptorWithProcessIdentifier(pid)

// show it
MsgBox "ProcessID: "+str(n.processIDValue) + EndOfLine + n.stringValue
Notes: (Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.returnID as Int16
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the receiver's return ID (the ID for a reply Apple event).
Notes:
Returns the receiver's return ID (an integer value), or 0 if an error occurs.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.singleValue as single
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the contents of the receiver as a single value.
Example:
dim a as NSAppleEventDescriptorMBS
a = NSAppleEventDescriptorMBS.descriptorWithString("5")
MsgBox str(a.singleValue) // shows 5
Notes: (Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.stringValue as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the contents of the receiver as a Unicode text string, coercing (to typeUnicodeText) if necessary.
Example:
dim a as NSAppleEventDescriptorMBS

a = NSAppleEventDescriptorMBS.descriptorWithString("Hello World")

MsgBox a.stringValue
Notes:
Returns the contents of the descriptor, as a string, or "" if an error occurs.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.transactionID as Int32
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the receiver's transaction ID, if any.
Notes:
Returns the receiver's transaction ID (an integer value), or 0 if an error occurs.

The receiver must be an Apple event. Currently provides no indication if an error occurs. For more information on transactions, see the description for appleEventWithEventClass.
(Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.typeCodeValue as string
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the contents of the receiver as a type, coercing (to typeType) if necessary.
Notes: (Read only property)

Feedback, Comments & Corrections

NSAppleEventDescriptorMBS.UInt32Value as UInt32
Type Topic Plugin Version macOS Windows Linux Console & Web iOS
property Apple Script MBS MacCocoa Plugin 11.2 Yes No No Yes, macOS only No
Function: Returns the contents of the receiver as an UInt32.
Example:
dim a as NSAppleEventDescriptorMBS
a = NSAppleEventDescriptorMBS.descriptorWithString("5")
MsgBox str(a.UInt32Value) // shows 5
Notes: (Read only property)

Feedback, Comments & Corrections

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




Links
MBS Xojo tutorial videos