FORUMS

c360 Forums
 Home        Members    Calendar    Who's On

Welcome Guest ( Login | Register )
      



Installation & LicensingExpand / Collapse
Message
Posted 2/14/2006 3:55:15 AMPost #19
 

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie
StartFragment I followed the installation instructions of c360 SDK (readme.txt) and I deployed the evaluation Licence successfully, using the tool that c360 emailed me. I added c360 assemblies in my project (in a virtual directory of CRM site) and I copied code from Exercise_3_1. No errors at this time. When I try to build the solution, I receive a server error with a long list that seems to me errors in checking licence:


Source Error:

 
Line 30: 
Line 31:     Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Line 32:         Dim pagina As New c360.Toolkit.SDK.Pages.AreaPage
Line 33:         pagina.MenuArea.Height = Unit.Pixel(0)
Line 34:         pagina.LeftArea.Width = Unit.Pixel(0)


Source File: \\Snserver-crm1\Microsoft CRM\CRMWeb\Protocollo\c360Test.aspx.vb    Line: 32

Stack Trace:

 
[LicenseException: Client found response content type of 'text/plain; charset=utf-8', but expected 'text/xml'.
The request failed with the error message:
--
System.InvalidOperationException: 2006/CrmService.asmx Web Service method name is not valid.
   at System.Web.Services.Protocols.HttpServerProtocol.Initialize()
   at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type, HttpContext context, HttpRequest request, HttpResponse response, Boolean& abortProcessing)
 
--. Please contact Licensing@c360.com for all licensing issues. You will have to provide the following information: Organization name = "ERROR: Could not retrieve Organization Name: System.InvalidOperationException: Client found response content type of 'text/plain; charset=utf-8', but expected 'text/xml'.
The request failed with the error message:
--
System.InvalidOperationException: 2006/CrmService.asmx Web Service method name is not valid.
   at System.Web.Services.Protocols.HttpServerProtocol.Initialize()
   at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type, HttpContext context, HttpRequest request, HttpResponse response, Boolean& abortProcessing)
 
--.
   at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
   at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
   at c360.Toolkit.CRM2005.CrmService.Execute(Request Request)
   at c360.Toolkit.Security.CRMSecurityPrincipal.()
   at c360.Toolkit.Security.CRMSecurityPrincipal.()
   at c360.Toolkit.Security.CRMSecurityPrincipal.()
   at c360.Toolkit.Security.CRMSecurityPrincipal.()
   at c360.Toolkit.Security.CRMSecurityPrincipal.()
   at c360.Toolkit.Licensing.c360LicenseProvider.GetOrganization()
   at c360.Toolkit.Licensing.c360LicenseProvider.get_Organization()
   at c360.Toolkit.Licensing.c360LicenseProvider.()"". Required number of licenses = ERROR: Could not retrieve Required Seat Count: System.InvalidOperationException: Client found response content type of 'text/plain; charset=utf-8', but expected 'text/xml'.
The request failed with the error message:
--
System.InvalidOperationException: 2006/CrmService.asmx Web Service method name is not valid.
   at System.Web.Services.Protocols.HttpServerProtocol.Initialize()
   at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type, HttpContext context, HttpRequest request, HttpResponse response, Boolean& abortProcessing)
 
