axapta

How to get file in folder in batch process?

被刻印的时光 ゝ 提交于 2020-01-17 04:59:26
问题 I have to get file in a folder. My process can work in Batch . My code is this: Io file; FileIoPermission perm; int handle; Filename fileName; [handle, filename] = WINAPI::findFirstFile( myFilePatch + "\\*.txt"); fileOpen = strFmt (myFilePatch + "\\" + filename); if (filename) { perm = new FileIoPermission(filename, 'r'); perm.assert(); file = new TextIo(filename, 'r', 65001); } //etc... other code // I go on to find another file filename = WinAPI::findNextFile(handle); fileOpen = strFmt

Report development, totalPages() Method

China☆狼群 提交于 2020-01-17 04:10:06
问题 Is it possible to reset the value returned by totalPages() method of reportRun class? I have one report populated with several invoices, I want to reset the totalPages() value for each fetched invoice. I tried to use element.reset() in the fetch() method of my report and it doesn't work, it splits my report by invoices. 回答1: No, it is not possible. The reset method does the trick, but splits the report as you observed. And unless your lines exactly fit one line there is no way to precalculate

How to refresh form when I open?

别说谁变了你拦得住时间么 提交于 2020-01-16 07:41:22
问题 I have a CheckBox in my TabPage on my Form, if I select the checkBox, the value is saved in a Table field (present in my FormDataSource: ParametersTable). I want to refresh the form when I enter in TabPage, just Like pressing F5. Is it possible? 回答1: There is a great article about different methods of refreshing the form's data here. Here are the basic outline: 1. Refresh This method basically refreshes the data displayed in the form controls with whatever is stored in the form cache for that

Microsoft Dynamics AX - Resources for new developers

╄→尐↘猪︶ㄣ 提交于 2020-01-13 19:28:07
问题 I am trying to find some good resources that will help me understand how to use the .NET Business Connector and without digging too deep into X++ and those other AX-specific things. First of all I want a bit more knowledge regarding the very AX usage basics and after that I want to head on to the AX for .NET developers. So, suggestions on books and resources for this? 回答1: I can give you some links. Remember to google both AX and the former name Axapta. AX in general: http://www.axaptapedia

How do you find a user's last used printer in SysLastValue

眉间皱痕 提交于 2020-01-13 06:39:10
问题 I've been trying to find where a user's last used printer is stored so that I can clear this usage data (as a few users have an issue where the remembered printer keeps defaulting to the XPS writer, despite us having KB981681 installed & the printer being available; just not defaulted on certain AX forms). I know this data's somewhere in the Usage Data, which I can browse via AX: Microsoft Dynamics AX > Tools > Development Tools > Application Objects > Usage Data AOT > System Documentation >

Table Update Event Handler

梦想的初衷 提交于 2020-01-13 01:55:25
问题 I am investigating the capabilities of the new delegate & event subscription pattern in AX 2012. At the moment I am looking to detect when a particular field has been modified, for example when SalesTable.SalesStatus is changed to SalesStatus::Invoiced . I have created the following post-event handler and attatched to the SalesTable.Update method; public static void SalesTable_UpdatePosteventHandler(XppPrePostArgs _args) { Info("Sales Update Event Handler"); } Now I know I can get the

Table Update Event Handler

点点圈 提交于 2020-01-13 01:55:14
问题 I am investigating the capabilities of the new delegate & event subscription pattern in AX 2012. At the moment I am looking to detect when a particular field has been modified, for example when SalesTable.SalesStatus is changed to SalesStatus::Invoiced . I have created the following post-event handler and attatched to the SalesTable.Update method; public static void SalesTable_UpdatePosteventHandler(XppPrePostArgs _args) { Info("Sales Update Event Handler"); } Now I know I can get the

Nested notExists joins X++ (Dynamics AX3.0)

十年热恋 提交于 2020-01-12 10:52:46
问题 When the following code executes: select sum(qty) from inventTrans index hint TransTypeIdx where inventTrans.ItemId == itemId && inventTrans.TransType == InventTransType::Sales && inventTrans.InventDimId == inventDimId notExists join custTable where custTable.AccountNum == inventTrans.CustVendAC && custTable.CustGroup == custGroupId notExists join salesTable where salesTable.SalesId == inventTrans.TransRefId && salesTable.Extraordinary == NoYes::Yes; The sql generated nests the second

Nested notExists joins X++ (Dynamics AX3.0)

|▌冷眼眸甩不掉的悲伤 提交于 2020-01-12 10:52:14
问题 When the following code executes: select sum(qty) from inventTrans index hint TransTypeIdx where inventTrans.ItemId == itemId && inventTrans.TransType == InventTransType::Sales && inventTrans.InventDimId == inventDimId notExists join custTable where custTable.AccountNum == inventTrans.CustVendAC && custTable.CustGroup == custGroupId notExists join salesTable where salesTable.SalesId == inventTrans.TransRefId && salesTable.Extraordinary == NoYes::Yes; The sql generated nests the second

Update records that can be retrieved by multiple joins in x++

时间秒杀一切 提交于 2020-01-11 14:28:29
问题 So I have a complete x++ script that aims to update records based on the retrieved result set made with select query with multiple joins and using crosscompany As I have been told, it is not a good idea to update records when there is crosscompany. Can you give expert advice on how to do it the best practice way considering my current script. here is the script static void UpdateSample(Args _args) { InventTable a; InventTableModule b; EcoResProduct c; EcoResProductCategory d; EcoResCategory e