Which code segment should you use?

You are creating a console application by using C#.
You need to access the assembly found in the file named car.dll.
Which code segment should you use?

You are creating a console application by using C#.
You need to access the assembly found in the file named car.dll.
Which code segment should you use?

A.
Assembly.Load();

B.
Assembly.GetExecutingAssembly();

C.
this.GetType();

D.
Assembly.LoadFile(“car.dll”);



Leave a Reply 7

Your email address will not be published. Required fields are marked *


MarcoJacob

MarcoJacob

Answers are wrong, or?
Correct would be “Assembly.Load(“car.dll”);”.

Djay

Djay

I believe D is the right answer..

Manab

Manab

Assembly.LoadFile(String) – Loads the contents of an assembly file on the specified path.
Assembly.Load(String) – Loads an assembly given the long form of its name.
There is no method Assembly.Load(), so correct answer is D, but result is not an assembly, result is content of an assembly file.