ax 2012批处理不运行问题

最近在开发12的批处理,可是很奇怪全部的都配置好了就是不跑批处理,假如你也出现了那用下面的方法试试:服务器

12的批处理和09不同,不是运行x++代码,并且运行你CIL生成的DLL文件,spa

 

 

1.你必须让你的批处理运行在服务器端(假如是设置定时跑,不是手动运行批处理的话),方法以下,orm

public boolean runsImpersonated()
{
  return true;
}server

 

2.你在批处理里面调用系统的类,必须也是运行在服务器端,例如假如调用过帐类blog

server static PurchFormLetter cec_construct(
DocumentStatus _document,
IdentifierName _className = '',
IdentifierName _methodName = '',
SysOperationExecutionMode _executionMode = SysOperationExecutionMode::Synchronous,
MenuItemNameAction _callerMenuItem = '')
{ip

  ***和系统相同开发

io

 

编译

purchFormLetter = PurchFormLetter::cec_construct(DocumentStatus::PackingSlip);
purchFormLetter.update(purchTable,
  packingSlipId,
  str2Date(cec_purchTable.ShippingDateRequested, 321),
  PurchUpdate::ReceiveNow,
  AccountOrder::None,
  Noyes::No,
  NoYes::No);
class

 

3.批处理写好以后,必须运行编译.NET Framework CIL,以下:

 

4.运行批处理的用户设置必须以下:

 

 这样就能够运行批处理了。

相关文章
相关标签/搜索