Method OpenAsync
OpenAsync(String)
Opens a SymbolStyle in the specified path.
Declaration
public static async Task<SymbolStyle> OpenAsync(string styleLocation)
Parameters
Type | Name | Description |
---|---|---|
System.String | styleLocation | Physical location of the .stylx file. Need to provide the full path (e.g. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<SymbolStyle> | The symbol style at the specified path. |
Applies to
Platforms and versions
Target | Versions |
---|---|
.NET Standard 2.0 | 100.3 - 100.15 |
.NET 6.0 | 100.13 - 100.15 |
.NET 6.0 Windows | 100.13 - 100.15 |
.NET Framework | 100.0 - 100.15 |
.NET 5 | 100.10 - 100.12 |
.NET Core 3.1 | 100.7 - 100.12 |
Xamarin.Android | 100.0 - 100.15 |
Xamarin.iOS | 100.0 - 100.15 |
UWP | 100.0 - 100.15 |
OpenAsync(PortalItem)
Opens a new SymbolStyle object from a portal item. The portal item must be a web style.
Declaration
public static async Task<SymbolStyle> OpenAsync(PortalItem portalItem)
Parameters
Type | Name | Description |
---|---|---|
PortalItem | portalItem | If you have the item id of a style file, you can search the portal to find the item using its uri or item Id. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<SymbolStyle> | The symbol style. |
Remarks
Use this constructor if you have a reference to a web style portal item.
Exceptions
Type | Condition |
---|---|
ArcGISRuntimeException |
|
Applies to
Platforms and versions
Target | Versions |
---|---|
.NET Standard 2.0 | 100.10 - 100.15 |
.NET 6.0 | 100.13 - 100.15 |
.NET 6.0 Windows | 100.13 - 100.15 |
.NET Framework | 100.10 - 100.15 |
.NET 5 | 100.10 - 100.12 |
.NET Core 3.1 | 100.10 - 100.12 |
Xamarin.Android | 100.10 - 100.15 |
Xamarin.iOS | 100.10 - 100.15 |
UWP | 100.10 - 100.15 |
OpenAsync(String, ArcGISPortal)
Opens a new SymbolStyle from a portal item. The portal item must contain a webstyle style.
Declaration
public static async Task<SymbolStyle> OpenAsync(string styleName, ArcGISPortal portal)
Parameters
Type | Name | Description |
---|---|---|
System.String | styleName | The registered symbol style name on the portal. |
ArcGISPortal | portal | The portal that contains the web style. If |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<SymbolStyle> | The web style. |
Remarks
Use this method to create a symbol style using the web style's unique name on the portal.
If null
is passed, ArcGIS online is used as
the default portal.
Esri provides a set of webstyles "out of the box" for localized use with ArcGIS Online and Enterprise. An overview of styles and symbols currently in production is available for 3D and 2D..
Tip: Click on the symbol icon to find it's associated style name. Registered style name can also be found in the item json of the symbols style. For example refer to item json for EsriThematicShapesStyle web style hosted on ArcGIS Online.
Applies to
Platforms and versions
Target | Versions |
---|---|
.NET Standard 2.0 | 100.10 - 100.15 |
.NET 6.0 | 100.13 - 100.15 |
.NET 6.0 Windows | 100.13 - 100.15 |
.NET Framework | 100.10 - 100.15 |
.NET 5 | 100.10 - 100.12 |
.NET Core 3.1 | 100.10 - 100.12 |
Xamarin.Android | 100.10 - 100.15 |
Xamarin.iOS | 100.10 - 100.15 |
UWP | 100.10 - 100.15 |
OpenAsync(Uri)
Opens a new SymbolStyle from a web style item Uri.
Declaration
public static Task<SymbolStyle> OpenAsync(Uri source)
Parameters
Type | Name | Description |
---|---|---|
Uri | source | Webstyle item Uri. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<SymbolStyle> | The symbol style |
Remarks
A symbol style using style item's Uri. For example, https://www.arcgis.com/home/item.html?id=bf27400d167d4c2e8e12c8a46f87afe4 is the Uri of the "Basic Shapes" style on ArcGIS Online."
Applies to
Platforms and versions
Target | Versions |
---|---|
.NET Standard 2.0 | 100.10 - 100.15 |
.NET 6.0 | 100.13 - 100.15 |
.NET 6.0 Windows | 100.13 - 100.15 |
.NET Framework | 100.10 - 100.15 |
.NET 5 | 100.10 - 100.12 |
.NET Core 3.1 | 100.10 - 100.12 |
Xamarin.Android | 100.10 - 100.15 |
Xamarin.iOS | 100.10 - 100.15 |
UWP | 100.10 - 100.14 |