--.
   at System.Web.Services.Protocols.SoapHttpClientProtocol.ReadResponse(SoapClientMessage message, WebResponse response, Stream responseStream, Boolean asyncCall)
   at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters)
   at c360.Toolkit.CRM2005.CrmService.Execute(Request Request)
   at c360.Toolkit.Security.CRMSecurityPrincipal.()
   at c360.Toolkit.Security.CRMSecurityPrincipal.()
   at c360.Toolkit.Security.CRMSecurityPrincipal.()
   at c360.Toolkit.Security.CRMSecurityPrincipal.()
   at c360.Toolkit.Security.CRMSecurityPrincipal.()
   at c360.Toolkit.Licensing.c360LicenseProvider.GetOrganization()
   at c360.Toolkit.Licensing.c360LicenseProvider.get_Organization()
   at c360.Toolkit.Licensing.c360LicenseProvider.()
   at c360.Toolkit.Licensing.c360LicenseProvider.GetRequiredSeatCount()
   at c360.Toolkit.Licensing.c360LicenseProvider.()".]
   c360.Toolkit.Licensing.c360LicenseProvider.(LicenseContext A_0, Type A_1, Object A_2, Boolean A_3) +985
   c360.Toolkit.Licensing.c360LicenseProvider.GetLicense(LicenseContext context, Type type, Object instance, Boolean allowExceptions) +18
   System.ComponentModel.LicenseManager.ValidateInternalRecursive(LicenseContext context, Type type, Object instance, Boolean allowExceptions, License& license, String& licenseKey) +325
   System.ComponentModel.LicenseManager.ValidateInternal(Type type, Object instance, Boolean allowExceptions, License& license) +44
   System.ComponentModel.LicenseManager.Validate(Type type, Object instance) +32
   c360.Toolkit.SDK.Pages.AreaPage..ctor() +29
   gp.c360Test.Page_Load(Object sender, EventArgs e) in \\Snserver-crm1\Microsoft CRM\CRMWeb\Protocollo\c360Test.aspx.vb:32
   System.Web.UI.Control.OnLoad(EventArgs e) +67
   System.Web.UI.Control.LoadRecursive() +35
   System.Web.UI.Page.ProcessRequestMain() +750
 

Posted 2/14/2006 1:45:43 PMPost #20
 

c360 Product Guruc360 Product Guruc360 Product Guruc360 Product Guruc360 Product Guruc360 Product Guruc360 Product Guruc360 Product Guru
The first thing I notice is that your web page does not derive from one of the Web page classes in the SDK. The syntax in C# is:

public class MyPage : c360.Toolkit.SDK.Pages.AreaPage

I am less familiar with VB.NET but I believe the proper syntax is something like:

Public Class MyPage
Inherits c360.Toolkit.SDK.Pages.AreaPage



Jeremie Desautels

VP, Product Marketing

c360 Solutions

Posted 2/14/2006 1:49:02 PMPost #21
 

c360 Product Guruc360 Product Guruc360 Product Guruc360 Product Guruc360 Product Guruc360 Product Guruc360 Product Guruc360 Product Guru
Also, something to double check is the value of the WebServicesUrl key in the c360.config to make sure that it points to the appropriate URL where the CRM webservices are exposed. This is especially important if your CRM web site is running on a "non-standard" IP port number or if a host header is required.

take a look at the following KB article for more information: http://www.c360.com/Support/Default.aspx?Number=KBA-01007&operation=KBDETAILS 

Jeremie Desautels

VP, Product Marketing

c360 Solutions

Posted 2/15/2006 3:34:50 AMPost #22
 

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie
Yesterday I posted the error message text. The code behind of c360Test.aspx is as follow:

________________________________________________________

Imports c360.Toolkit.SDK

Imports c360.Toolkit.UI

Imports c360.Toolkit.SDK.Pages

Imports System.Web.UI.WebControls

Public Class c360Test

Inherits System.Web.UI.Page

#Region " Web Form Designer Generated Code "

'This call is required by the Web Form Designer.

<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()

End Sub

'NOTE: The following placeholder declaration is required by the Web Form Designer.

'Do not delete or move it.

Private designerPlaceholderDeclaration As System.Object

