PrepAway - Latest Free Exam Questions & Answers

What should you do?

You work as the Microsoft.NET developer at Domain.com. The Domain.com network consists of a single Active Directory domain named Domain.com. All servers in the domain run Windows Server 2003.
The development and deployment of Microsoft.NET Remoting components forms part of your responsibilities at Domain.com. You are currently developing a Microsoft.NET Remoting component that will be accessed over the Domain.com local area network (LAN). To this end you create a console application named RemoteHost.exe to serve remote calls to the component. You added Remoting configuration settings in the app.config file of the console application’s project. Now you need to configure the host application to use those configuration settings that has been added in the app.config file.

What should you do? (Choose the appropriate code segment.)

PrepAway - Latest Free Exam Questions & Answers

A.
RemotingConfiguration.Configure[@”bin\Release\app.config”,false];

B.
RemotingConfiguration.Configure[“app.config”,false];

C.
RemotingConfiguration.Configure[@”bin\Debug\RemoteHost.exe.config”, false];

D.
RemotingConfiguration.Configure[“RemoteHost.exe.config”,false];

Explanation:
When passing the “RemoteHost.exe.config” to the configure method of the RemotingConfiguration class, then the app.config file is copied to the runtime directory and renamed to the executable file with”.config” affixed after you compile a console application.
Incorrect answers:
A: You should not pass “bin\Release\app.config” to the Configure method because this is a project file and not a runtime file.
B: You should not pass “app.config” to the Configure method because this is a project file and not a runtime file.
C: You should not pass “bin\Debug\RemoteHost.exe.config” to the configure method because the RemoteHost.exe.config file exists in the same folder as RemoteHost.exe. This means that you should only be passing the configuration file to the method.


Leave a Reply