警报编辑器UI的错误 - 将Int转换为String [英] Bug With Alerts Editor UI - Converting Int to String

查看:122
本文介绍了警报编辑器UI的错误 - 将Int转换为String的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

创建"特定工作项目已更改"时使用October08 Power Tools随附的警报编辑器生成以下表达式:

"CoreFields / IntegerFields / Field [ReferenceName ='System.Id'] / NewValue" = '2113'

UI自动将整数2113转换为字符串'2113',这会在此帖子末尾显示的服务事件日志中导致以下错误

如果通过右键单击查询视图中的工作项并选择"当此工作项更改时通知我"来创建警报,则会生成正确的过滤器表达式

" CoreFields / IntegerFields /领域引用名称= 'System.Id'] /&的NewValue QUOT; = 2113

这个bug可以修复吗?

= =================== =========================
事件日志错误消息
============= ===============================

TF53010:发生以下错误在Team Foundation组件或扩展中:
日期(UTC):3/05/2009 11:40:03 pm
机器:STNZ-TEAM
应用领域:/ LM / W3SVC / 260119026 / Root / Services-2-128857951960398157
Assembly:Microsoft.TeamFoundation.Server,Version = 9.0.0.0,Culture = neutral,PublicKeyToken = b03f5f7f11d50a3a; v2.0.50727
制造细节:
制造商名称:w3wp
制程编号:5856
线程编号:388
帐户名称:NT AUTHORITY \ NETWORK SERVICE

详细消息:TF50285:异常匹配订阅:Microsoft.TeamFoundation.Server.SubscriptionOnServer:System.InvalidCastException:无法将类型为"System.Int32"的对象强制转换为"System.String"。
at Microsoft.TeamFoundation.Server.StringFieldCondition.EvaluateOneValue(Object fieldValue)
在Microsoft.TeamFoundation.Server.FieldCondition.Evaluate(IFieldContainer be)
在Microsoft.TeamFoundation.Server.NotificationCenter.Notify(EventOnServer e)
异常消息:无法将类型为"System.Int32"的对象强制转换为"System.String"。 (输入InvalidCastException)

异常堆栈跟踪:在Microsoft.TeamFoundation.Server.StringFieldCondition.EvaluateOneValue(Object fieldValue)
在Microsoft.TeamFoundation.Server.FieldCondition.Evaluate(IFieldContainer) be)at Microsoft.TeamFoundation.Server.NotificationCenter.Notify(EventOnServer e)


有关详细信息,请参阅http://上的"帮助和支持中心" go.microsoft.com/fwlink/events.asp。

When Creating "Specific Work Item Changed" alert using the alerts editor that comes with October08 Power Tools the following expression is generated:

"CoreFields/IntegerFields/Field[ReferenceName='System.Id']/NewValue" = '2113'

The UI automatically converts the integer 2113 to a string '2113' which causes the following error on the serves event log shown at the end of this post

If the alert is created via right clicking on the work item  in a query view and selecting  "Notify my when this Work Item changes", the correct filter expression is generated

"CoreFields/IntegerFields/Field[ReferenceName='System.Id']/NewValue" = 2113

Can this bug be fixed?

============================================
Event log error Message
============================================


TF53010: The following error has occurred in a Team Foundation component or extension:
Date (UTC): 3/05/2009 11:40:03 p.m.
Machine: STNZ-TEAM
Application Domain: /LM/W3SVC/260119026/Root/Services-2-128857951960398157
Assembly: Microsoft.TeamFoundation.Server, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a; v2.0.50727
Process Details:
  Process Name: w3wp
  Process Id: 5856
  Thread Id: 388
  Account name: NT AUTHORITY\NETWORK SERVICE

Detailed Message: TF50285: Exception matching subscription: Microsoft.TeamFoundation.Server.SubscriptionOnServer: System.InvalidCastException: Unable to cast object of type 'System.Int32' to type 'System.String'.
   at Microsoft.TeamFoundation.Server.StringFieldCondition.EvaluateOneValue(Object fieldValue)
   at Microsoft.TeamFoundation.Server.FieldCondition.Evaluate(IFieldContainer be)
   at Microsoft.TeamFoundation.Server.NotificationCenter.Notify(EventOnServer e)
Exception Message: Unable to cast object of type 'System.Int32' to type 'System.String'. (type InvalidCastException)

Exception Stack Trace:    at Microsoft.TeamFoundation.Server.StringFieldCondition.EvaluateOneValue(Object fieldValue)
   at Microsoft.TeamFoundation.Server.FieldCondition.Evaluate(IFieldContainer be)
   at Microsoft.TeamFoundation.Server.NotificationCenter.Notify(EventOnServer e)



For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

推荐答案

是的,这可以修复。

看到这篇文章:
http://social.msdn.microsoft.com/Forums/en-US/tfsworkitemtracking/thread/29bf269b-a027-4b64-a4b2-47e05aac03d7
详情。

它主要涉及手动更改已安装的.XSD文件之一。

简单,相对无痛。

Yes, this can be fixed.

See this post:
http://social.msdn.microsoft.com/Forums/en-US/tfsworkitemtracking/thread/29bf269b-a027-4b64-a4b2-47e05aac03d7
for details.

It basically involves making a manual change to one of the installed .XSD files.

Simple, relatively painless.


这篇关于警报编辑器UI的错误 - 将Int转换为String的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