VideoHelp Forum
+ Reply to Thread
Results 1 to 5 of 5
Thread
  1. Hi, I'm a cat

    but I wonder if is there a way - via commandline - to check if the current user have all administrator privileges. I need to change the state of a variable so that if yes --> become 1, if no --> become or stay to Zero.

    And is it possible to automatically change via commandline the windows 10 settings so that the current user assumes all administrative privileges? thanks
    Quote Quote  
  2. and possibly I need to set windows so that when I run one program, or a batch, by default it have to "run as administrator". I cannot understand why, because I'am already administrator but to run as administrator I alwais clic the right button as manually select "run as administrator". Is there a way to set windows so that it runs as administrator alwais, and anything? thanks
    Quote Quote  
  3. Member
    Join Date
    Mar 2008
    Location
    United States
    Search Comp PM
    Perhaps by disabling UAC you'll get the functionality you want. Windows, by default, has not behaved that way since XP
    Quote Quote  
  4. Image
    [Attachment 46222 - Click to enlarge]


    problem solved cat

    this check if or not

    Code:
    @echo off
    goto check_Permissions
    
    :check_Permissions
        echo Administrative permissions required. Detecting permissions...
    
        net session >nul 2>&1
        if %errorLevel% == 0 (
            echo Success: Administrative permissions confirmed.
        ) else (
            echo Failure: Current permissions inadequate.
        )
    
        pause >nul
    and in secpol.msc some settings of user account control to modify and all the elevated privileges are ok

    thanks
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!