Force a file to be copied when a component is created

  • Thread starter Thread starter CJ Taylor
  • Start date Start date
C

CJ Taylor

Is there anyway to force a file to be copied to the Bin directory of the
referencing applicaiton when a component is created?

i.e. how the comment files work for intellisense. when added, they copy
over the xml file.

I know how I "could" write it, just seeing if something already exists.

Thanks,
CJ
 
* "CJ Taylor said:
Is there anyway to force a file to be copied to the Bin directory of the
referencing applicaiton when a component is created?

i.e. how the comment files work for intellisense. when added, they copy
over the xml file.

I know how I "could" write it, just seeing if something already exists.

Did you try to add the file to the project and play around with its
'Build Action'?
 
I was thinking about this as well. using the EnvDTE (which seems redundant
doesn't it) to copy the file, but not use a build event, rather when the
file is added. I think I'm going to use the code from the Add XP Theme
Plugin that was publically posted awhile back.

However, this doesn't really "solve" the problem. Because that means that
the plugin has to be installed in order for it to work. Whereas I want to
be able to distribute a component with certain data files attached with it,
and copy those to the directory when added to a project. I suppose I could
hook the design time environemnt on the constructor and go from there. But
seems a little excessive. Thats why I was seeing if microsoft already
included a way to do so.



-CJ
 
Back
Top