I had to do some cleanup on my generated files as well, there was a brace in
the wrong place. My first suggestion would be to get the most recent build
(not 0.18) and see if it's still happening there.

On Thu, Mar 19, 2009 at 8:42 AM, <[email protected]> wrote:

>
> Hello Forum,
>
> I have a MySQL DB. I want to use it with Linq. I followed this
> instructions: http://code2code.net/DB_Linq/index.html
>
> - I have downloaded the zip releases (DbLinq-0.18.zip).
> - I used the run_myMetal.bat file from the src\DBMetal folder to
> generate a .cs file of my database. (A C# file was created in the
> build folder with the name of my DB.)
> - I created a new C# Class Library Project with Visual Studio 2008
> Professional and included the C# file. (Now I have 12 errors within
> the project)
> - I added the build folder to the Windows Path variable.
> - I added a reference to "DbLinq.MySql.dll" within the new C# project.
> (Now I have 93 errors, but if I compile the project again I have again
> 12 errors.)
>
>
> Here a sample code. Amount is a column in one of my tables. The errors
> are written in the comments.
> #region  "Amount"
>
> private  _amount; // Invalid token ';' in class, struct, or interface
> member declaration
>
> [DebuggerNonUserCode]
> [Column(Storage = "_amount", Name = "Amount", DbType = "double
> unsigned", CanBeNull = false)]
> public  Amount
> { // Invalid token '{' in class, struct, or interface member
> declaration
>        get
>        { // Invalid token '{' in class, struct, or interface member
> declaration
>                return _amount; // Invalid token ';' in class, struct, or
> interface
> member declaration
>        }
>        set // A namespace does not directly contain members such as fields
> or methods
>        {
>                if (value != _amount)
>                {
>                        _amount = value;
>                        OnPropertyChanged("Amount");
>                }
>        }
> }
>
> #endregion
>
> It seems that class/struct "_amount" is not defined. If I search
> within the .cs for "amount", this name only appears in this piece of
> code. Is this an error within DBMetal or do I have an unusual database
> definition?
>
>
> Regards
>
> Peter
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"DbLinq" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/dblinq?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to