ServiceController in MAUI application

דני שטרית 2,266 Reputation points
2022-06-30T10:49:23.157+00:00

Hi,
Can you please tell when we can you ServiceController in MAUI application?
Thanks,

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
2,618 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Rob Caplan - MSFT 5,397 Reputation points Microsoft Employee
    2022-06-30T21:02:14.433+00:00

    System.ServiceProcess.ServiceController is currently available to .Net 6 apps running on Windows, including those using MAUI.

    ServiceController is not relevant on other platforms and will raise a PlatformNotSupportedException:

    ServiceController enables manipulating and accessing Windows services and it is not applicable for other operating systems.

    0 comments No comments