Solved Kiosk Mode Customization Questions


Where did you get that cmdlet name, Set-AssignedAccessConfiguration? I can't find it anywhere.
 

My Computers

System One System Two

  • OS
    Windows 11 Pro 23H2 [rev. 3447]
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC12WSHi7
    CPU
    12th Gen Intel Core i7-1260P, 2100 MHz
    Motherboard
    NUC12WSBi7
    Memory
    64 GB
    Graphics Card(s)
    Intel Iris Xe
    Sound Card
    built-in Realtek HD audio
    Monitor(s) Displays
    Dell U3219Q
    Screen Resolution
    3840x2160 @ 60Hz
    Hard Drives
    Samsung SSD 990 PRO 1TB
    Keyboard
    CODE 104-Key Mechanical Keyboard with Cherry MX Clears
  • Operating System
    Linux Mint 21.2 (Cinnamon)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC8i5BEH
    CPU
    Intel Core i5-8259U CPU @ 2.30GHz
    Memory
    32 GB
    Graphics card(s)
    Iris Plus 655
    Keyboard
    CODE 104-Key Mechanical Keyboard - Cherry MX Clear
Attached is a PowerShell script, based on the article in post #18. It allows Calculator, Weather and Firefox, so you'll want to adjust what's in the XML at the top. The point was to show you can use Store apps and classic Win32 apps.

Near the bottom of the XML, on line 29, you can see I'm assigning it to a specific account. You'll almost surely need to change that, to reflect the account name you want to use. I would recommend you assign things to a test account first, so you can play around with the XML and get it just how you want it. Then, assign it to the real user account when you're satisfied.
 

Attachments

  • restricted-experience.ps1
    2.8 KB · Views: 1

My Computers

System One System Two

  • OS
    Windows 11 Pro 23H2 [rev. 3447]
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC12WSHi7
    CPU
    12th Gen Intel Core i7-1260P, 2100 MHz
    Motherboard
    NUC12WSBi7
    Memory
    64 GB
    Graphics Card(s)
    Intel Iris Xe
    Sound Card
    built-in Realtek HD audio
    Monitor(s) Displays
    Dell U3219Q
    Screen Resolution
    3840x2160 @ 60Hz
    Hard Drives
    Samsung SSD 990 PRO 1TB
    Keyboard
    CODE 104-Key Mechanical Keyboard with Cherry MX Clears
  • Operating System
    Linux Mint 21.2 (Cinnamon)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC8i5BEH
    CPU
    Intel Core i5-8259U CPU @ 2.30GHz
    Memory
    32 GB
    Graphics card(s)
    Iris Plus 655
    Keyboard
    CODE 104-Key Mechanical Keyboard - Cherry MX Clear
The cmdlet was provided by ChatGPT.

Thank you for the .xml or .json file. I may have issues when I get to this point, but my real issue is not being able to determine HOW to enter my file or yours into PowerShell? The syntax I am trying is obviously not correct, but search as I might, ChatGPT was the only place that actually had an answer to that question. Al least that I could find......... The original link you gave me in post #2 was interesting, but at least I could not find how to use PowerShell to enter the file I create.
 

My Computer

System One

  • OS
    Windows 11
    Computer type
    PC/Desktop
    Manufacturer/Model
    Scratch Build
    CPU
    AMD Ryzen 7 Processor
    Motherboard
    ACUSTeK, TUF Gaming XS70-PLUS
    Memory
    16
    Graphics Card(s)
    NVIDIA GeForce GTX 1660 Ti
    Sound Card
    NVIDIA High Definition Audio
    Monitor(s) Displays
    BenQ
Looking over your file in more detail. Are you saying that I just copy & past the whole code into PowerShell?
 

My Computer

System One

  • OS
    Windows 11
    Computer type
    PC/Desktop
    Manufacturer/Model
    Scratch Build
    CPU
    AMD Ryzen 7 Processor
    Motherboard
    ACUSTeK, TUF Gaming XS70-PLUS
    Memory
    16
    Graphics Card(s)
    NVIDIA GeForce GTX 1660 Ti
    Sound Card
    NVIDIA High Definition Audio
    Monitor(s) Displays
    BenQ
