Create shortcut error

Hi, if I run the wyUpdate as a standard user the wyUpdate will fail and give "Access is denied" error. This happened when wyUpdate creates the shortcut under commdesktop folder. But If I run as administrator, everything is ok. Why?

IPersistFile pf = (IPersistFile)m_Link; pf.Save(m_sPath, true);

it fails on the second line "pf.Save(m_sPath, true". m_sPath = "C:\Users\Public\Desktop\New Command Update Test.lnk"

Thanks,

Don't modify wyUpdate, and don't use the "/fromservice" switch if you're not actually running wyUpdate from a service. That switch is not magical. It won't let you bypass the security in Windows. It would be a greater concern if we could do that.

Let it run as admin so it can properly create shortcuts in areas that need admin permission (like Common Desktop).

After I added codes to let the app running as administrator the problem was fixed. Thanks for your help!

Wyatt wrote:> Don't modify wyUpdate, and don't use the "/fromservice" switch if> you're not actually running wyUpdate from a service. That switch is not> magical. It won't let you bypass the security in Windows. It would be a> greater concern if we could do that.> > Let it run as admin so it can properly create shortcuts in areas that need> admin permission (like Common Desktop).