For a deeper look into our DataScope Select SOAP API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials

question

Upvotes
Accepted
3 0 0 2

Example C# Application does not work

Hi all,

I've downloaded C# Example WPF Application but. I cannot run this.

I tried both via visual studio and execute Dss.Api.Examples.exe directly. I got same following error.

'Initialization of 'Dss.Api.Examples.MainWindow' threw an exception.' Line number '226' and line position '7'.

What does mean?

Thanks

dss-rest-apidatascope-selectdssvisual-studioexample
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

When did you get the error: just after starting the program, or after entering your DSS username and password in the popup ?

just starting. did not come any screen

Upvotes
Accepted
7.6k 15 6 9

@numan.mazlum

The VS solution file(DSS.Api.Examples.sln) was created from Visual Studio 2013. It's not Visual Studio 2012. Please open the solution with Visual Studio 2013 instead, I think the problem may occurs because using mismatch version of visual studio component so it could not load the XAML.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvotes
13.7k 26 8 12

@numan.mazlum

Did you follow these installation instructions ? If you did, and downloaded the application after 20 March 2017, it should work fine.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvotes
3 0 0 2

- I Downloaded zip files again.

- Extract files to a folder

- I opened solution in VS 2012

- I changed userId and password

- I tried to build and than I got error: Missing reference "ICSharpCode.AvalonEdit"

- I added "ICSharpCode.AvalonEdit" reference from bin\release folder again

- Build Succeeded

- I click start on VS and than I get following error again.

'Initialization of 'Dss.Api.Examples.MainWindow' threw an exception.' Line number '226' and line position '7'.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvotes
465 3 5 3

@numan.mazlum, would you mind running this again in Visual Studio and posting the exception stack trace?

Also, what operating system and version are you using?

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvotes
3 0 0 2

I'm using Windows 8

You can find stack trace in following

at System.Windows.Markup.WpfXamlLoader.Load(XamlReader xamlReader, IXamlObjectWriterFactory writerFactory, Boolean skipJournaledProperties, Object rootObject, XamlObjectWriterSettings settings, Uri baseUri) at System.Windows.Markup.WpfXamlLoader.LoadBaml(XamlReader xamlReader, Boolean skipJournaledProperties, Object rootObject, XamlAccessLevel accessLevel, Uri baseUri) at System.Windows.Markup.XamlReader.LoadBaml(Stream stream, ParserContext parserContext, Object parent, Boolean closeStream) at System.Windows.Application.LoadComponent(Object component, Uri resourceLocator) at Dss.Api.Examples.MainWindow.InitializeComponent() in d:\Projects\RESTAPIExampleApplication\MainWindow.xaml:line 1 at Dss.Api.Examples.MainWindow..ctor() in d:\Projects\RESTAPIExampleApplication\MainWindow.xaml.cs:line 29

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvotes
3 0 0 2

Hi,

I don't think same. Because of when I run exe directly, I get same error.


dss-hata.jpg (14.0 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvotes
7.6k 15 6 9

@numan.mazlum

Do you have VS2013 runtime(.NET framework 4.5.x) installed on your windows when you run the exe?
If not please download it from MSDN and try running the execute file again.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Upvotes
3 0 0 2

I will try and inform you.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Please let us know if you still found the issue or it has been resolved after installed .NET framework 4.5.x.

Upvotes
3 0 0 2

Hi all again,

I installed VS 2013 and then my problem solved.

Thanks for all

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 5.0 MiB each and 10.0 MiB total.

Click below to post an Idea Post Idea