You can save the file I posted in #22, and make sure it saves with a .ps1 extension. Then, if you're new to PowerShell, it's probably easiest to find "PowerShell ISE" on the Start menu, and run it as administrator. Open the file I posted, make adjustments to the user account name and the programs list, and then hit the Play button in the toolbar to run it.

Screenshot 2024-03-22 221538.png
 

My Computers

System One System Two

  • OS
    Windows 11 Pro 23H2 [rev. 3447]
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC12WSHi7
    CPU
    12th Gen Intel Core i7-1260P, 2100 MHz
    Motherboard
    NUC12WSBi7
    Memory
    64 GB
    Graphics Card(s)
    Intel Iris Xe
    Sound Card
    built-in Realtek HD audio
    Monitor(s) Displays
    Dell U3219Q
    Screen Resolution
    3840x2160 @ 60Hz
    Hard Drives
    Samsung SSD 990 PRO 1TB
    Keyboard
    CODE 104-Key Mechanical Keyboard with Cherry MX Clears
  • Operating System
    Linux Mint 21.2 (Cinnamon)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC8i5BEH
    CPU
    Intel Core i5-8259U CPU @ 2.30GHz
    Memory
    32 GB
    Graphics card(s)
    Iris Plus 655
    Keyboard
    CODE 104-Key Mechanical Keyboard - Cherry MX Clear
Thanks! So, this makes sense. What does the "namespaceName" portion of the code do?
 

My Computer

System One

  • OS
    Windows 11
    Computer type
    PC/Desktop
    Manufacturer/Model
    Scratch Build
    CPU
    AMD Ryzen 7 Processor
    Motherboard
    ACUSTeK, TUF Gaming XS70-PLUS
    Memory
    16
    Graphics Card(s)
    NVIDIA GeForce GTX 1660 Ti
    Sound Card
    NVIDIA High Definition Audio
    Monitor(s) Displays
    BenQ
For lack of a better term, that's the "section" of WMI that this configuration data will get dumped into.
 

My Computers

System One System Two

  • OS
    Windows 11 Pro 23H2 [rev. 3447]
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC12WSHi7
    CPU
    12th Gen Intel Core i7-1260P, 2100 MHz
    Motherboard
    NUC12WSBi7
    Memory
    64 GB
    Graphics Card(s)
    Intel Iris Xe
    Sound Card
    built-in Realtek HD audio
    Monitor(s) Displays
    Dell U3219Q
    Screen Resolution
    3840x2160 @ 60Hz
    Hard Drives
    Samsung SSD 990 PRO 1TB
    Keyboard
    CODE 104-Key Mechanical Keyboard with Cherry MX Clears
  • Operating System
    Linux Mint 21.2 (Cinnamon)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC8i5BEH
    CPU
    Intel Core i5-8259U CPU @ 2.30GHz
    Memory
    32 GB
    Graphics card(s)
    Iris Plus 655
    Keyboard
    CODE 104-Key Mechanical Keyboard - Cherry MX Clear
Ok, I am getting pulled away. I will study your code further tomorrow and make the changes. Then try to insert it in PowerShell ISE. See what happens.

Here is the test code I was trying to insert originally.
 

Attachments

  • Test Code.txt
    1.5 KB · Views: 1

My Computer

System One

  • OS
    Windows 11
    Computer type
    PC/Desktop
    Manufacturer/Model
    Scratch Build
    CPU
    AMD Ryzen 7 Processor
    Motherboard
    ACUSTeK, TUF Gaming XS70-PLUS
    Memory
    16
    Graphics Card(s)
    NVIDIA GeForce GTX 1660 Ti
    Sound Card
    NVIDIA High Definition Audio
    Monitor(s) Displays
    BenQ

pseymour,​

I made the necessary changes to your .ps1 script. Implemented it in PowerShell ISE and was successful. Now the issues:

1) AssignedAccess to the user made no difference. Nothing seemed to have changed. I rebooted, still nothing different. User account could still see, access, and run any app.

2) What do I run to back out the AssignedAccess changes? Found a couple of things online, but they did not work?

Oh, one other thing. Not sure it matters, but when I paste the code/script into PowerShell ISE, the run button remains greyed out. I have to hit enter on the keyboard to get any script to run.

Thanks!
 

My Computer

