Little scripting help

I’m having a really hard time making a script which contains 4 functions which will automatically draw a box menu and change your TCP/IP settings from static to DHCP or vice versa.

Create a Set-DHCP function to enable DCHP on the local computer
Create a Set-StaticIP function to change from DHCP to static addressing.
Make sure to SetDynamicDNSRegistration to “false”.

If anyone can help, that will be greatly appreciated. THANKS

The menu should look like this below.

Which bit, exactly, are you having problems with?

Hello, You appear to have only attached an image.

Rocking the ASCII art menus! Takes us back to 1990…

These days, why bother with all the lines and blocks? If you want a GUI, there are much nicer options. Modern command-line scripts and utilities rarely go to the trouble of that sort of menu.

The PowerShell Host has a built-in PromptForChoice method which you might like. It’s what gets used when you set one of the action preference variable to ‘Confirm’, and so on. Check out for an example of it. (In PowerShell.exe, this will be a command-line prompt. In the ISE, it’s a GUI pop-up.)

Problems with all of the steps. I know, I’am an amateur to coding via Powershell but my strength is in Linux. I just started doing windows administration.

Dave that was and excellent source you provided me, only issue is I must use ASCII to create the menu.

This is the guideline I must follow.

I got a friend to help me out.