Hi, I know this link, but the code doesn't work. I use VS2010 Prof. and OSG 2.8.3
The first problem is ::GetWindowRect( hwnd, &rect ); error LNK2028 .... Unresolved Token ... Defining a namespace namespace SysWin { [DllImport("user32.dll")] int GetWindowRect(HWND hwnd, RECT* rc); } and using SysWin::GetWindowRect( hwnd, &rect ); solves the problem for this. But the next problem when running the app occurs in line osg::ref_ptr<osg::GraphicsContext> gc = osg::GraphicsContext::createGraphicsContext( traits.get() ); "Unhandled Exception ... System.Runtime.Interop.Services.SEHException at osg.GraphicsContext.createGraphicsContext(Traits* ) ... " And so an... Anyone a running example using VS2010, .NET 4.0 and a CLR windows forms app? Thank you! Cheers, Andreas ------------------ Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=34824#34824 _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org