Skip to main content

DeviceLauncher

Namespace: Wisej.Hybrid

Assembly: Wisej.Hybrid

Provides methods to interact with app launching and external file opening on the device.

public class DeviceLauncher

Access this class through the Device singleton.

See Launch External Apps for scheme configuration and an async Wisej event handler.

Constructors​

Instance memberDeviceLauncher()​

Initializes a new instance of DeviceLauncher.

Methods​

Instance memberCanOpenAsync(url)​

Checks whether a given app link can be opened on the device.

ParameterTypeDescription
urlStringThe app link (e.g., "lyft://") to check for availability.

Returns: Task<bool>. Await the result; it is true if the app link can be opened. This name matches the published 4.1.4 XML; the former synchronous CanOpen entry was stale.

Instance memberOpen(url)​

Attempts to open the given application link on the device.

ParameterTypeDescription
urlStringThe application link (e.g., "lyft://ridetype?id=lyft_line") to open.

Instance memberOpen(popoverTitle, fileName, fileData)​

Opens the given file using the default app associated with its file type.

ParameterTypeDescription
popoverTitleStringThe title for the file picker popover (iOS only).
fileNameStringThe name of the file to open.
fileDataByte[]The byte array containing the file's data.

TryOpenAsync(url)​

Attempts to open an application URI and returns Task<bool>. This async method is present in the published 4.1.4 XML.

See: https://learn.microsoft.com/en-us/dotnet/maui/platform-integration/appmodel/launcher. Throws: