上一页 1 ··· 5 6 7 8 9 10 11 12 13 下一页
方法一,使用扩展类型 tableName。方法二,使用函数 PickTable(),参考下面的job(可以直接运行)。 1 static void GetSelectedTable(Args _args) 2 { 3 tableid a; 4 ; 5 6 a = pickTable(); 7 print 'Table ID is:'+int2str(a); 8 print 'Table Name is:'+tableID2Name(a); 9 pause;10 } Read More
posted @ 2012-08-30 10:57 Sprite.z Views(159) Comments(0) Diggs(0) Edit
1 static void ExportImageToExcel(Args _args) 2 { 3 container ImaPos; 4 COM comWorksheet; 5 COM comShapes; 6 COM comCells; 7 COM comFont; 8 COM comPageSetup; 9 SysExcelWorksheet sheet;10 SysExcelApplication excel;11 SysExcelWorkbooks boo... Read More
posted @ 2012-08-30 10:56 Sprite.z Views(336) Comments(0) Diggs(0) Edit
1 static void FindPrimaryIdx(Args _args) 2 { 3 DictTable dt; 4 DictIndex di; 5 Common cm; 6 IndexID idx; 7 int i, iCnt; 8 FieldID fid; 9 FieldID fids[,10];10 int fidsCnt = 0;11 str ... Read More
posted @ 2012-08-30 10:55 Sprite.z Views(234) Comments(0) Diggs(0) Edit
1 void startupPost() 2 { 3 int counter; 4 int num = 0; 5 int maxSessions = Info::licensedUsersTotal(); 6 xSession session; 7 UserInfo userInfo; 8 UserId currentUserId; 9 ;10 11 currentUserId = curuserid();12 13 for(counter = 1; ... Read More
posted @ 2012-08-30 10:52 Sprite.z Views(206) Comments(0) Diggs(0) Edit
1 static str Num2ChnStr(real realNum) 2 { 3 real y; 4 int b, a; 5 str je, x, hz1, hz2, e, h, f, m; 6 boolean IsNegative=false; 7 ; 8 if (realNum == 0) 9 return '零圆';10 if (realNum < 0)11 {12 realNum =... Read More
posted @ 2012-08-30 10:49 Sprite.z Views(409) Comments(0) Diggs(0) Edit
As we talk before, AX has no support with sigleton instance modle, but we can use the global cache insteaded.1、Create the global cache.1 SysGlobalCache globalCache;2 ;3 4 globalCache = ClassFactory.globalCache(); //全局缓存,客户端和服务端都可以用,但依赖调用方5 globalCache = Appl.globalCache(); //全局缓存,客户端和服务端都可以用,... Read More
posted @ 2012-08-30 10:38 Sprite.z Views(226) Comments(0) Diggs(0) Edit
1 static void dialog(Args _args) 2 { 3 Dialog dialog = new Dialog("Test dialog!"); //标题 4 DialogField dialogField1 = dialog.addField(typeid(ItemId),"Item Name"); //设置字段 5 DialogField dialogField2 = dialog.addField(typeid(noYes),"Update?"); 6 Dial... Read More
posted @ 2012-08-30 10:02 Sprite.z Views(195) Comments(0) Diggs(0) Edit
在AX中,我们很容易发现很多子窗口都通过一个“MenuItem”并绑定数据源,就可以完成数据的自动绑定了。其实细节是由“MenuItem”封装好了,我们也可以通过代码实现。 1 static void activateWindow(Args _args) 2 { 3 FormRun fr; 4 Args args = new Args(); 5 CustTable CustTable = CustTable::find("WIB-CHN"); //记录行,如果是母窗口数据源,则实现绑定 6 ; 7 args.name(formstr(Cu... Read More
posted @ 2012-08-30 09:59 Sprite.z Views(205) Comments(0) Diggs(0) Edit
1、系统自带储存过程。 1 exec sp_databases; --查看数据库 2 exec sp_tables; --查看表 3 exec sp_columns student;--查看列 4 exec sp_helpIndex student;--查看索引 5 exec sp_helpConstraint student;--约束 6 exec sp_stored_procedures; 7 exec sp_helptext 'sp_stored_procedures';--查看存储过程创建、定义语句 8 exec sp_rename student, stuInfo;- Read More
posted @ 2012-08-28 14:49 Sprite.z Views(833) Comments(0) Diggs(0) Edit
1 void ViewCrystalReport() 2 { 3 Com comapp; 4 Com reporting; 5 str paramwhole; 6 str paramfilename; 7 str paramCond; 8 str ViewYesNo; 9 int ret; 10 COMVariant variant; 11 12 ; 13 14 variant = new COMvariant(COMVariantInOut::OUT,COMVariantType::VT_BOOL) ; 15 paramwhole... Read More
posted @ 2012-08-28 11:32 Sprite.z Views(248) Comments(0) Diggs(0) Edit
上一页 1 ··· 5 6 7 8 9 10 11 12 13 下一页