Anuya
Anuya

Reputation: 8350

Problem using Add key value in app.config of c# windows application

I am trying to use the below in my app.config

<add key="InstanceID" value="HID\VID_413C&PID_3200\6&227E6ED3&0&0000" />

It shows error in app.config, what is the problem ? i want to use this value as string in my c# code.

Upvotes: 0

Views: 539

Answers (1)

Zachary
Zachary

Reputation: 6532

You need to encode your special characters, example (& = &amp;). I think that's the only problem character.

Upvotes: 2

Related Questions