HLK Studio Automation: System.ArgumentException: The driver package must support at least one operating system.

Roman Kantor 1 Reputation point
2021-11-01T19:24:03.433+00:00

HLK Studio Automation: System.ArgumentException: The driver package must support at least one operating system.
Parameter name: operatingSystems

When I am trying to automate the package creation for whql using packageWriter. I get this error below.
When I create the package using HLK studio GUI providing the path to the same driver.. it does not throw any errors. Any help would be much appreciated.

at Microsoft.UniversalStore.HardwareWorkflow.SubmissionBuilder.DriverPackageInfo..ctor(String driverPackagePath, OperatingSystems operatingSystems, Boolean microsoftDriverPackage, Boolean useLocalDate, Boolean isAudioDriver, Boolean isGraphicsDriver, String workingDirectory)

at Microsoft.Windows.Kits.Hardware.ObjectModel.Submission.PackageWriter.SignabilityTest(DriverInformation driverInfo, OperatingSystems detectedOSs, List1& errors, List1& warnings)

at Microsoft.Windows.Kits.Hardware.ObjectModel.Submission.PackageWriter.RunSignabilityTests(DriverInformation driverInfo, List1& errors, List1& warnings)

at Microsoft.Windows.Kits.Hardware.ObjectModel.Submission.PackageWriter.AddDriver(String pathToDriver, String pathToSymbols, IEnumerable1 targets, IEnumerable1 locales, Boolean validateDriverSignabilityForDownLevel, StringCollection& errorMessages, StringCollection& warningMessages)

at Microsoft.Windows.Kits.Hardware.ObjectModel.Submission.PackageWriter.AddDriver(String pathToDriver, String pathToSymbols, IEnumerable1 targets, IEnumerable1 locales, StringCollection& errorMessages, StringCollection& warningMessages)

Windows for business | Windows Client for IT Pros | Devices and deployment | Other
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Roman Kantor 1 Reputation point
    2021-11-04T22:56:32.07+00:00

    Ended up using PowerShell scripting.
    For some reason when doing the same thing using PowerShell script instead of C# it does not throw this error.

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.