Can Someone Help me Write a Script

Discus and support Can Someone Help me Write a Script in Windows 10 Support to solve the problem; I use an old kvm switch without active ddc so I am always having to open screen resolution settings and click detect. I would like to make a script... Discussion in 'Windows 10 Support' started by lgentry, Jul 13, 2015.

  1. lgentry Win User

    Can Someone Help me Write a Script


    I use an old kvm switch without active ddc so I am always having to open screen resolution settings and click detect.
    I would like to make a script file and then a shortcut to the file to do this for me but I have never written a script and can't figure out how to do it. Also, do I need to have a program in order for the script file to work. Can one of you tell me how I might accomplish this. Thanks

    :)
     
    lgentry, Jul 13, 2015
    #1
  2. ogun228 Win User

    Can someone help me write a small batch file?

    YESSS! It worked once I corrected syntactical errors. You are THE MAN. Thank yo very much.

    I also had a chance to revisit my old DOS skills, killed by GUI.

    J-D
     
    ogun228, Jul 13, 2015
    #2
  3. A_User_Here Win User
    Can someone help me write a small batch file?

    Did the command icacls give you errors that say you don't have permissions?

    If that is the case you can try it in an Administrator command window.

    Select: Win Key + X -> Command Prompt (admin)

    To get to the right folder use the cd command

    For instance: cd C:\

    That takes you to the top folder/directory.

    From there you can cd (change directory) down one directory at a time. If you type: cd (and the a few characters of the right directory name and then <Tab Key> it will fill in the name).

    You can also use the dir command to get a listing of the current directory type: dir<Enter Key>
     
    A_User_Here, Jul 13, 2015
    #3
  4. MilesAhead Win User

    Can Someone Help me Write a Script

    DonationCoder.com has a sub-forum dedicated to just these small requests called Coding Snacks. You may submit your request here:
    Post New Requests Here - DonationCoder.com

    Please read the rules before posting. But the type of thing you are talking about should be quite easy. Also you may wish to read about DonationCoder here:
    DonationCoder.com

    Donations are encouraged but voluntary. If you have any questions about signing up or using the site contact Mouser.
     
    MilesAhead, Jul 13, 2015
    #4
  5. NUS
    Nus Win User
    If you don't know how to program then it would probably be to complicated to do that for your first script.

    Check you have Windows Powershell installed, it should be listed on the Start menu, and I'll see if I can knock something up for you.
     
  6. lgentry Win User
    Yes, I have powershell. I REALLY appreciate your time and effort.
     
    lgentry, Jul 14, 2015
    #6
  7. NUS
    Nus Win User
    As I can't replicate the same issue you've got this may need tweaking for your system, so report back.

    Rather than open the Control Panel Display properties and clicking detect, this uses the Windows API to detect display devices.

    There's a powershell script with the code and a batch file to run the script without having to change your system execution policies. You can place these files wherever you want but you will have to edit the .bat file and put in a new location. As it is, I've set it to run from C:\Program Files\Detect. So create this folder and put the two files in it. You can then create a shortcut to the .bat file on your Desktop.

    Detect.zip
     
  8. lgentry Win User

    Can Someone Help me Write a Script

    Nus, this did not work for me but DonationCoder told me that a simple shortcut with the following as target
    will "detect display" Hope someone else finds this and it is beneficial. Thank you so much for your time and effort., I don't know what I would do without all the help I receive from gurus such as yourself. I am really amazing how many people across the web give of themselves to assist strangers. Good will is alive and well in the computing world.

    %SystemRoot%\system32\WindowsPowerShell\v1.0\powershell.exe -noprofile -executionpolicy bypass -Command "Get-CimInstance -Namespace root\wmi -ClassName WmiMonitorBasicDisplayParams | Out-Null"

    edit 7/23/15 I forgot to add that this shortcut must be "run as administrator"
     
    lgentry, Jul 18, 2015
    #8
  9. Ztruker Win User
    What does it do for you? I ran it just for kicks and it took 5 seconds or so then exited but I could not detect anything happening, probably because my resolution was already correct.
     
    Ztruker, Jul 19, 2015
    #9
  10. NUS
    Nus Win User
    No, worries, that looks like a simpler method, heh.

    I've got a script to set resolution, colour depth and refresh rate, so say if you need that.
     