Private Sub Page_Init(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Init

'CODEGEN: This method call is required by the Web Form Designer

'Do not modify it using the code editor.

InitializeComponent()

End Sub

#End Region

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

Dim pagina As New c360.Toolkit.SDK.Pages.AreaPage

pagina.MenuArea.Height = Unit.Pixel(0)

pagina.LeftArea.Width = Unit.Pixel(0)

pagina.ContentArea.Controls.Add(New System.Web.UI.LiteralControl("<br>" + DateTime.Now.ToLongDateString()))

pagina.FooterArea.Controls.Add(New System.Web.UI.LiteralControl(DateTime.Now.ToLongTimeString()))

End Sub

End Class

_____________________________________________

The error message posted yesterday rises when the application makes a new instance of "c360.Toolkit.SDK.Pages.AreaPage" at the code line "Dim pagina As New c360.Toolkit.SDK.Pages.AreaPage".

In 360.config I modified the WebServicesUrl as follow

<add key="WebServicesUrl" value="http://snserver-crm1:5555/mscrmservices" />

I'm sure that it is a valid address.

May I suppose that the "c360.Toolkit.SDK Version 3.lic" is not a valid licence for my CRM Organization?
I remember that the organization name is "INCOM" and the number of users is 100000.

Sorry for my english.

Michele Ficarazzi

Posted 2/15/2006 9:03:45 AMPost #23
 

Forum Member
Miko,

When utilizing the AreaPage class from our SDK, you do not create a new AreaPage object (there is no constructor for that), instead, as Jeremie mentioned, your page needs to inherit that class.  For example, in your code, where you have:

Inherits System.Web.UI.Page

it should say:

Inherits c360.Toolkit.SDK.Pages.AreaPage

(AreaPage inherits from our Base page, which inherits form System.Web.UI.Page, so you will have all of the same properties available - and more) 

Then, when you add objects to that page or need to reference one of the four areas, you would do so by referencing the Instance of this page like so:

Instance.MenuArea.Height = Unit.Pixel(0)
Instance.LeftArea.Width = Unit.Pixel(0)
Instance.ContentArea.Controls.Add(New System.Web.UI.LiteralControl("<br>" + DateTime.Now.ToLongDateString()))

Also, in your web.config (not c360.config), make sure you point to the location of where you have the toolkit installed, as taken from our README file:

"The one and only key that can be added to the web.config file. This key is required.  This must point to the installation location of the c360 SDK relative to the root of the website.  If it is installed into the root of the website you are working in, then the value would be:

<add key='c360Location' value='/'/>

If it was installed into a sub-directory of that website, for example, SDK, the value would be:

<add key='c360Location' value='/SDK/'/>"

If your WebServicesUrl key in the c360.config is right, then it should work fine.  Thanks for posting and let me know if that helps!

miko65 (2/15/2006)
Yesterday I posted the error message text. The code behind of c360Test.aspx is as follow:

...

The error message posted yesterday rises when the application makes a new instance of "c360.Toolkit.SDK.Pages.AreaPage" at the code line "Dim pagina As New c360.Toolkit.SDK.Pages.AreaPage".

In 360.config I modified the WebServicesUrl as follow

<add key="WebServicesUrl" value="http://snserver-crm1:5555/mscrmservices" />

I'm sure that it is a valid address.

May I suppose that the "c360.Toolkit.SDK Version 3.lic" is not a valid licence for my CRM Organization?
I remember that the organization name is "INCOM" and the number of users is 100000.

Sorry for my english.

Michele Ficarazzi



Kevin Eichelberger
Pre-Sales Engineer / Product Specialist
c360 Solutions, Inc.
Posted 2/15/2006 9:56:28 AMPost #25
 

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie
This is the code modified:

Imports c360.Toolkit.SDK

Imports c360.Toolkit.UI

Imports System.Web.UI.WebControls

Public Class c360Test

Inherits c360.Toolkit.SDK.Pages.AreaPage

#Region " Web Form Designer Generated Code "

'This call is required by the Web Form Designer.

<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()

End Sub

'NOTE: The following placeholder declaration is required by the Web Form Designer.

'Do not delete or move it.

Private designerPlaceholderDeclaration As System.Object

Private Sub Page_Init(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Init

'CODEGEN: This method call is required by the Web Form Designer

'Do not modify it using the code editor.

InitializeComponent()

End Sub

#End Region

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

Instance.MenuArea.Height = Unit.Pixel(0)

Instance.LeftArea.Width = Unit.Pixel(0)

Instance.ContentArea.Controls.Add(New System.Web.UI.LiteralControl("<br>" + DateTime.Now.ToLongDateString()))

Instance.FooterArea.Controls.Add(New System.Web.UI.LiteralControl(DateTime.Now.ToLongTimeString()))

End Sub

________________________________________________________

this is the server error text:

There is an invalid character in the given encoding. Line 7, position 48. Please contact Licensing@c360.com for all licensing issues. You will have to provide the following information: Organization name = "ERROR: Could not retrieve Organization Name: System.Xml.XmlException: There is an invalid character in the given encoding. Line 7, position 48. at System.Xml.XmlScanner.GetChars(Byte[] srcBuffer, Int32& srcOffset, Int32 srcLen, Char[] destBuffer, Int32 destOffset, Boolean zeroedOut) at System.Xml.XmlScanner.Read() at System.Xml.XmlScanner.ScanLiteral() at System.Xml.XmlTextReader.SetLiteralValues(XmlAttributeTokenInfo fld) at System.Xml.XmlTextReader.SetAttributeValues() at System.Xml.XmlTextReader.ParseElement() at System.Xml.XmlTextReader.Read() at System.Xml.XmlLoader.LoadCurrentNode() at System.Xml.XmlLoader.LoadDocSequence(XmlDocument parentDoc) at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace) at System.Xml.XmlDocument.Load(XmlReader reader) at c360.Toolkit.Config.ConfigFileReader.ᜀ() at c360.Toolkit.Config.CachedConfigFileReader.ᜀ() at c360.Toolkit.Util.ᜀ(String A_0, String A_1, String A_2) at c360.Toolkit.Util.ᜀ(String A_0, String A_1, String A_2, Boolean A_3) at c360.Toolkit.Util.GetWebConfigSetting(String strWebConfigKeyName) at c360.Toolkit.Security.ImpersonationStrategy.ᜀ() at c360.Toolkit.Security.ImpersonationStrategy.ᜁ() at c360.Toolkit.Licensing.c360LicenseProvider.GetOrganization() at c360.Toolkit.Licensing.c360LicenseProvider.get_Organization() at c360.Toolkit.Licensing.c360LicenseProvider.ᜀ()"". Required number of licenses = ERROR: Could not retrieve Required Seat Count: System.Xml.XmlException: There is an invalid character in the given encoding. Line 7, position 48. at System.Xml.XmlScanner.GetChars(Byte[] srcBuffer, Int32& srcOffset, Int32 srcLen, Char[] destBuffer, Int32 destOffset, Boolean zeroedOut) at System.Xml.XmlScanner.Read() at System.Xml.XmlScanner.ScanLiteral() at System.Xml.XmlTextReader.SetLiteralValues(XmlAttributeTokenInfo fld) at System.Xml.XmlTextReader.SetAttributeValues() at System.Xml.XmlTextReader.ParseElement() at System.Xml.XmlTextReader.Read() at System.Xml.XmlLoader.LoadCurrentNode() at System.Xml.XmlLoader.LoadDocSequence(XmlDocument parentDoc) at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace) at System.Xml.XmlDocument.Load(XmlReader reader) at c360.Toolkit.Config.ConfigFileReader.ᜀ() at c360.Toolkit.Config.CachedConfigFileReader.ᜀ() at c360.Toolkit.Util.ᜀ(String A_0, String A_1, String A_2) at c360.Toolkit.Util.ᜀ(String A_0, String A_1, String A_2, Boolean A_3) at c360.Toolkit.Util.GetWebConfigSetting(String strWebConfigKeyName) at c360.Toolkit.Security.ImpersonationStrategy.ᜀ() at c360.Toolkit.Security.ImpersonationStrategy.ᜁ() at c360.Toolkit.Licensing.c360LicenseProvider.GetOrganization() at c360.Toolkit.Licensing.c360LicenseProvider.get_Organization() at c360.Toolkit.Licensing.c360LicenseProvider.ᜀ() at c360.Toolkit.Licensing.c360LicenseProvider.GetRequiredSeatCount() at c360.Toolkit.Licensing.c360LicenseProvider.ᜀ()".

____________________________________________________

In the appconfig section of my web.config file I added the key:

<add key="c360Location" value="/c360sdk/" />.

I think it's right because changing the value the server error asks for c360 location.

Posted 2/15/2006 9:59:57 AMPost #26
 

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie
Errata corrige

I mean

<appSettings> instead of appconfig

Posted 2/15/2006 10:08:30 AMPost #27
 

Forum Member