|
发表于 2007-2-1 10:33:37
|
显示全部楼层
楼主,2424升级到2617没有对系统初始化功能作修改。
你升级后,需要重新修改一下系统初始化功能中的TCreateFunc.Invoke方法的实现部分。
function TCreateFunc.Invoke(var Params: array of object): object;
const
cInitFunc = 'Biz:\YYCSKJ\TIEFuncContainer.Func';
cUserNameIndex = 'UserName';
cPasswordIndex = 'Password';
cPositionIDIndex = 'Position';
var
FuncItem: TOperatorFuncItem;
lFunc: TFunc;
lFuncURL, lUserName, lPassword, lPositionID: string;
lStrings: TStrings;
I: integer;
begin
if Params.Length >1 then
begin
lFuncURL := System.String(Params[0]);
lStrings := TStringList.Create;
try
lStrings.Delimiter := ';';
lStrings.DelimitedText := System.String(Params[1]);
lUserName := lStrings.Values[cUserNameIndex];
lPassword := lStrings.Values[cPasswordIndex];
lPositionID := lStrings.Values[cPositionIDIndex];
finally
lStrings.Free;
end;
end else
raise Exception.Create('参数不够!');
lFunc := TSystemCore.FuncManager.CreateFunc(BizSys.GlobalContext, cInitFunc);
//Assert(lFunc <> nil, '无法创建TFunc');
if lFunc = nil then
raise Exception.Create('无法创建TFunc');
TIEFuncContainer.TTIEFuncContainer(lFunc).RunFuncURL := lFuncURL;
TIEFuncContainer.TTIEFuncContainer(lFunc).UserName := lUserName;
TIEFuncContainer.TTIEFuncContainer(lFunc).Password := lPassword;
TIEFuncContainer.TTIEFuncContainer(lFunc).PositionID := lPositionID;
Result := lFunc;
end; |
|