Thema:

Can Someone Help me Write a Script

Loading...
  1. Can Someone Help me Write a Script - Similar Threads - Someone Help Write

  2. can not get icons to pin to taskbar

    in Windows 10 Customization
    can not get icons to pin to taskbar: updated google chrome, windows 10. Taskbar icons no longer work new ones will not pin https://answers.microsoft.com/en-us/windows/forum/windows_10-start-win_taskbar/can-not-get-icons-to-pin-to-taskbar/29941795-5ede-44e3-9e36-c2f1e18cea04
  3. Last Update Screwed Me

    in Windows 10 Drivers and Hardware
    Last Update Screwed Me: I noticed this right after I suddenly had Microsoft Edge, which I do not use and don't want, by the way. I have no key functions for the following keys: backspace, right enter, and forward slash. Additionally, when I checked in Device Manager which online helps instructed me...
  4. Operating System failure help needed

    in Windows 10 Support
    Operating System failure help needed: Greetings, Earlier today I was watching amazon and google chrome sent me back to the previous page continuously until I got back to new tab. This happens everytime I open something in google chrome, spotify, microsoft edge, or even steam. A few seconds after opening anything...
  5. Can i use OS Windows 10 without license for free?

    in Windows 10 Installation and Upgrade
    Can i use OS Windows 10 without license for free?: i need a windows 10 just for printer, and typing for work https://answers.microsoft.com/en-us/windows/forum/windows_10-windows_install/can-i-use-os-windows-10-without-license-for-free/acd33008-05cd-4164-8e5e-af4b67010588
  6. Updgrade from Windows Vista to Windows 10 help needed

    in Windows 10 Installation and Upgrade
    Updgrade from Windows Vista to Windows 10 help needed: I am upgrading from Windows Vista to Windows 10. I have purchased a full retail version of Windows 10. My computer, although old, has been upgraded and has all the correct specs to run the operating system, including a 250gb SSD. My system is 32-bit. I know I have to do a...
  7. can i use the windows 10 product key from my now dead pc on my new pc

    in Windows 10 Installation and Upgrade
    can i use the windows 10 product key from my now dead pc on my new pc: my laptop with windows 10 home crashed so I went and bought a new one on 13 Aug 2018. I found out the windows 10 home version on the new laptop is a "single language version". Can I upgrade to a normal Home version or use the product key from my other laptop which crashed to...
  8. Why won't Chrome open for me?

    in Windows 10 Network and Sharing
    Why won't Chrome open for me?: All of a sudden this afternoon Chrome will not open for me. I need to save all the bookmarks since I use my home computer for my job. Is this a known problem? What do I do? I've used Chrome on this computer for several years with no problem....
  9. Windows 10 failing to update from the 1703 version. What can I do?

    in Windows 10 Installation and Upgrade
    Windows 10 failing to update from the 1703 version. What can I do?: Windows 10 just doesn't seem to update from the 1703 version to a newer one. It started about a month ago; the update would start normally, but it'd eventually fail after reaching a certain percentage of completion. It'd then reboot back to the previous version. But then one...
  10. Word 2007 Can No-Longer open .DOCM files after upgrade to Windows 10

    in Windows 10 Support
    Word 2007 Can No-Longer open .DOCM files after upgrade to Windows 10: Today, I upgraded a Windows 8 system to Windows 10 Home. All seemed to work well. NOW however, Word 2007 cannot open a .DOCM file that has an embedded Excel spreadsheet object (.XLS). I've never seen such a thing before and I'm lost. There's a bunch of chatter about Security...