GithubHelp home page GithubHelp logo

Comments (4)

mehar-eng avatar mehar-eng commented on July 22, 2024 1

Hi thiago

Thanks for your quick reply. the code given by you is working fine without any issue.i recreted my class library project and its working now.

from dapper.crud.extension.

thiagoloureiro avatar thiagoloureiro commented on July 22, 2024

Hello @mehar-eng , looks like there are itens in your project/folder which are not compiling correctly.
Please copy and paste the whole error here please too.

  1. Please first of all check if your solution is building properly.
  2. Check if there is any files not included in the project which are breaking (the component compiles everything and that's why.
  3. I also recommend you include all the model files that you use in the project in a separate project to make it easier and less dependant on other components.

Waiting your answer to help you out with the solution

from dapper.crud.extension.

mehar-eng avatar mehar-eng commented on July 22, 2024

Dear thiago

i have done all the suggestions from your end and project build is successfull but still i am getting the same error.below is the full error text.

MY MODAL

using System;

namespace Epro.Data.Models
{
///


/// Represents a ADP_Category.
/// NOTE: This class is generated from a T4 template - you should not modify it manually.
///

public class ADP_Category
{
public int ID { get; set; }

    public string EDESC { get; set; }

    public string ADESC { get; set; }
}

}

Compiler Errors

Error during the operation: Compiler Errors :
Line 16,1 : A using clause must precede all other elements defined in the namespace except extern alias declarations
Line 17,1 : A using clause must precede all other elements defined in the namespace except extern alias declarations
Line 18,1 : A using clause must precede all other elements defined in the namespace except extern alias declarations
Line 2862,22 : Invalid token '?' in class, struct, or interface member declaration
Line 2862,46 : Invalid token '{' in class, struct, or interface member declaration
Line 2862,51 : Invalid token ';' in class, struct, or interface member declaration
Line 2862,56 : Invalid token ';' in class, struct, or interface member declaration
Line 3290,21 : A namespace cannot directly contain members such as fields or methods
Line 3290,22 : Type expected
Line 3322,1 : Type or namespace definition, or end-of-file expected
Line 4064,22 : Invalid token '?' in class, struct, or interface member declaration
Line 4064,31 : Invalid token '{' in class, struct, or interface member declaration
Line 4064,36 : Invalid token ';' in class, struct, or interface member declaration
Line 4064,41 : Invalid token ';' in class, struct, or interface member declaration
Line 4068,1 : Type or namespace definition, or end-of-file expected
Line 4208,22 : Invalid token '?' in class, struct, or interface member declaration
Line 4208,39 : Invalid token '{' in class, struct, or interface member declaration
Line 4208,44 : Invalid token ';' in class, struct, or interface member declaration
Line 4208,49 : Invalid token ';' in class, struct, or interface member declaration
Line 4212,21 : A namespace cannot directly contain members such as fields or methods
Line 4212,22 : Type expected
Line 4218,1 : Type or namespace definition, or end-of-file expected
Line 13198,22 : Invalid token '?' in class, struct, or interface member declaration
Line 13198,43 : Invalid token '{' in class, struct, or interface member declaration
Line 13198,48 : Invalid token ';' in class, struct, or interface member declaration
Line 13198,53 : Invalid token ';' in class, struct, or interface member declaration
Line 13200,21 : A namespace cannot directly contain members such as fields or methods
Line 13200,22 : Type expected
Line 13202,1 : Type or namespace definition, or end-of-file expected
InnerException StackTrace at Dapper.Crud.VSExtension.Helpers.AssemblyHelper.BuildAssembly(String code) in C:\Projects\Dapper.Crud.Extension\Dapper.Crud.VSExtension\Helpers\AssemblyHelper.cs:line 46
at Dapper.Crud.VSExtension.Helpers.AssemblyHelper.ExecuteCode(String code, String namespacename, String classname, Boolean isstatic) in C:\Projects\Dapper.Crud.Extension\Dapper.Crud.VSExtension\Helpers\AssemblyHelper.cs:line 57
at Dapper.Crud.VSExtension.Helpers.ModelHelper.Generate(String[] content, String rawContent, String model) in C:\Projects\Dapper.Crud.Extension\Dapper.Crud.VSExtension\Helpers\ModelHelper.cs:line 10
at Dapper.Crud.VSExtension.frmExtension.GetPropertyInfos(String model) in C:\Projects\Dapper.Crud.Extension\Dapper.Crud.VSExtension\frmExtension.cs:line 277
at Dapper.Crud.VSExtension.frmExtension.GenerateCrud() in C:\Projects\Dapper.Crud.Extension\Dapper.Crud.VSExtension\frmExtension.cs:line 73

from dapper.crud.extension.

thiagoloureiro avatar thiagoloureiro commented on July 22, 2024

Hi, thanks for your input. Can you make sure that the file has the same name as the Class?

image

I have attached also the project that I tested, can you try to run locally in your environment and see what happens, please?

ClassLibrary1.zip

from dapper.crud.extension.

Related Issues (17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.