cancel
Showing results for 
Search instead for 
Did you mean: 

Error Adding Service Reference of SAP Service Layer WCF

0 Kudos

Hi Experts,

When i try to add a Service reference of service layer from an XML file, i get the following error
invalid Name attribute( Name attribute has spaces !!)

when i removed all spaces from name attributes i got the following error

Attribute cannot be as same as their enclosing type

so i changed the attributes with same name as their complexType name and then i got the following error

EnumTypes (BOYesNoEnum,BoAccountTypes,......) is not defined in SAPB1

i am sure that the EnumTypes are defined under <Schema Namespace = "SAPB1"

Each UDO has a space in its name why should i not have spaces in UDO description.
Previously i was removing Spaces manually from XML file as i never wanted to use the UDO's but now i need to use everything.

Please HELP.

Accepted Solutions (0)

Answers (2)

Answers (2)

Trinidad
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Bilal,

Please make sure you have set the following parameters in your service layer config file as explained in the blog (https://blogs.sap.com/2015/07/15/how-to-consume-service-layer-odata-services-from-net-via-wcf/) and restarted Service Layer afterwards:

  1. MetadataWithoutSession”: true
  2. WCFCompatible”:true

In the metadata file generated with WCFCompatible option there are no enumerations defined as not supported by WCF.

Hope this helps
Trinidad.

0 Kudos

Thanks Maria

but yeah these configurations are set to true.

0 Kudos

mariatrinidad.martinezgea Can you help me with this please