AssetDatabase.IsOpenForEdit

static function IsOpenForEdit (assetObject : UnityEngine.Object) : boolean

static function IsOpenForEdit (assetPath : String) : boolean

static function IsOpenForEdit (assetObject : UnityEngine.Object, out message : String) : boolean

static function IsOpenForEdit (assetPath : String, out message : String) : boolean

Parameters

NameDescription
assetPath Is the path to the asset on disk relative to project folder.
message Used to give reason for not open.

Returns

boolean - True is the asset can be edited.

Description

Use IsOpenForEdit to determine if the asset is open for edit by the version control.

Used to disable editor controls.