# assetPath

> The path name of the asset for this importer. (Read Only)

## Definition

* **Type:** Property
* **Namespace:** [UnityEditor](/engine/6000.0/script-reference/unityeditor.md)
* **Assembly:** UnityEditor

```csharp
public string assetPath { get; }
```

### Examples

```csharp
using UnityEngine;
using UnityEditor;
public class AssetPathExample : MonoBehaviour
{
    [MenuItem("Tools/AssetPathExample")]
    static void Example()
    {
        var importers = AndroidAssetPackImporter.GetAllImporters();

        foreach (var importer in importers)
        {
            var labels = new string[0];
            //Get asset path
            var path = importer.assetPath;
            //Use asset path to set labels if path contains "Icon"
            if (path.Contains("Icon"))
            {
                labels = new [] { "Icon" };
                AssetDatabase.SetLabels(AssetDatabase.LoadAssetAtPath<Object>(path), labels);
            }
        }
    }
}
```
