Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Calling Norway
Message
 
To
17/11/2009 16:30:19
Al Doman (Online)
M3 Enterprises Inc.
North Vancouver, British Columbia, Canada
General information
Forum:
ASP.NET
Category:
Other
Title:
Miscellaneous
Thread ID:
01432969
Message ID:
01435305
Views:
32
>>>I am addressing this post directly to Norwegian developers, but writing in english so others can read it (and it just takes a lot longer to write in norwegian).
>>>
>>>I have posted about this issue in the past but had no replies.
>>>
>>>I first encountered this exception on a norwegian pc running Windows with Norwegian language package.
>>>
>>>The exception is in Norwegian:
>>>Noen eller all identitetsreferanser kan ikke oversettes.
>>>
>>>But I have also seen the exception in english (I think on a danish PC and/or french PC)
>>>Some or all identity references could not be translated.
>>>
>>>I am not sure where this beeing thrown from and I can't reproduce it on my computer. My app only seem to throw this exception on computers with French, Norwegian or Danish language package for Windows.
>>>
>>>Any help on this would be great.
>>>
>>>You can reply in norwegian if you want to.
>>>
>>>Thanks,
>>>Einar
>>
>>I finnaly got a hold of a Swedish laptop where I could generate the exception. The following code throws the exception mentioned above:
>>
>>        public static void AddFolderAccess(string path, string identity)
>>        {
>>            DirectorySecurity directorySecurity = Directory.GetAccessControl(path);
>>            FileSystemAccessRule fileSystemAccessRule = new FileSystemAccessRule
>>                (identity
>>                , FileSystemRights.Modify
>>                , InheritanceFlags.ContainerInherit | InheritanceFlags.ObjectInherit
>>                , PropagationFlags.None
>>                , AccessControlType.Allow);
>>
>>            directorySecurity.AddAccessRule(fileSystemAccessRule);
>>            Directory.SetAccessControl(path, directorySecurity);
>>        }
>>
>>
>>If anyone (not only norwegian developers) can help me shed some light on this that would be great.
>
>Warning: I know very little .Net/C#, but here's a SWAG. You're not showing the namespaces you're using. Can you try fully qualifying the class names in your code, rather than relying on the namespaces?
>
>My other, even SWAGgier thought was if somehow, something in your code was a reserved word or some such.

I don't think it is a problem with the code per say (it compiles). The code runs just fine on all computers running US Windows and on most non-US versions of Windows.

DirectorySecurity is part of the System.Security.AccessControl namespace
Directory is part of the System.IO namespace
Semper ubi sub ubi.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform