Select to view content in your preferred language

WCF doesn't seem to like class Graphic

918
3
12-01-2010 11:08 AM
SangamLama
Emerging Contributor
Hi,

I'm trying to compute driving directions between two locations. I'm following the sample available for SL/WPF. I need to pass "stops" so that the Route Server can compute the direction. Now the problem lies in using class Graphic. Whenever I use it on my wcf service, I get following error during compilation:

The type 'System.Windows.DependencyObject' is defined in an assembly that is not referenced.
You must add a reference to assembly 'WindowsBase, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'

what could be happening here?

Thanks,
0 Kudos
3 Replies
nakulmanocha
Esri Regular Contributor
You need to add WindowsBase assembly (v 4.0.0.0) to your WCF web project. Then error should go away.
0 Kudos
SangamLama
Emerging Contributor
You need to add WindowsBase assembly (v 4.0.0.0) to your WCF web project. Then error should go away.


Hi, I finally found the dll but after adding it as a reference, the error didn't disappear...

Is there any other workaround?
0 Kudos
SangamLama
Emerging Contributor
You need to add WindowsBase assembly (v 4.0.0.0) to your WCF web project. Then error should go away.


it worked, thanks!
0 Kudos