Showing posts with label groups. Show all posts
Showing posts with label groups. Show all posts

Tuesday, March 27, 2012

customized grouping

I have a tabular report with several groupings.
I want to customize one of the groups.
For example I have a field called country. I want to group it by
region, western and eastern. How would I do this?where does the regional information come from? you need to provide us with
more info about your fields and their data.
"OogleGoogle" <Yvonhong@.gmail.com> wrote in message
news:1183576344.729726.5950@.i38g2000prf.googlegroups.com...
>I have a tabular report with several groupings.
> I want to customize one of the groups.
> For example I have a field called country. I want to group it by
> region, western and eastern. How would I do this?
>

Tuesday, March 20, 2012

Custom sort the dimension members

Hello users of SSAS2005!

I am in the funny position of developing a cube for (at least) three different user groups, and each need "their" special treatment. My problem is in sort order of one particular dimension. The dimension has 3 fields: ID (=person number), Firstname and Lastname - as simple as straightforward as it can be.

Now Finance wants it sorted by ID to relate it to their documents. Human resources needs it by last name, so it can be copy-pasted directly into their structures.

It gets really hilarious when IT needs it sorted by first name (not joking here) because an external application delivers correlating date sorted by first name (again, I am not making that up).

Since I cannot convience anyone onto one common sort I need to make all three possible sort orders available, and I might end up with having 3 identical dimensions or one dimension with 3 identical attributes (except for sorting)

We use Excel as our frontend, I know I can sort a cube there as well. This is, of course, if the field to base the sorting upon is dragged onto the same axis, but that is a bit clumsy too.

