문제

In Windows application using vb.net a APP.config file is created automatically. Is that file is created in windows application developed using C# ? If yes then where can I find it ?
As I'm developing a project in ASP.net in which I've to use a web application for video conferencing, for which I'm using iconf.net dll files from AVSpeed. In which I've to enable flag for realtime application which is in APP.config file as said.

도움이 되었습니까?

해결책 2

If you are creating a new windows application in C# then by default you dont get any app config file. To answer your question, Yes C# does support appconfig files. You can add them as shown below :

enter image description here

Then you can exploit its XML to set some values as shown in the example below.

<configuration>
  <appSettings>
    <add key="TestFlag" value="false" />
    <add key="TestUser" value="somevalue" />
    <add key="TestPass" value="somevalue" />
    <add key="TestRole" value="SA" />
    <add key="TestModeOfOp" value="dssaas" />
    <add key="TestFetchRef" value="" />
    <add key="TestFetchQuoteNo" value="" />
    <add key="TestVersionNo" value=""/>
    <add key="TestProdCode" value="233" />
    <add key="TestSessionID" value="123123"/>
    <add key="TestServiceIP" value="192.168.30.21"/>
  </appSettings>
</configuration>

In my case I use APP.XAML to get the value from the app.config in its application_startup.

다른 팁

For Web applications its web.config and for desktop applications its app.config. You can add config files to your project as well.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top