System One

  • OS
    Windows 11
    Computer type
    PC/Desktop
    Manufacturer/Model
    Scratch Build
    CPU
    AMD Ryzen 7 Processor
    Motherboard
    ACUSTeK, TUF Gaming XS70-PLUS
    Memory
    16
    Graphics Card(s)
    NVIDIA GeForce GTX 1660 Ti
    Sound Card
    NVIDIA High Definition Audio
    Monitor(s) Displays
    BenQ
Sounds like maybe something is awry with the modified code. Can you paste it here? And if nothing changed for the user, what needs to be rolled back?
 

My Computers

System One System Two

  • OS
    Windows 11 Pro 23H2 [rev. 3447]
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC12WSHi7
    CPU
    12th Gen Intel Core i7-1260P, 2100 MHz
    Motherboard
    NUC12WSBi7
    Memory
    64 GB
    Graphics Card(s)
    Intel Iris Xe
    Sound Card
    built-in Realtek HD audio
    Monitor(s) Displays
    Dell U3219Q
    Screen Resolution
    3840x2160 @ 60Hz
    Hard Drives
    Samsung SSD 990 PRO 1TB
    Keyboard
    CODE 104-Key Mechanical Keyboard with Cherry MX Clears
  • Operating System
    Linux Mint 21.2 (Cinnamon)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC8i5BEH
    CPU
    Intel Core i5-8259U CPU @ 2.30GHz
    Memory
    32 GB
    Graphics card(s)
    Iris Plus 655
    Keyboard
    CODE 104-Key Mechanical Keyboard - Cherry MX Clear
Here is your file (Same name but modified) & what the PowerShell ISE accepted. It could be that the PinnedList or AllowedApps I changed did have some syntax errors? I tried to made them exactly like the ones you had in the template.

Plus, I just did not know if having that code/script floating around might harm something latter on....... What is the syntax to see what PowerShell shows for AssignedAccess for that user?

Also, I did NOT generate a new Profile #. I used the one you provided........
 

Attachments

  • restricted-experience.ps1
    4 KB · Views: 1
Last edited:

My Computer

System One

  • OS
    Windows 11
    Computer type
    PC/Desktop
    Manufacturer/Model
    Scratch Build
    CPU
    AMD Ryzen 7 Processor
    Motherboard
    ACUSTeK, TUF Gaming XS70-PLUS
    Memory
    16
    Graphics Card(s)
    NVIDIA GeForce GTX 1660 Ti
    Sound Card
    NVIDIA High Definition Audio
    Monitor(s) Displays
    BenQ
I ran the script again & here is the error message:

