Does it work if you hard code a full path for CreateShortcut? –Andy Arismendi Jul 17 '13 at 15:54 Thanks, that was the main problem. then what can i do to avoid this? If a user is writing a file then that user has to have write permissions to that location, plain and simple. 2007-2016 Why is my data not saved to my database? Either: Run the process elevated, or Save the shortcut in a location where you have write access. Source
And those who willingly leave it enabled. #12 Wilson Phillips Total Posts : 33 Scores: 0 Reward points : 0 Joined: 1/21/2009 Status: offline Re:help with creating a shortcut on Please try the request again. Are there textual deviations between the Dead Sea Scrolls and the Old Testament? Interlace strings Can I "build" a TDS project without having it attempt to deploy? https://www.autoitscript.com/forum/topic/44929-probably-a-simple-problem-vbs-to-create-shortcuts-based-on-username/
I can see how powerful VBscript would be (or whatever this is, i've never been big in programming), and I know some people that will sit down and just start hammering Why does typography ruin the user experience? Still not perfect, but it does work. #11 59cobalt Total Posts : 2547 Scores: 247 Reward points : 0 Joined: 7/17/2011 Status: offline Re:help with creating a shortcut on all
ok i solved problem i have to go to properties and window settings and change settings level to "requireAdministrator" Reply With Quote Quick Navigation Visual Basic .NET Top Site Areas Settings Dim objWSH, objFSO, link, desktopPath Set objWSH = WScript.CreateObject("WScript.Shell") Set objFSO = WScript.CreateObject("Scripting.FileSystemObject") desktopPath = objWSH.SpecialFolders("Desktop") 'if file exists define where the shortcut should point to If objFSO.FileExists("%SystemRoot%\System32\internet explorer\iexplore.exe") Then Edit: BTW, Group Policy Preferences would be a far more elegant way to handle this kind of task.
current community chat Stack Overflow Meta Stack Overflow your communities Sign up or log in to customize your list. SkyrimSE is Quiet A crossword so simple, it practically solves itself Why mention town and country of equipment manufacturer? Thank you! It appears that your user is not authorised to save a file to the public desktop. 2007-2016 Why is my data not saved to my database? | MSDN Data Walkthroughs MSDN
Seems it doesn't like it only when i use the "%username%" in slinkfile. http://stackoverflow.com/questions/20481055/saving-windows-shortcut-gives-me-an-error It makes administration more complex and thus more difficult. Unable To Save Shortcut 80070005 I suspect that it would make more sense for you to choose option 2 and save the shortcut under the user profile. Unable To Save Shortcut Powershell That's not what you asked though.
Your cache administrator is webmaster. this contact form What am i doing wrong? ERROR The requested URL could not be retrieved The following error was encountered while trying to retrieve the URL: http://0.0.0.9/ Connection to 0.0.0.9 failed. as u said "They either have to create a shortcut configured that way" some programs only start in administer rights so how to configure software to only start in administer rights Autoit
Then it was a simple matter to put the pieces together. I do not offer free assistance by e-mail. Can you write to that folder outside your VB app? 2007-2016 Why is my data not saved to my database? | MSDN Data Walkthroughs MSDN "How Do I?" Videos: VB | http://prcflow.com/unable-to/unable-to-connect-to-the-mks-902.html It doesn't increase security one bit.
To start viewing messages, select the forum that you want to visit from the selection below. Check it to make sure it has the folder path you're expecting. –Andy Arismendi Jul 17 '13 at 17:39 add a comment| active oldest votes Know someone who can answer? asked 3 years ago viewed 2167 times Blog Stack Overflow Podcast #93 - A Very Spolsky Halloween Special Related 12Editing shortcut (.lnk) properties with Powershell1360Determine installed PowerShell version793PowerShell says “execution of
It breaks workflows. UAC is enabled by default on new systems and it's a pain in the butt just to do a simple regedit to remove regkeys from within a script. I always disable this "feature" since it is not needed as long as you have decent group policies in place. #14 59cobalt Total Posts : 2547 Scores: 247 Reward points With a little digging, I found that I could edit the permissions of the folder and add the System User "Interactive" with Full Control, and this would allow me to paste
what is wrong with this code and how to make it work successfully. more stack exchange communities company blog Stack Exchange Inbox Reputation and Badges sign up log in tour help Tour Start here for a quick overview of the site Help Center Detailed The time now is 08:54 PM. Check This Out Join them; it only takes a minute: Sign up “Save” method Windows Powershell (windows 7) returns error up vote 1 down vote favorite 1 I am trying to learn how to
Instead it raises a false sense of security, while educating people to enter their password whenever something pops up a dialog. Reply With Quote 04-27-2007,12:57 AM #4 Phil Weber View Profile View Forum Posts Visit Homepage Senior Member Join Date Nov 2003 Location Portland, OR Posts 8,387 Well, I started out by Here's what I have:Set oWS = WScript.CreateObject("WScript.Shell") sLinkFile = "C:Documents and Settings%username%DesktopStartup.LNK" Set oLink = oWS.CreateShortcut(sLinkFile) oLink.TargetPath = "C:Documents and Settings%username%Start MenuProgramsStartup" oLink.Save I've put the above in a text file, powershell windows-7-x64 shortcuts share|improve this question edited Jul 17 '13 at 15:40 asked Jul 17 '13 at 14:13 dconner 63 I'm betting C:\Desktop doesn't exist.
thanks Dim objWSH, objFSO, link, desktopPath Set objWSH = WScript.CreateObject("WScript.Shell") Set objFSO = WScript.CreateObject("Scripting.FileSystemObject") desktopPath = "c:\users\public\desktop" 'if file exists define where the shortcut should point to If objFSO.FileExists("c:\Program Files\internet The difference between normal users and admins is that the latter have an additional security token, that can be activated via "run as administrator" and will then grant the user administrative Movie about encountering blue alien What is an instant of time? Here's what I have: Set oWS = WScript.CreateObject("WScript.Shell") sLinkFile = "C:\Documents and Settings\%username%\Desktop\Startup.LNK" Set oLink = oWS.CreateShortcut(sLinkFile) oLink.TargetPath = "C:\Documents and Settings\%username%\Start Menu\Programs\Startup\" oLink.Save I've put the above in a text
Reply With Quote Mar 21st, 2012,11:53 PM #2 jmcilhinney View Profile View Forum Posts Visit Homepage .NUT Join Date May 2005 Location Sydney, Australia Posts 93,673 Re: how to create shortcut how do i go about learning this? Sign in here. How should I deal with players who prefer "realistic" approaches to challenges?
Your Answer draft saved draft discarded Sign up or log in Sign up using Google Sign up using Facebook Sign up using Email and Password Post as a guest Name At least not on my little OU. #13 BoOkWoRm Total Posts : 43 Scores: 2 Reward points : 0 Joined: 8/13/2011 Status: offline Re:help with creating a shortcut on all See AlsoReferenceWshShortcut ObjectWshUrlShortcut ObjectNeed Help about VBScript? The reason why administrators can't write to that folder when UAC is enabled is that after logging in they have the same permissions as normal users (who don't have write access
It makes administration more complex and thus more difficult. Problems associated with booking flights inside another set of flights? Sign In Sign In Remember me Not recommended on shared computers Sign in anonymously Sign In Forgot your password? This package includes VbsEdit 32-bit, VbsEdit 64-bit, HtaEdit 32-bit and HtaEdit 64-bit.The evaluation version never expires.
hehehehe Cheers Old ScriptologyVisual Ping 1.8 - Mass Ping Program with export to txt delimited.Desktop 2 RGB and YMCK - Pick a color in the desktop and get the RGB and Interlace strings Why does WordPress use outdated jQuery v1.12.4? Register Lost Password? Are there textual deviations between the Dead Sea Scrolls and the Old Testament?