软件下载吧文章资讯

分类分类

Sql Server 数据库中如何调用dll文件的过程

2024-03-26 14:33作者:下载吧

1.首先新建一个空的解决方案,并添加一个类库,代码如下,编译并生产dll

using System;
using System.Collections.Generic;
using System.Data.SqlTypes;
using System.Linq;
using System.Text;
namespace TEST
{
public class TestTrans
{
[Microsoft.SqlServer.Server.SqlFunction]
public static SqlString GenerateDecryptString(string name)
{
string decode = string.Empty;
decode = string.Format(“HELLO WORLD {0}!”, name);//DecryptString(dataXML.Value);
SqlString sqlValue = new SqlString(decode);
return sqlValue;
}
}
}

展开全部

相关文章

说两句网友评论
    我要跟贴
    取消