Write-Output "Successfully applied Assigned Access configuration"
The property 'Configuration' cannot be found on this object. Verify that the property exists and can be set.
At line:56 char:1
+ $obj.Configuration = [System.Net.WebUtility]::HtmlEncode($assignedAcc ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : PropertyNotFound

Set-CimInstance : Cannot bind argument to parameter 'InputObject' because it is null.
At line:57 char:37
+ $obj = Set-CimInstance -CimInstance $obj -ErrorVariable cimSetError - ...
+ ~~~~
+ CategoryInfo : InvalidData: (:) [Set-CimInstance], ParameterBindingValidationException
+ FullyQualifiedErrorId : ParameterArgumentValidationErrorNullNotAllowed,Microsoft.Management.Infrastructure.CimCmdlets.SetCimInstanceCommand
 

My Computer

System One

  • OS
    Windows 11
    Computer type
    PC/Desktop
    Manufacturer/Model
    Scratch Build
    CPU
    AMD Ryzen 7 Processor
    Motherboard
    ACUSTeK, TUF Gaming XS70-PLUS
    Memory
    16
    Graphics Card(s)
    NVIDIA GeForce GTX 1660 Ti
    Sound Card
    NVIDIA High Definition Audio
    Monitor(s) Displays
    BenQ
There were a few problems with your XML configuration at the top of the script.

  • In the AllowedApps element at the top, you had some of the App elements with an attribute of ExecutableName. This attribute should be named AppUserModelId, like the App elements in my example.
  • For classic Windows apps (Chrome, Microsoft Office, etc.), you don't put !App at the end of the path.
  • After the very last item in the pinned Start menu items list, you had a comma. You don't need a comma after the last item.

Oh, one other thing. Not sure it matters, but when I paste the code/script into PowerShell ISE, the run button remains greyed out. I have to hit enter on the keyboard to get any script to run.

Sounds like you are pasting the code into the blue PowerShell console at the bottom of the ISE, rather than opening the file I posted and you modified. I had said, "Open the file I posted, make adjustments to the user account name and the programs list, and then hit the Play button in the toolbar to run it."

Also, in the Microsoft article I linked in #18, it says to open PowerShell using PSExec. You would have to open PowerShell ISE the same way. It sounds like you're not doing that, given the errors you posted. The command for that would be powershell_ise.exe, rather than powershell.exe.



Not trying to be a jerk here, but with all of the above stuff, plus the introduction of "Set-AssignedAccessConfiguration," which ChatGPT didn't say, at least in what you posted here, it sounds like directions are not being followed. I don't say that to be mean, but it's very important that directions are followed with this stuff. The XML has to comply with the expected format, and Microsoft's and my instructions have to be followed. If you're not sure about something, just ask.
 

My Computers

System One System Two

  • OS
    Windows 11 Pro 23H2 [rev. 3447]
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC12WSHi7
    CPU
    12th Gen Intel Core i7-1260P, 2100 MHz
    Motherboard
    NUC12WSBi7
    Memory
    64 GB
    Graphics Card(s)
    Intel Iris Xe
    Sound Card
    built-in Realtek HD audio
    Monitor(s) Displays
    Dell U3219Q
    Screen Resolution
    3840x2160 @ 60Hz
    Hard Drives
    Samsung SSD 990 PRO 1TB
    Keyboard
    CODE 104-Key Mechanical Keyboard with Cherry MX Clears
  • Operating System
    Linux Mint 21.2 (Cinnamon)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC8i5BEH
    CPU
    Intel Core i5-8259U CPU @ 2.30GHz
    Memory
    32 GB
    Graphics card(s)
    Iris Plus 655
    Keyboard
    CODE 104-Key Mechanical Keyboard - Cherry MX Clear
Understand. Let me try again and let you know.....
 

My Computer

System One

  • OS
    Windows 11
    Computer type
    PC/Desktop
    Manufacturer/Model
    Scratch Build
    CPU
    AMD Ryzen 7 Processor
    Motherboard
    ACUSTeK, TUF Gaming XS70-PLUS
    Memory
    16
    Graphics Card(s)
    NVIDIA GeForce GTX 1660 Ti
    Sound Card
    NVIDIA High Definition Audio
    Monitor(s) Displays
    BenQ

pseymour,​

Thanks for your effort on this thread! I have decided to no longer pursue implementation of Assigned Access. Thank you.
 

My Computer

System One

  • OS
    Windows 11
    Computer type
    PC/Desktop
    Manufacturer/Model
    Scratch Build
    CPU
    AMD Ryzen 7 Processor
    Motherboard
    ACUSTeK, TUF Gaming XS70-PLUS
    Memory
    16
    Graphics Card(s)
    NVIDIA GeForce GTX 1660 Ti
    Sound Card
    NVIDIA High Definition Audio
    Monitor(s) Displays
    BenQ
Understandable. It’s not exactly user friendly. I’m empathetic to your situation; I hope you find something that works for you.
 

My Computers

System One System Two

  • OS
    Windows 11 Pro 23H2 [rev. 3447]
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC12WSHi7
    CPU
    12th Gen Intel Core i7-1260P, 2100 MHz
    Motherboard
    NUC12WSBi7
    Memory
    64 GB
    Graphics Card(s)
    Intel Iris Xe
    Sound Card
    built-in Realtek HD audio
    Monitor(s) Displays
    Dell U3219Q
    Screen Resolution
    3840x2160 @ 60Hz
    Hard Drives
    Samsung SSD 990 PRO 1TB
    Keyboard
    CODE 104-Key Mechanical Keyboard with Cherry MX Clears
  • Operating System
    Linux Mint 21.2 (Cinnamon)
    Computer type
    PC/Desktop
    Manufacturer/Model
    Intel NUC8i5BEH
    CPU
    Intel Core i5-8259U CPU @ 2.30GHz
    Memory
    32 GB
    Graphics card(s)
    Iris Plus 655
    Keyboard
    CODE 104-Key Mechanical Keyboard - Cherry MX Clear

Latest Support Threads

Back
Top Bottom