Dear all,

I am using vxl library (version 1.12.0) without having a problem in a "Win32 Console Application" in Visual Studio 2008.  I am using it in a 32bit Windows XP computer.

Recently I decided to build a GUI application and created a "Windows Forms Application". However, now I am having these "unresolved external symbol errors". I do not understand what is wrong here. I am using the exact same computer, Visual Studio program, vxl libraries etc. and I am including and linking the exact same libraries. Yet, if I have a "Win32 Console Application" everything works perfectly well but in "Windows Forms Application" it does not work. I will really appreciate if you can help me on how to solve this problem. Here is the code I am using and the errors I get:

My code includes only these two lines about vxl library:

#include "vil/vil_image_view.h"
...
....
 vil_image_view<vxl_uint_16> image_stack(1,1,1,1);


I am getting the following errors:

Error 10 error LNK2001: unresolved external symbol "private: static void __clrcall vil_smart_ptr<class vil_memory_chunk>::unref(class vil_memory_chunk *)" (?unref@?$vil_smart_ptr@Vvil_memory_chunk@@@@$$FCMXPAVvil_memory_chunk@@@Z) form_stuff.obj
Error 16 error LNK2001: unresolved external symbol "public: __clrcall vil_image_view<unsigned short>::vil_image_view<unsigned short>(unsigned int,unsigned int,unsigned int,unsigned int)" (??0?$vil_image_view@G@@$$FQAM@IIII@Z) form_stuff.obj
Error 11 error LNK2001: unresolved external symbol "public: virtual bool __clrcall vil_image_view<unsigned short>::is_class(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)const " (?is_class@?$vil_image_view@G@@$$FUBM_NABV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@Z) form_stuff.obj
Error 12 error LNK2001: unresolved external symbol "public: virtual class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > __clrcall vil_image_view<unsigned short>::is_a(void)const " (?is_a@?$vil_image_view@G@@$$FUBM?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@XZ) form_stuff.obj
Error 13 error LNK2001: unresolved external symbol "public: virtual void __clrcall vil_image_view<unsigned short>::print(class std::basic_ostream<char,struct std::char_traits<char> > &)const " (?print@?$vil_image_view@G@@$$FUBMXAAV?$basic_ostream@DU?$char_traits@D@std@@@std@@@Z) form_stuff.obj
Error 14 error LNK2001: unresolved external symbol "public: virtual void __clrcall vil_image_view<unsigned short>::set_size(unsigned int,unsigned int)" (?set_size@?$vil_image_view@G@@$$FUAMXII@Z) form_stuff.obj
Error 15 error LNK2001: unresolved external symbol "public: virtual void __clrcall vil_image_view<unsigned short>::set_size(unsigned int,unsigned int,unsigned int)" (?set_size@?$vil_image_view@G@@$$FUAMXIII@Z) form_stuff.obj
Error 17 fatal error LNK1120: 7 unresolved externals ..\..\..\bin\form_stuff.exe

 Thanks a lot in advance.  
Osman