-
Nov 9th, 2018, 02:06 AM
#1
Thread Starter
New Member
unable to run msconfig.exe
Hello,
I use Windows 10 64 Bits with Visual Studio Community 2017, i wish to create a button to run msconfig.
I tried with Process.Start() shell() ; nothing works i have the following error message :
System.IO.FileNotFoundException*: 'File not found.'
The app use and admin account and i checked the file msconfig.exe exists.
Any idea ?
Thank you so much for your help!
-
Nov 9th, 2018, 03:26 AM
#2
Re: unable to run msconfig.exe
If it didn't work then you did it wrong. If you don't show us what you did then we can't tell you what's wrong with it. Don't provide vague descriptions of what you did. Show us the actual code.
-
Nov 9th, 2018, 03:35 AM
#3
Re: unable to run msconfig.exe
Hmmm... just tested this:
vb.net Code:
Process.Start("C:\Windows\System32\msconfig.exe")
so with fully-qualified path, and also running the project EXE as an administrator and I still got the same error message. I suspect that it's got to do with virtualisation, where apps are given their own virtual version of various system locations in the file system and Registry in order to protect the system from rogue and malicious users or apps. I'm not sure of all the details so I don't know whether there's even a way around it but that might provide an avenue for investigation.
-
Nov 9th, 2018, 05:31 AM
#4
Thread Starter
New Member
Re: unable to run msconfig.exe
i think it is related to WIN32 application not ?
So no way to run msconfig in VB.Net ?
-
Nov 9th, 2018, 05:58 AM
#5
Re: unable to run msconfig.exe
Originally Posted by jmcilhinney
Hmmm... just tested this:
vb.net Code:
Process.Start("C:\Windows\System32\msconfig.exe")
so with fully-qualified path, and also running the project EXE as an administrator and I still got the same error message. I suspect that it's got to do with virtualisation, where apps are given their own virtual version of various system locations in the file system and Registry in order to protect the system from rogue and malicious users or apps. I'm not sure of all the details so I don't know whether there's even a way around it but that might provide an avenue for investigation.
I just tried the above on WIN7 64 bit (not as Admin), and it worked with no problem, seems to be Win 10 related
to hunt a species to extinction is not logical !
since 2010 the number of Tigers are rising again in 2016 - 3900 were counted. with Baby Callas it's 3901, my wife and I had 2-3 months the privilege of raising a Baby Tiger.
-
Nov 9th, 2018, 05:59 AM
#6
Thread Starter
New Member
Re: unable to run msconfig.exe
Thank's for the trie.
Any idea to make that compatible with Win7 to 10 ?
-
Nov 9th, 2018, 06:01 AM
#7
Thread Starter
New Member
Re: unable to run msconfig.exe
Thank's for the attempt.
Any idea to make that compatible with Win7 to 10 ?
-
Nov 9th, 2018, 06:06 AM
#8
Addicted Member
Re: unable to run msconfig.exe
I just tried manually on WIN10 64 bit without success
-
Nov 9th, 2018, 06:10 AM
#9
Re: unable to run msconfig.exe
Try making use of the SysNative alias of System32, eg:
Code:
Dim msConfig as String = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.Windows), "sysnative", "msconfig.exe")
Process.Start(msConfig)
-
Nov 9th, 2018, 06:13 AM
#10
Re: unable to run msconfig.exe
Hi,
see if this works..
Code:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
'Process.Start("C:\Windows\System32\msconfig.exe")
Dim startInfo As ProcessStartInfo = New ProcessStartInfo("C:\Windows\System32\msconfig.exe")
startInfo.WindowStyle = ProcessWindowStyle.Normal
Process.Start(startInfo)
End Sub
to hunt a species to extinction is not logical !
since 2010 the number of Tigers are rising again in 2016 - 3900 were counted. with Baby Callas it's 3901, my wife and I had 2-3 months the privilege of raising a Baby Tiger.
-
Nov 9th, 2018, 06:17 AM
#11
Thread Starter
New Member
Re: unable to run msconfig.exe
same issue
-
Nov 9th, 2018, 06:30 AM
#12
Re: unable to run msconfig.exe
Running the project exe (in the bin > debug folder) as administrator worked for me on Windows 10:
Code:
Process.Start("C:\Windows\Sysnative\msconfig.exe")
-
Nov 9th, 2018, 06:35 AM
#13
Thread Starter
New Member
Re: unable to run msconfig.exe
Thank you so much @Paul4ije; it works!
-
Nov 9th, 2018, 06:37 AM
#14
Re: unable to run msconfig.exe
that is strange, Si's code in Post#9 didn't work
Win10 is one strange OS
to hunt a species to extinction is not logical !
since 2010 the number of Tigers are rising again in 2016 - 3900 were counted. with Baby Callas it's 3901, my wife and I had 2-3 months the privilege of raising a Baby Tiger.
-
Nov 9th, 2018, 06:39 AM
#15
Thread Starter
New Member
Re: unable to run msconfig.exe
-
Nov 9th, 2018, 06:44 AM
#16
Re: unable to run msconfig.exe
Originally Posted by ChrisE
that is strange, Si's code in Post#9 didn't work
Win10 is one strange OS
paulg4ije made a small but very important change to it, which was to run it as Admin... given that msconfig is an admin program, it isn't particularly surprising that it requires admin rights.
Note however that detecting the path of Windows as I did is a wise move, as it isn't guaranteed to always be C:\Windows
-
Nov 9th, 2018, 06:55 AM
#17
Re: unable to run msconfig.exe
Originally Posted by si_the_geek
paulg4ije made a small but very important change to it, which was to run it as Admin... given that msconfig is an admin program, it isn't particularly surprising that it requires admin rights.
Note however that detecting the path of Windows as I did is a wise move, as it isn't guaranteed to always be C:\Windows
I see, thanks for the detail Information
to hunt a species to extinction is not logical !
since 2010 the number of Tigers are rising again in 2016 - 3900 were counted. with Baby Callas it's 3901, my wife and I had 2-3 months the privilege of raising a Baby Tiger.
-
Nov 9th, 2018, 06:56 AM
#18
Thread Starter
New Member
Re: unable to run msconfig.exe
-
Nov 9th, 2018, 08:04 AM
#19
Re: unable to run msconfig.exe
It's interesting that that worked for you guys. I suspected that it would and I tested it myself but it still didn't work for me. Not sure why.
-
Nov 9th, 2018, 10:45 AM
#20
Addicted Member
Re: unable to run msconfig.exe
it still didn't work for me too
-
Nov 9th, 2018, 10:55 AM
#21
Addicted Member
Re: unable to run msconfig.exe
Hi keanny479,
You're suffering from the "File System Redirector", which is explained here.
Just change your build configuration target from x86 to Any CPU and you're good to go.
Hope that helps.
-
Nov 9th, 2018, 11:51 AM
#22
Re: unable to run msconfig.exe
Originally Posted by cPubis
Hi keanny479,
You're suffering from the " File System Redirector", which is explained here.
Just change your build configuration target from x86 to Any CPU and you're good to go.
Hope that helps.
hope someone will try this with Win10 and report back
to hunt a species to extinction is not logical !
since 2010 the number of Tigers are rising again in 2016 - 3900 were counted. with Baby Callas it's 3901, my wife and I had 2-3 months the privilege of raising a Baby Tiger.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|