SharpDevelop Community

Get your problems solved!
Welcome to SharpDevelop Community Sign in | Join | Help
in Search

Compact Framework project problems

Last post 09-03-2007 4:22 PM by jcarvalho. 6 replies.
Page 1 of 1 (7 items)
Sort Posts: Previous Next
  • 06-29-2007 8:43 PM

    Compact Framework project problems

    I have just installed SharpDevelop 2.1. With the wizard I create a new Compact Framework Windows Application, then (without making any change to the code generated) I click on "Build Solution" and get this error:


    Error CS0246: The type or namespace name 'STAThread' could not be found (are you missing a using directive or an assembly reference?)

    This error doesn't happen if I make an standard "Windows Application".

     

    Help!!! 

  • 06-29-2007 10:06 PM In reply to

    Re: Compact Framework project problems

    That's a mistake in the Compact Framework project template, you just have to remove the [STAThread] line. This has been fixed in SharpDevelop 2.2.
    Daniel Grunwald
  • 06-30-2007 10:13 AM In reply to

    Re: Compact Framework project problems

    Yes, removing [STAThread] solves the problem.

     Thank you very much
     

  • 07-26-2007 1:22 PM In reply to

    Compact Framework project problems

    Hi, I have install the .NET compact framework 2.0 and the compact framework sdk and then the sharp develop.

    After, when i try make a mobile app, after put the name of solution the sharp develop give me the follow message:

     "Error loading C:\Documents and Settings\...\Projectos\teste\teste.csproj:

     The imported project

     'C:\WINNT\Microsoft.NET\Framework\v2.0.5.727\Mcrosoft.CompactFramework.CSharp.tergets' was no found.

     Confirm that the path in the <Import> declaration is correct, and that the file exists on disk.

     C:\Programas\SharpDevelop\2.2\bin\SharpDevelop.Build.CSharp.targets"

     

    This is the error that appear, then I hit  the ok buttom and it creats the next files:

         -AssemblyInfo.cs

         -MainForm.cs

         -MainForm.Designer.cs

         -teste.csproj

     

    I verified if that files already exists but only the  " C:\Programas\SharpDevelop\2.2\bin\SharpDevelop.Build.CSharp.targets" exist.

     I would try compile the "MainForm.cs" file after create a line of code (Hello world print, for exemple) and the compiler give e error saying which "is not support the only file compilation,  please create a project".

    What I do wrong? miss me any file? how do I resolve this problem?

     Thanks for any ideas
  • 07-26-2007 3:48 PM In reply to

    Another problem

    Guys, my previously problem is resolved, I uninstall and install everithing again and did work.

     Now I create a single compact framework aplication with a simple buttons and combobox and when I compile it give me this errors:

     'System.Windows.Forms.Button' does not contain a definition for 'UseVisualStyleBackColor' (CS0117) - C:\Documents and Settings\JCarvalho\Ambiente de trabalho\Projectos\PDA\Hello World\MainForm.Designer.cs:60,17

    'System.Windows.Forms.ComboBox' does not contain a definition for 'FormattingEnabled' (CS0117) - C:\Documents and Settings\JCarvalho\Ambiente de trabalho\Projectos\PDA\Hello World\MainForm.Designer.cs:88,19

    'System.Windows.Forms.ComboBox.ObjectCollection' does not contain a definition for 'AddRange' (CS0117) - C:\Documents and Settings\JCarvalho\Ambiente de trabalho\Projectos\PDA\Hello World\MainForm.Designer.cs:89,25

    'System.Windows.Forms.Button' does not contain a definition for 'UseVisualStyleBackColor' (CS0117) - C:\Documents and Settings\JCarvalho\Ambiente de trabalho\Projectos\PDA\Hello World\MainForm.Designer.cs:107,17

    'System.Windows.Forms.Label' does not contain a definition for 'BorderStyle' (CS0117) - C:\Documents and Settings\JCarvalho\Ambiente de trabalho\Projectos\PDA\Hello World\MainForm.Designer.cs:120,16

    'System.Windows.Forms.Button' does not contain a definition for 'UseVisualStyleBackColor' (CS0117) - C:\Documents and Settings\JCarvalho\Ambiente de trabalho\Projectos\PDA\Hello World\MainForm.Designer.cs:133,17

    'System.Windows.Forms.Button' does not contain a definition for 'UseVisualStyleBackColor' (CS0117) - C:\Documents and Settings\JCarvalho\Ambiente de trabalho\Projectos\PDA\Hello World\MainForm.Designer.cs:143,17

    'System.Windows.Forms.Button' does not contain a definition for 'UseVisualStyleBackColor' (CS0117) - C:\Documents and Settings\JCarvalho\Ambiente de trabalho\Projectos\PDA\Hello World\MainForm.Designer.cs:153,17

    'Hello_World.MainForm' does not contain a definition for 'PerformLayout' (CS0117) - C:\Documents and Settings\JCarvalho\Ambiente de trabalho\Projectos\PDA\Hello World\MainForm.Designer.cs:184,9

     

    This are the errors that appear when I compile the code .

     

    Anyone knows how resolve this problems?

     Thanx

  • 07-26-2007 6:27 PM In reply to

    Re: Another problem

    That's because those are properties and procedures not supported when programming for CF.Net. You just have to comment or delete the lines that are rising those errors.
  • 09-03-2007 4:22 PM In reply to

    Re: Another problem

    Thanks man, I did it  and solved the problem.

     I hope that in next version of #develop this errors gone :)

     thanks again

Page 1 of 1 (7 items)
Powered by Community Server (Commercial Edition), by Telligent Systems
Don't contact us via this (fleischfalle@alphasierrapapa.com) email address.