What is the "best practices" approach to such a funny situation? (Except for changing the company workflow, let's take that as ... sigh ... static.)

Hello Ralf! I am not sure that this is possible in SSAS/MDX.

One way to solve this is to make the SSAS 2005 reports in Reporting Services 2005.

Check Books On Line for dynamic sorting in reporting services. It is also possible to sort with parameters.

If you can only use Excel pivot tables you can make three different reports, each sorted according to each groups preference.

Publish them i Sharepoint(or any other portal).

HTH

Thomas Ivarsson

HTH

Thomas Ivarsson

Custom Security: How do you manage groups

Dear Anyone,

We are trying to create our own custom security extension for rs2005. We are wondering how will then security extension will manage the authenticated users and how will it be mapped to an existing RS2005 group or role?

Thanks,

Joseph

It completely depends on how you write the extension itself.

I'd recommend that you use the forms auth extension as a start: C:\Program Files\Microsoft SQL Server\90\Samples\Reporting Services\Extension Samples\FormsAuthentication Sample

Change the parts of it that handle authentication, and then leave the parts alone which do authorization for you.

If you go this route, you will continue to use all the same roles you did before: Browser, Content Manager, etc.

|||

How would this dovetail with using Custom roles within the custom authentication database?

I've already implemented a version of the custom authentication extension and have the basic SSRS Forms auth working.

For example, users of my application log in with a companycode and would be put into one or many custom application roles that would ostensibly control the visibility of various folders and reports (you can imagine the various scenarios). Would I have to intercept the ASP.NET authentication pipeline and insert a custom Principal/Identity into the HTTP context? Would SSRS use the "User.IsInRole" construct to determine if the user is in a role that can "see" the restricted SSRS objects?

Just in case I confused anyone...I want to be able to add application-domain roles to the SSRS built-in (and possibly custom) roles and use those to restrict visibility to the SSRS objects.

Thanks,

Matthew Belk

|||Did you ever find an answer to this question? We're wanting to do the same thing (use roles from our custom application DB).|||

You can do this by assigning security within RS using the role names (just like windows groups). To get this to work though you will need to:

1. make your implementation of IAuthenticationExtension.IsValidPrincipalName check against the roles in your custom database
2. Implement IAuthorisationExtension.CheckAccess and in there look up the roles the user belongs to and check the access based on the username and his roles.

A good sample of this is located at:

http://www.devx.com/dotnet/Article/26759 - Part 1
http://www.devx.com/dotnet/Article/27133 - Part 2

Incidentally, I would like to take this further by using the Membership and Role Management Application Services of ASP.NET 2.0 to manage my users and roles.

So far I've been able to get the Forms Authentication working and I've set up the Membership and Role Management features, but when I try to use the 2 together i.e. make my logon.aspx page call Membership.ValidateUser the report server stops working and returns:

An internal error occurred on the report server. See the error log for more details. (rsInternalError) Get Online Help

Object reference not set to an instance of an object.

Custom Security: How do you manage groups

Dear Anyone,

We are trying to create our own custom security extension for rs2005. We are wondering how will then security extension will manage the authenticated users and how will it be mapped to an existing RS2005 group or role?

Thanks,

Joseph

It completely depends on how you write the extension itself.

I'd recommend that you use the forms auth extension as a start: C:\Program Files\Microsoft SQL Server\90\Samples\Reporting Services\Extension Samples\FormsAuthentication Sample

Change the parts of it that handle authentication, and then leave the parts alone which do authorization for you.

If you go this route, you will continue to use all the same roles you did before: Browser, Content Manager, etc.

|||

How would this dovetail with using Custom roles within the custom authentication database?

I've already implemented a version of the custom authentication extension and have the basic SSRS Forms auth working.

For example, users of my application log in with a companycode and would be put into one or many custom application roles that would ostensibly control the visibility of various folders and reports (you can imagine the various scenarios). Would I have to intercept the ASP.NET authentication pipeline and insert a custom Principal/Identity into the HTTP context? Would SSRS use the "User.IsInRole" construct to determine if the user is in a role that can "see" the restricted SSRS objects?

Just in case I confused anyone...I want to be able to add application-domain roles to the SSRS built-in (and possibly custom) roles and use those to restrict visibility to the SSRS objects.

Thanks,

Matthew Belk

|||Did you ever find an answer to this question? We're wanting to do the same thing (use roles from our custom application DB).|||

You can do this by assigning security within RS using the role names (just like windows groups). To get this to work though you will need to:

1. make your implementation of IAuthenticationExtension.IsValidPrincipalName check against the roles in your custom database
2. Implement IAuthorisationExtension.CheckAccess and in there look up the roles the user belongs to and check the access based on the username and his roles.

A good sample of this is located at:

http://www.devx.com/dotnet/Article/26759 - Part 1
http://www.devx.com/dotnet/Article/27133 - Part 2

Incidentally, I would like to take this further by using the Membership and Role Management Application Services of ASP.NET 2.0 to manage my users and roles.

So far I've been able to get the Forms Authentication working and I've set up the Membership and Role Management features, but when I try to use the 2 together i.e. make my logon.aspx page call Membership.ValidateUser the report server stops working and returns:

An internal error occurred on the report server. See the error log for more details. (rsInternalError) Get Online Help

Object reference not set to an instance of an object.sql

Custom Security: How do you manage groups

Dear Anyone,

We are trying to create our own custom security extension for rs2005. We are wondering how will then security extension will manage the authenticated users and how will it be mapped to an existing RS2005 group or role?

Thanks,

Joseph

It completely depends on how you write the extension itself.

I'd recommend that you use the forms auth extension as a start: C:\Program Files\Microsoft SQL Server\90\Samples\Reporting Services\Extension Samples\FormsAuthentication Sample

Change the parts of it that handle authentication, and then leave the parts alone which do authorization for you.

If you go this route, you will continue to use all the same roles you did before: Browser, Content Manager, etc.

|||

How would this dovetail with using Custom roles within the custom authentication database?

I've already implemented a version of the custom authentication extension and have the basic SSRS Forms auth working.

For example, users of my application log in with a companycode and would be put into one or many custom application roles that would ostensibly control the visibility of various folders and reports (you can imagine the various scenarios). Would I have to intercept the ASP.NET authentication pipeline and insert a custom Principal/Identity into the HTTP context? Would SSRS use the "User.IsInRole" construct to determine if the user is in a role that can "see" the restricted SSRS objects?

Just in case I confused anyone...I want to be able to add application-domain roles to the SSRS built-in (and possibly custom) roles and use those to restrict visibility to the SSRS objects.

Thanks,

Matthew Belk

|||Did you ever find an answer to this question? We're wanting to do the same thing (use roles from our custom application DB).|||

You can do this by assigning security within RS using the role names (just like windows groups). To get this to work though you will need to:

1. make your implementation of IAuthenticationExtension.IsValidPrincipalName check against the roles in your custom database
2. Implement IAuthorisationExtension.CheckAccess and in there look up the roles the user belongs to and check the access based on the username and his roles.

A good sample of this is located at:

http://www.devx.com/dotnet/Article/26759 - Part 1
http://www.devx.com/dotnet/Article/27133 - Part 2

Incidentally, I would like to take this further by using the Membership and Role Management Application Services of ASP.NET 2.0 to manage my users and roles.

So far I've been able to get the Forms Authentication working and I've set up the Membership and Role Management features, but when I try to use the 2 together i.e. make my logon.aspx page call Membership.ValidateUser the report server stops working and returns:

An internal error occurred on the report server. See the error log for more details. (rsInternalError) Get Online Help

Object reference not set to an instance of an object.

Sunday, March 11, 2012

Custom Page Break

There are 3 groups in my report– grp1, grp2 and grp3, with grp1 at the top, grp2 in the middle and grp3 at the bottom. I need to insert a page break when the value of grp1 record becomes “abc”. Is this possible? If so, I will really appreciate if someone can let me know how.

Thanks in advance,
Saurav

This is not possible with RS 2005. Condtional page breaks are on the wish list for the next release.

Thursday, March 8, 2012

Custom Groups

I'm wondering if there is any way in RS to create what Crystal reports calls Custom or Named Groups. This functionality allows you to define groups based on the values found in one of the fields on your report. For example, if I were grouping on a person's last name and I want 3 groups based on the first letter: A-G, H-P, Q-Z. I would want to keep it contained in one table.RS also has a concept of groups, and the construction of groups is very flexible. Groups are usedion DataRegion, such as Table, Matrix and Lists. Groups can be be grouped, filtered, sorted using multiple expressions. These expression can be just a field value, or they can be more complex.

In your case, you could create a group that uses an expression to return 1 if the value starts with A-G, return 2 if the value starts with H-P, and so on. The expression would look something like this, it assumes only upper case ASCII characters.

=Switch("ABCDEFGH".Contains(Fields!Name.Value.Substring(0,1)), 1, "IJKLMNOP".Contains(Fields!Name.Value.Substring(0,1)), 2, "QRSTUVWXYZ".Contains(Fields!Name.Value.Substring(0,1)), 3)

or

(use 64 since Choose uses the 1-based index into the array)

=Choose(Convert.ToInt32(Fields!Name.Value.Chars(0)) - 64, {1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3})

If you want something a little cleaner, then I would use a custom function that takes the first character as an argument and determines the appropriate value using regular control statements.|||

Thanks Ian!

Instead of editing the report, I decided to just add a field to my SQL statement to group on. It looks something like this:

select case
when left(lname,1) between 'a' and 'h' then 'A-H'
when left(lname,1) between 'i' and 'p' then 'I-P'
when left(lname,1) between 'q' and 'z' then 'Q-Z'
end as NameType from employee

I then created a group on the NameType field.

This worked great and my group headers were named properly as well.

|||I am trying something similar, but for some reason it does not like the syntax near AS. I see that it creates field called "NameType"...but does 'Employee' refer to the table the lname is coming from?|||Yes, the 'AS NameType' clause specifies the name for the result of the case statement, and 'lname' is a field in the 'Employee' table.

What is your query? Can you post it? I'm happy to take a look at it and see if there is something I can spot that would result in the syntax error.

Ian

Custom Groups

I'm wondering if there is any way in RS to create what Crystal reports calls Custom or Named Groups. This functionality allows you to define groups based on the values found in one of the fields on your report. For example, if I were grouping on a person's last name and I want 3 groups based on the first letter: A-G, H-P, Q-Z. I would want to keep it contained in one table.RS also has a concept of groups, and the construction of groups is very flexible. Groups are usedion DataRegion, such as Table, Matrix and Lists. Groups can be be grouped, filtered, sorted using multiple expressions. These expression can be just a field value, or they can be more complex.

In your case, you could create a group that uses an expression to return 1 if the value starts with A-G, return 2 if the value starts with H-P, and so on. The expression would look something like this, it assumes only upper case ASCII characters.

=Switch("ABCDEFGH".Contains(Fields!Name.Value.Substring(0,1)), 1, "IJKLMNOP".Contains(Fields!Name.Value.Substring(0,1)), 2, "QRSTUVWXYZ".Contains(Fields!Name.Value.Substring(0,1)), 3)

or

(use 64 since Choose uses the 1-based index into the array)

=Choose(Convert.ToInt32(Fields!Name.Value.Chars(0)) - 64, {1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3})

If you want something a little cleaner, then I would use a custom function that takes the first character as an argument and determines the appropriate value using regular control statements.|||

Thanks Ian!

Instead of editing the report, I decided to just add a field to my SQL statement to group on. It looks something like this:

select case
when left(lname,1) between 'a' and 'h' then 'A-H'
when left(lname,1) between 'i' and 'p' then 'I-P'
when left(lname,1) between 'q' and 'z' then 'Q-Z'
end as NameType from employee

I then created a group on the NameType field.

This worked great and my group headers were named properly as well.

|||I am trying something similar, but for some reason it does not like the syntax near AS. I see that it creates field called "NameType"...but does 'Employee' refer to the table the lname is coming from?|||Yes, the 'AS NameType' clause specifies the name for the result of the case statement, and 'lname' is a field in the 'Employee' table.

What is your query? Can you post it? I'm happy to take a look at it and see if there is something I can spot that would result in the syntax error.

Ian

Custom Grouping

My reqmt is to group records based on items purchased. I hv 2 groups cat1 ,cat2 with different set of items in them. My third group cat3 will contain customers who have purchased any items from cat1 AND cat2.

My formula is something like
if {table.itemnumber} in ['abc','def',..] then 'cat1:'
else
if {table.itemnumber} in ['xyz','lkm',...] then 'cat2:'
else
if ({table.itemnumber} in ['abc','def',...] AND {table.itemnumber} in ['xyz','lkm',...]) then 'cat3'

Am not able to get the cat3(3rd Group) on my report. Any thots on wat I cud b missing?

Am using Crystal Reports XII'd guess that your condition checks are in the wrong order.
You'll never get to the final if statement 'cos one of the previous two will always be true if the 3rd is true.|||Sorry if i have confused u. My reqmt is to get a count of all customers who buy items. Cat1 will have a set of items. Cat2 will have another set of items. My third group will contain items frm both cat1 and cat2. I sud basically get a count of customers in each cat.

I have grouped my report on items using the formula
if {table.itemnumber} in ['abc','def',..] then 'cat1:'
else
if {table.itemnumber} in ['xyz','lkm',...] then 'cat2:'
else
if ({table.itemnumber} in ['abc','def',...] AND {table.itemnumber} in ['xyz','lkm',...]) then 'cat3'

My report sud luk something like this :
Count(customer)
Cat1 xxxx
Cat2 xxxxx
Cat3 xxx(sud be the count of customers who hv bought frm cat1 and cat2)|||Assuming that your cat1 items and cat2 item lists are mutually exclusive then the 3rd if statement can never be true.
If there is an overlap (which I suspect there isn't, otherwise an item would be both a cat1 and cat2 item) then my previous comment is still true.

i.e. you will never get a cat3 with that formula.

Your main problem, however, is that you want to catagorise a customer, and your formula categorises an item.

Sunday, February 19, 2012

Custom Assembly Security Error

I have created a custom assembly that contains a function that uses
System.DirectoryServices to determine the user groups a user belongs to. It
works fine in development (preview) but returns the following error on the
report server:
"Request for the permission of type
System.Security.Permissions.SecurityPermission, mscorlib, Version=1.0.5000.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089 failed."
- I have another function in the same assembly that uses
System.Data.SQLClient to access a database and return values - this works
fine.
- I have included a codegroup for the assembly in rssrvpolicy.config with
the FullTrust permissionset.
- I have tried combinations of the following in the assemblyInfo.cs file:
[assembly: DirectoryServicesPermission(SecurityAction.RequestMinimum,
PermissionAccess=DirectoryServicesPermissionAccess.Browse)]
[assembly:
System.Security.Permissions.SecurityPermission(SecurityAction.RequestMinimum,
Unrestricted = true)]
[assembly: AllowPartiallyTrustedCallers]
- I have tried the following at the top of the function:
System.DirectoryServices.DirectoryServicesPermission pDir = new
DirectoryServicesPermission(System.Security.Permissions.PermissionState.Unrestricted);
System.DirectoryServices.DirectoryServicesPermissionEntry pDirEnt = new
DirectoryServicesPermissionEntry(System.DirectoryServices.DirectoryServicesPermissionAccess.Browse,"");
pDir.PermissionEntries.Add(pDirEnt);
pDir.Assert();
Please help!
I have been trying to solve this for ages and just cannot find a solution.
Regards,
Flon MackenzieHey, are you using 1.1 of the framework on the web server? If you do have it
installed, it doesn't look like it is installed for that virtual web.
I would like to suggest to first refresh the framwork installation on the
web server.
in %systemroot%\microsoft.net\framework\v1.1.4322\
installutil /i
The only reason I say that is because this number bugs me: "...mscorlib,
Version=1.0.5000.0, "
=-Chris
"Flon" <Flon@.discussions.microsoft.com> wrote in message
news:0725157A-2C8D-4CCE-B382-A6658FE98449@.microsoft.com...
>I have created a custom assembly that contains a function that uses
> System.DirectoryServices to determine the user groups a user belongs to.
> It
> works fine in development (preview) but returns the following error on the
> report server:
> "Request for the permission of type
> System.Security.Permissions.SecurityPermission, mscorlib,
> Version=1.0.5000.0,
> Culture=neutral, PublicKeyToken=b77a5c561934e089 failed."
> - I have another function in the same assembly that uses
> System.Data.SQLClient to access a database and return values - this works
> fine.
> - I have included a codegroup for the assembly in rssrvpolicy.config with
> the FullTrust permissionset.
> - I have tried combinations of the following in the assemblyInfo.cs file:
> [assembly: DirectoryServicesPermission(SecurityAction.RequestMinimum,
> PermissionAccess=DirectoryServicesPermissionAccess.Browse)]
> [assembly:
> System.Security.Permissions.SecurityPermission(SecurityAction.RequestMinimum,
> Unrestricted = true)]
> [assembly: AllowPartiallyTrustedCallers]
> - I have tried the following at the top of the function:
> System.DirectoryServices.DirectoryServicesPermission pDir = new
> DirectoryServicesPermission(System.Security.Permissions.PermissionState.Unrestricted);
> System.DirectoryServices.DirectoryServicesPermissionEntry pDirEnt = new
> DirectoryServicesPermissionEntry(System.DirectoryServices.DirectoryServicesPermissionAccess.Browse,"");
> pDir.PermissionEntries.Add(pDirEnt);
> pDir.Assert();
> Please help!
> I have been trying to solve this for ages and just cannot find a solution.
> Regards,
> Flon Mackenzie
>|||I just verified the version on my server with the 1.1 version of the
framework, and my version says:
1.1.4322.2251 for MSCORLIB.DLL.
=-Chris
"Christopher Conner" <someone@.someplace.com> wrote in message
news:On91kx3EFHA.3664@.TK2MSFTNGP15.phx.gbl...
> Hey, are you using 1.1 of the framework on the web server? If you do have
> it installed, it doesn't look like it is installed for that virtual web.
> I would like to suggest to first refresh the framwork installation on the
> web server.
> in %systemroot%\microsoft.net\framework\v1.1.4322\
> installutil /i
> The only reason I say that is because this number bugs me: "...mscorlib,
> Version=1.0.5000.0, "
> =-Chris
>
> "Flon" <Flon@.discussions.microsoft.com> wrote in message
> news:0725157A-2C8D-4CCE-B382-A6658FE98449@.microsoft.com...
>>I have created a custom assembly that contains a function that uses
>> System.DirectoryServices to determine the user groups a user belongs to.
>> It
>> works fine in development (preview) but returns the following error on
>> the
>> report server:
>> "Request for the permission of type
>> System.Security.Permissions.SecurityPermission, mscorlib,
>> Version=1.0.5000.0,
>> Culture=neutral, PublicKeyToken=b77a5c561934e089 failed."
>> - I have another function in the same assembly that uses
>> System.Data.SQLClient to access a database and return values - this works
>> fine.
>> - I have included a codegroup for the assembly in rssrvpolicy.config with
>> the FullTrust permissionset.
>> - I have tried combinations of the following in the assemblyInfo.cs file:
>> [assembly: DirectoryServicesPermission(SecurityAction.RequestMinimum,
>> PermissionAccess=DirectoryServicesPermissionAccess.Browse)]
>> [assembly:
>> System.Security.Permissions.SecurityPermission(SecurityAction.RequestMinimum,
>> Unrestricted = true)]
>> [assembly: AllowPartiallyTrustedCallers]
>> - I have tried the following at the top of the function:
>> System.DirectoryServices.DirectoryServicesPermission pDir = new
>> DirectoryServicesPermission(System.Security.Permissions.PermissionState.Unrestricted);
>> System.DirectoryServices.DirectoryServicesPermissionEntry pDirEnt = new
>> DirectoryServicesPermissionEntry(System.DirectoryServices.DirectoryServicesPermissionAccess.Browse,"");
>> pDir.PermissionEntries.Add(pDirEnt);
>> pDir.Assert();
>> Please help!
>> I have been trying to solve this for ages and just cannot find a
>> solution.
>> Regards,
>> Flon Mackenzie
>|||I meant aspnet_regiis /i not installutil /i DOH!
Sorry!
=-Chris
"Christopher Conner" <someone@.someplace.com> wrote in message
news:On91kx3EFHA.3664@.TK2MSFTNGP15.phx.gbl...
> Hey, are you using 1.1 of the framework on the web server? If you do have
> it installed, it doesn't look like it is installed for that virtual web.
> I would like to suggest to first refresh the framwork installation on the
> web server.
> in %systemroot%\microsoft.net\framework\v1.1.4322\
> installutil /i
> The only reason I say that is because this number bugs me: "...mscorlib,
> Version=1.0.5000.0, "
> =-Chris
>
> "Flon" <Flon@.discussions.microsoft.com> wrote in message
> news:0725157A-2C8D-4CCE-B382-A6658FE98449@.microsoft.com...
>>I have created a custom assembly that contains a function that uses
>> System.DirectoryServices to determine the user groups a user belongs to.
>> It
>> works fine in development (preview) but returns the following error on
>> the
>> report server:
>> "Request for the permission of type
>> System.Security.Permissions.SecurityPermission, mscorlib,
>> Version=1.0.5000.0,
>> Culture=neutral, PublicKeyToken=b77a5c561934e089 failed."
>> - I have another function in the same assembly that uses
>> System.Data.SQLClient to access a database and return values - this works
>> fine.
>> - I have included a codegroup for the assembly in rssrvpolicy.config with
>> the FullTrust permissionset.
>> - I have tried combinations of the following in the assemblyInfo.cs file:
>> [assembly: DirectoryServicesPermission(SecurityAction.RequestMinimum,
>> PermissionAccess=DirectoryServicesPermissionAccess.Browse)]
>> [assembly:
>> System.Security.Permissions.SecurityPermission(SecurityAction.RequestMinimum,
>> Unrestricted = true)]
>> [assembly: AllowPartiallyTrustedCallers]
>> - I have tried the following at the top of the function:
>> System.DirectoryServices.DirectoryServicesPermission pDir = new
>> DirectoryServicesPermission(System.Security.Permissions.PermissionState.Unrestricted);
>> System.DirectoryServices.DirectoryServicesPermissionEntry pDirEnt = new
>> DirectoryServicesPermissionEntry(System.DirectoryServices.DirectoryServicesPermissionAccess.Browse,"");
>> pDir.PermissionEntries.Add(pDirEnt);
>> pDir.Assert();
>> Please help!
>> I have been trying to solve this for ages and just cannot find a
>> solution.
>> Regards,
>> Flon Mackenzie
>|||Thanks for your suggestion.
I have no idea what the 1.0.5000.0 is for.
I have reinstalled .net framework 1.1 and my version of mscorlib.dll
is 1.1.4322.573.
Still no change.
I have also tried the following in my function:
System.Security.Permissions.SecurityPermission pSec = new
SecurityPermission(System.Security.Permissions.PermissionState.Unrestricted);
pSec.Assert();
System.DirectoryServices.DirectoryServicesPermission pDir = new
DirectoryServicesPermission(System.Security.Permissions.PermissionState.Unrestricted);
pDir.Assert();
which results in this error:
"Stack walk modifier must be reverted before another modification of the
same type can be performed."
"Christopher Conner" wrote:
> I meant aspnet_regiis /i not installutil /i DOH!
> Sorry!
> =-Chris
> "Christopher Conner" <someone@.someplace.com> wrote in message
> news:On91kx3EFHA.3664@.TK2MSFTNGP15.phx.gbl...
> > Hey, are you using 1.1 of the framework on the web server? If you do have
> > it installed, it doesn't look like it is installed for that virtual web.
> >
> > I would like to suggest to first refresh the framwork installation on the
> > web server.
> >
> > in %systemroot%\microsoft.net\framework\v1.1.4322\
> >
> > installutil /i
> >
> > The only reason I say that is because this number bugs me: "...mscorlib,
> > Version=1.0.5000.0, "
> >
> > =-Chris
> >
> >
> > "Flon" <Flon@.discussions.microsoft.com> wrote in message
> > news:0725157A-2C8D-4CCE-B382-A6658FE98449@.microsoft.com...
> >>I have created a custom assembly that contains a function that uses
> >> System.DirectoryServices to determine the user groups a user belongs to.
> >> It
> >> works fine in development (preview) but returns the following error on
> >> the
> >> report server:
> >>
> >> "Request for the permission of type
> >> System.Security.Permissions.SecurityPermission, mscorlib,
> >> Version=1.0.5000.0,
> >> Culture=neutral, PublicKeyToken=b77a5c561934e089 failed."
> >>
> >> - I have another function in the same assembly that uses
> >> System.Data.SQLClient to access a database and return values - this works
> >> fine.
> >>
> >> - I have included a codegroup for the assembly in rssrvpolicy.config with
> >> the FullTrust permissionset.
> >>
> >> - I have tried combinations of the following in the assemblyInfo.cs file:
> >> [assembly: DirectoryServicesPermission(SecurityAction.RequestMinimum,
> >> PermissionAccess=DirectoryServicesPermissionAccess.Browse)]
> >> [assembly:
> >> System.Security.Permissions.SecurityPermission(SecurityAction.RequestMinimum,
> >> Unrestricted = true)]
> >> [assembly: AllowPartiallyTrustedCallers]
> >>
> >> - I have tried the following at the top of the function:
> >> System.DirectoryServices.DirectoryServicesPermission pDir = new
> >> DirectoryServicesPermission(System.Security.Permissions.PermissionState.Unrestricted);
> >> System.DirectoryServices.DirectoryServicesPermissionEntry pDirEnt = new
> >> DirectoryServicesPermissionEntry(System.DirectoryServices.DirectoryServicesPermissionAccess.Browse,"");
> >> pDir.PermissionEntries.Add(pDirEnt);
> >> pDir.Assert();
> >>
> >> Please help!
> >> I have been trying to solve this for ages and just cannot find a
> >> solution.
> >>
> >> Regards,
> >> Flon Mackenzie
> >>
> >
> >
>
>