Resources assemblys and csc.exe

  • Thread starter Thread starter dgauchet
  • Start date Start date
D

dgauchet

Hi all,

I would build a resources assembly (no code, only resources) using csc.exe.
I launched :
csc.exe /out:MyDll.dll /target:library /res:.\..\Main.resources
or
csc.exe /out:MyDll.dll /target:library /res:.\..\Main.resx

but it doesn't work.

Is somebody knows if it's possible and, in this case, what I am doing wrong?


Thanks a lot.
 
I would build a resources assembly (no code, only resources) using csc.exe.

Use Al.exe for that instead.



Mattias
 
Thanks Mattias.

Effectively, I had to generate my .resources files using ResGen.exe (or
CFResGen.exe for compact applications) and to link these files in my
assembly using AL.exe
It works fine!!

Example:
CFResGen /compile A.resx B.resx
A.resources and B.resources were generated
AL /out:MyProject.dll /embed:A.resources,MyProject.A.resources
/embed:B.resources,MyProject.B.resources
MyProject.dll was created

Note that you need to add your project's name in the logical name of your
..resources files if you want to retrieve your resources at the running time.

D.
 
Back
Top