惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

D
Darknet – Hacking Tools, Hacker News & Cyber Security
Jina AI
Jina AI
博客园_首页
J
Java Code Geeks
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - 司徒正美
Hugging Face - Blog
Hugging Face - Blog
S
SegmentFault 最新的问题
MyScale Blog
MyScale Blog
P
Proofpoint News Feed
L
Lohrmann on Cybersecurity
Forbes - Security
Forbes - Security
大猫的无限游戏
大猫的无限游戏
Vercel News
Vercel News
Y
Y Combinator Blog
Google DeepMind News
Google DeepMind News
The Register - Security
The Register - Security
N
News | PayPal Newsroom
S
Security Archives - TechRepublic
量子位
Cisco Talos Blog
Cisco Talos Blog
V
V2EX
C
Cisco Blogs
The Cloudflare Blog
Stack Overflow Blog
Stack Overflow Blog
L
LangChain Blog
Scott Helme
Scott Helme
S
Securelist
Security Latest
Security Latest
爱范儿
爱范儿
TaoSecurity Blog
TaoSecurity Blog
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
I
Intezer
L
LINUX DO - 最新话题
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
C
Check Point Blog
C
CXSECURITY Database RSS Feed - CXSecurity.com
美团技术团队
Know Your Adversary
Know Your Adversary
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
PCI Perspectives
PCI Perspectives
月光博客
月光博客
T
Tailwind CSS Blog
Cloudbric
Cloudbric
小众软件
小众软件
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
K
Kaspersky official blog
D
DataBreaches.Net
博客园 - 【当耐特】
有赞技术团队
有赞技术团队

博客园 - zhanqiangz(闲云野鹤)

在ReportService2005.asmx 找不到 ReportingService2005 类 BizTalk相关的问题,打算持续更新。 恢复被格式化过的硬盘数据 BizTalk - Most possible reason for “is Delimiters are not unique” in EDI transaction What happens if BizTalk artifacts are not GACed? XmlSerializer is not trustable BizTalk - Carefully use Send Port Group BizTalk - How to debug map in VS2005 BizTalk-Get to know functoid. BizTalk - String Functoids 一辈子都忘不了的七夕节 Head First Design patterns笔记-Singleton patterns (从“一夫一妻制社会中婚约的达成”看单件模式) Global.asax文件里的Application_Init能触发吗? 使用HttpApplication实例(翻译) Head First Design patterns笔记-Decorator Patterns (从”用不同技能武装自己”看装饰模式) Head First Design patterns笔记-Observer Patterns (从TFS的Project alerts功能看观察者模式) ASP.NET 2.0的编译行为 Head First Design patterns笔记-Strategy Patterns (从不同的人使用不同的交通工具上班看策略模式) 晕菜了,TFS居然把vss里的那个rollback功能cut掉了,还好有人写了工具.
BizTalk - How to create custom functoid.
zhanqiangz(闲云野鹤) · 2008-05-29 · via 博客园 - zhanqiangz(闲云野鹤)

Functoid is no more than a piece of .Net code, find my another post BizTalk-Get to know functoid for more detail. The functoids coming with BizTalk do not always satisfy your needs. How to create our own custom functoid? In this article, I want to create a functoid which get current date/date time based on given format.

1. All functoids are derived from BaseFunctoid class which is built in Microsoft.BizTalk.BaseFunctoids.dll, it can be found under <BizTalk Installation Path>\Developer Tools.

2. BizTalk artifacts are required to be deployed in GAC, that’s to say they are strong named assemblies, we need a snk file. You can create a snk file by running sn –k sn.snk visual studio command prompt window.

3. Coding time now! Let’s create a c# class project called FunctoidDemo, include sn.snk in this project and add reference to Microsoft.BizTalk.BaseFunctoids.dll.

4. In this step we add a resource file to FunctoidDemo solution. BaseFunctoid is designed to store some settings in resource file such as functoid name, tooltip, tool description, so all derived functoid class should also have its related resource file.

 

5. The real c# code is pretty simple.

Code

6. Register FunctoidDemo.dll go GAC by running GacUtil -I FunctoidDemo.dll.

7. Copy FunctoidDemo.dll to <BizTalk Installation Path>\Developer Tools\Mapper Extensions, If you skip this step, you will get an error like this.

 

8. Add this custom functoid to tool box. NOTE: FormattedDate is the class name, it is different from assembly name.

 

9. Now add a BizTalk project to current solution for testing purpose.

 

I keep the map very simple for easy testing. The selected functoid is my custom functoid, the icon looks a little bit ugly. J I did not dray anything, just a white square, a beautiful icon does not help anything from technical perspective.

 

10. Specify the input parameter as yyyyMMdd, I want to use this pattern to format current date time.

 

11. Now I test the map with automatically generated sample file, see the output data.

 

The checkInTime is formatted as 20080529.

12. Source code download.

I will explain the structure of BaseFunctoid class in detail later.
Hope it helps!