Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

F#: Namespace not defined when trying to open System.Windows.Forms

I am using Visual Studio 2008 Integrated Shell with the F# CTP (October). Everything works fine, but when I am trying to open System.Windows.Forms, VS gives an error: the namespace 'Windows' is not defined.

However, it works when I try to open the namespace in F# interactive.

What am I doing wrong?

like image 237
Reshure Avatar asked Nov 19 '09 14:11

Reshure


1 Answers

For F# Visual Studio projects you will need to right click on your project References entry and walk through the Add Reference dialog. F# Interactive includes references to several frequently used assemblies by default whereas F# application projects only get FSharp.Core, mscorlib, System, and System.Core by default.

like image 191
Ray Vernagus Avatar answered Sep 22 '22 02:09

Ray Vernagus