Raised if a method is only for a particular platform but it was called from another platform. The functions FolderItem.MacFSRef and FolderItem.CreateFromMacFSRef raise this exception if called from Windows or Linux.
A PlatformNotSupportedException is raised if you call a method on Carbon that is supported only on Cocoa. For example, this example will raise an exception from a Carbon build because alpha channels are supported on Cocoa, not Carbon. You can fix this by setting the target platform in the Build Settings dialog box.
dim height as integer = 2000
// creates new picture
dim pic as new Picture(width, height) //constructor for a picture with an alpha channel
dim f as FolderItem
if f<> Nil then
exception err as PlatformNotSupportedException