简体   繁体   English

如何将名称空间添加到Model MVC

[英]How to add namespace into Model MVC

I created folder "App_Code" in my project, with simple class 我在项目中使用简单的类创建了文件夹“ App_Code”

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace Tools
{

    public static class TextTools
    {
        public static void GenerateHash(string str, int user)
        { 

        }
    }
}

My question is: How can I add this namespace "Tools" with all classes and methods to my project? 我的问题是:如何将带有所有类和方法的名称空间“工具”添加到项目中? I tried to insert using Tools; 我尝试using Tools;插入using Tools; in my AccountModels.cs but it isn't working. 在我的AccountModels.cs中,但是它不起作用。

Regards 问候

您可能需要在参考中添加“工具”

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM