Error - Trying Get Advertisement(MarketingSystem).

Hi everybody!!

I am trying to get a Ads(Advertisement) created in my commerce server, but an error is happen...

error =http://www40.brinkster.com/guilhermegara/images/error.jpg

There is my code:

IPrincipal
principal =newWindowsPrincipal(WindowsIdentity.GetCurrent());
Thread.CurrentPrincipal = principal;
stringcurrentUser = principal.Identity.Name;

stringstrNomeSite ="SCE"; //Name application
MarketingContext ctx =MarketingContext.Create(strNomeSite,@"C:\Inetpub\wwwroot\application\MarketingWebService\MarketingAuthorizationStore.xml",AuthorizationMode.ThreadContext,10,20);

PageGroup[] pg = ctx.PageGroups.GetAllPageGroups();

I was set all configurations for *.webserviceAthorizationStore (in azman.msc)!

My MarketingWebService is with windows authentication (not allow user anonymous).

I trying change the mode of authentication in parameter... ->

MarketingContext.Create(strNomeSite,@"C:\Inetpub\wwwroot\application\MarketingWebService\MarketingAuthorizationStore.xml",AuthorizationMode.HttpContext);

... and not solve my problem!!!

Know anybody what happens?

Thanks in advance!

Guilherme Gara.

[2050 byte] By [GuilhermeGara] at [2008-1-8]
# 1

Hi Guilherme,

I am unable to see the actual error that you provided in the link. Can you paste the error details into your message?

Thanks,

madhur

madhur-MSFT at 2007-10-2 > top of Msdn Tech,Commerce Server,Commerce Server 2007...
# 2

Copy the Link of image and past in other browser!! I do that... success...

You see that erro is about Page group...

Thanks.

Guilherme Gara.

GuilhermeGara at 2007-10-2 > top of Msdn Tech,Commerce Server,Commerce Server 2007...
# 3

Guilherme,

The link you posted does not allow unauthenticated access. I'm assuming it's working fine for you because you probably have an authentication cookie which is allowing you to look at your own page, but the rest of us are getting a 403 message when pasting the URL for that link.

JosephJohnson at 2007-10-2 > top of Msdn Tech,Commerce Server,Commerce Server 2007...
# 5

We see,

HTTP1.1 STATUS 403 Remote Access to this object forbidden This file cannot be directly accessed from a remote site, but must be linked through the Brinkster Member's site.

If you create a page that includes the image, then you can post a link to the page.

[For anyone willing to fiddle a bit, try loading http://www40.brinkster.com/guilhermegara/ (you will see an error) and then load the image.]

AndyMiller at 2007-10-2 > top of Msdn Tech,Commerce Server,Commerce Server 2007...