A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Add-ins for Outlook
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

problem with VISTA



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old October 29th 07, 03:48 PM posted to microsoft.public.outlook.program_addins
sd[_2_]
external usenet poster
 
Posts: 69
Default problem with VISTA

Hi All,
I have created one VSTo COM - addin for office 2007 in vb 2005. I have
seen that my code is not working if I access the hkey_Classes_Root or
hkey_local_machine through my code on windows VISTA. My code is
working fine on all OS except VISTA.
My code snippet for modifying HKEY_CLASSES_ROOT is as follows -
------------------------------------------------------------------------------------------------
Dim rk As Microsoft.Win32.RegistryKey
rk = Microsoft.Win32.Registry.ClassesRoot
With rk
.CreateSubKey(".asi",
Microsoft.Win32.RegistryKeyPermissionCheck.ReadWri teSubTree)
-------------- Error starting from this line
.OpenSubKey(".asi", True).SetValue("", "ASI.Document",
Microsoft.Win32.RegistryValueKind.String)
.CreateSubKey("ASI.Document\shell\open\command")
End With

------------------------------------------------------------------------------------------------
My user account is Administrator.
Also my trace file (trace.txt) is not generated if my addin's
directory is under "program files". If my addin's directory is not in
"Program files", then it is working fine!


Thanks,
Dhananjay

Ads
  #2  
Old December 6th 07, 09:45 PM posted to microsoft.public.outlook.program_addins
Vaelek
external usenet poster
 
Posts: 6
Default problem with VISTA

Whether your account is administrator does not make you "Administrator" in
Vista's eyes. I've run into a number of permissions issues when working with
both the registry or modifying anything under \Program Files. I think you
need to elevate the priviledges in your code to get true Admin level rights.
Though I am not sure how to go about that.

"sd" wrote:

Hi All,
I have created one VSTo COM - addin for office 2007 in vb 2005. I have
seen that my code is not working if I access the hkey_Classes_Root or
hkey_local_machine through my code on windows VISTA. My code is
working fine on all OS except VISTA.
My code snippet for modifying HKEY_CLASSES_ROOT is as follows -
------------------------------------------------------------------------------------------------
Dim rk As Microsoft.Win32.RegistryKey
rk = Microsoft.Win32.Registry.ClassesRoot
With rk
.CreateSubKey(".asi",
Microsoft.Win32.RegistryKeyPermissionCheck.ReadWri teSubTree)
-------------- Error starting from this line
.OpenSubKey(".asi", True).SetValue("", "ASI.Document",
Microsoft.Win32.RegistryValueKind.String)
.CreateSubKey("ASI.Document\shell\open\command")
End With

------------------------------------------------------------------------------------------------
My user account is Administrator.
Also my trace file (trace.txt) is not generated if my addin's
directory is under "program files". If my addin's directory is not in
"Program files", then it is working fine!


Thanks,
Dhananjay


 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
problem with VISTA sd[_2_] Outlook and VBA 0 October 29th 07 03:47 PM
Problem create mail with Vista [email protected] Outlook and VBA 3 June 29th 07 08:50 PM
sending problem after upgrade to Vista [email protected] Outlook - General Queries 3 March 10th 07 11:51 AM
POP Problem with Outlook 2003 & Vista stringshome Outlook - General Queries 2 March 6th 07 11:20 PM
Vista/Outlook problem Jerome Phillips Outlook Express 2 February 9th 07 02:59 AM


All times are GMT +1. The time now is 10:21 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.