Quantcast
Channel: Microsoft Dynamics AX Forum - Recent Threads
Viewing all 46681 articles
Browse latest View live

Expand My favourites every time

$
0
0

Hello,

I have added some forms to My favorites however when I change the module My favorites get collapse. 

Is there any way to make it expanded by default through code?


PR WF - How to skip one person in the hierarchy approval?

$
0
0

Hi All, 

Currently, I'm mapping the position's report-to in this order: Purchaser-->Manager-->VP-->COO.  Right now, there is no Director, but in the future, they may have a Director.  How do I tell the system that, in this department, if there is no Director, skip and move to the next approver in the hierarchy?  Where, in AX, can I do this setup? 

Master planning setup

$
0
0

I only want to set this up by site not sure and warehouse can sOmeone let me know proper setup that is needed? 

Send request and get response process not working in D365FO

$
0
0

Hi All,

Environment :D365FO'

While trying in send request and get response in POST MAN its working good.

but When Using below code for send request and get response process its not working getting below error .Any one please help on this.

The remote server returned an error: (403) Forbidden.

System.Net.HttpWebRequest request;

System.Net.HttpWebResponse response;

CLRObject clrObj;

System.Exception ex;

System.Net.WebHeaderCollection httpHeader;

System.IO.Stream requestStream, responseStream;

System.IO.StreamWriter streamWriter;

int IDValue;

str SKUValue;

Map data;

str result;

try

{

new InteropPermission(InteropKind::ClrInterop).assert();

clrObj = System.Net.WebRequest::Create("URL");

request = clrObj;

request.Method = "GET";

response = request.GetResponse();

System.IO.StreamReader streamRead = new System.IO.StreamReader(response.GetResponseStream());

str responseJson = streamRead.ReadToEnd();

data = RetailCommonWebAPI::getMapFromJsonString(responseJson);

result = data.lookup("result");

info("Token response = " + responseJson);

//Token Class

httpHeader = new System.Net.WebHeaderCollection();

clrObj = System.Net.WebRequest::Create("request Other URL");

request = clrObj;

request.set_KeepAlive(true); // adding headers

httpHeader.Add("Authorization", "Bearer " + result);

request.set_Headers(httpHeader);

request.Method = "POST";

request.ContentType = "application/json";

requestStream = request.GetRequestStream();

streamWriter = new System.IO.StreamWriter(request.GetRequestStream());

// streamWriter.Write("[" + jsonString + "]");

streamWriter.Flush();

streamWriter.Close();

response = request.GetResponse();

streamRead = new System.IO.StreamReader(response.GetResponseStream());

info(streamRead.ReadToEnd());

}

catch

{

//exception

ex = CLRInterop::getLastException().GetBaseException();

error(ex.get_Message());

}

 

How to get single entry from General Journal Account Entry table when joining with CustTeans using Vouchdr

$
0
0

Hi 

I am trying to join the General Journal Account Entry with Custtrans using the Voucher field. 

Select T1.*, T2.*

GeneralJournalAccountEntry T1,  CustTrans T2 

Where T1.Voucher = T2.Voucher.

But I am getting a lot of nulls on the AR front (data from CustTrans) after joining. 

Could you please assist me with correct join. Also the possible reasons to the nulls.

Error "The referred item is not of full visibility, therefore shipment can only be made at status "picked"." when pick Sales order by code

$
0
0

Hello everyone,

I want to ask something, I have code to pick sales order and packing slip sales order. When use item catch weight I always have error like this

The referred item is not of full visibility, therefore shipment can only be made at status "picked".
To resolve this issue, go to the order lines -> Inventory -> Pick to pick sufficient amount to issue.
Insufficient inventory transactions with status Picked.
But if I use an item that is not a catch weight there is no error. this is my code
private void createPickReserverSOline(salesline salesln, SalesQty   qty)
    {
        Query inventTransQuery;
        QueryRun qr;
        QueryBuildDataSource qbds;
        InventTrans inventTrans = null;
        InventDim inventDimPick = null;
        InventTransOrigin inventTransOrigin = null;
        TmpInventTransWMS tmpInventTransWMS = null;
        InventTransWMS_Pick inventTransWMS_Pick = null;

        inventTransQuery = new Query();
        qbds = inventTransQuery.addDataSource(tableNum(InventTrans));
        qbds.addRange(fieldNum(InventTrans, StatusIssue)).value(queryValue(StatusIssue::OnOrder));
        qbds.addRange(fieldNum(InventTrans, StatusReceipt)).value(queryValue(StatusReceipt::None));
        qbds = qbds.addDataSource(tableNum(InventTransOrigin));
        qbds.relations(true);
        qbds.joinMode(JoinMode::InnerJoin);
        qbds.addRange(fieldNum(InventTransOrigin, InventTransId)).value(salesln.InventTransId);
    
        qr = new QueryRun(inventTransQuery);
        while (qr.next())
        {
            inventTrans = qr.get(tableNum(InventTrans));
            inventTransOrigin = qr.get(tableNum(InventTransOrigin));
        
            // Set inventory dimensions for picking
            inventDimPick = inventDim::find(salesln.InventDimId);
            inventDimPick = inventDim::findOrCreate(inventDimPick);
        
            tmpInventTransWMS.clear();
        
            inventTransWMS_Pick = InventTransWMS_Pick::newStandard(tmpInventTransWMS, inventTransQuery);
            tmpInventTransWMS.initInventDimId(inventTrans.InventDimId);
            tmpInventTransWMS.UnitId            = inventTrans.inventUnit();
            tmpInventTransWMS.InventTrans       = inventTrans.RecId;
            tmpInventTransWMS.InventTransOrigin = inventTrans.InventTransOrigin;
            tmpInventTransWMS.initInventQty(PdsCatchWeight::inventQty(InventTrans.ItemId, salesParmLine.PdsCWDeliverNow, InventTableModule::find(InventTrans.ItemId, ModuleInventPurchSales::Sales).UnitId),inventTrans.StatusReceipt,inventTrans.StatusIssue);
            tmpInventTransWMS.initPdsCWQty(salesParmLine.PdsCWDeliverNow,inventTrans.StatusReceipt,inventTrans.StatusIssue);

            tmpInventTransWMS.PDSBaseValue = inventTrans.pdsGetPotencyValue();
            //tmpInventTransWMS.initFromInventTrans(InventTrans);
            tmpInventTransWMS.initFromInventTransOrigin(inventTransOrigin);
            tmpInventTransWMS.initFromInventDim(inventDimPick);
            tmpInventTransWMS.ItemId    = InventTrans.ItemId;
            tmpInventTransWMS.UnitId    = InventTableModule::find(InventTrans.ItemId, ModuleInventPurchSales::Sales).UnitId;
            tmpInventTransWMS.PdsCWQty  = salesParmLine.DeliverNow;
            tmpInventTransWMS.InventQty = PdsCatchWeight::inventQty(InventTrans.ItemId, salesParmLine.PdsCWDeliverNow, InventTableModule::find(InventTrans.ItemId, ModuleInventPurchSales::Sales).UnitId);
            inventTransWMS_Pick.writeTmpInventTransWMS(tmpInventTransWMS);
            inventTransWMS_Pick.updateInvent();
        }
    }
Anybody help me? Im sorry for my bad english.
Thanks

enable grid filter in lookup form

$
0
0

Hi,

I have a grid with a field which contains ITEMID field. This field has a lookup button. When we press it, we popup a lookup form. I guess this is dynamic lookup form and I didn't find any place where it is referenced. So I guess it is something concerning EDT. The point is each time this lookup up appears I must enabled grid filter (CTRL G).  I wonder if exists a way to enable them by default or by x++ in lookup method of the control which contains this lookup.

thank you

multiple records select in grid (not manual) through code in AX 2009

$
0
0

hi All,

AX 2009

In ledger settlement form, when user select multiple records MANUALLY and clicked on Include button then as per standard functionality those line appeared in BELOW GRID as below

But user wants this process to AUTOMATE. So, i have added MARK check box in Ledger Trans table and marked the voucher based on excel template. That i have done through Import  voucher button clicked. Which voucher is matched with excel that voucher get mark = YES. It's working fine.

But when i clicked on INCLUDE button it's only insert SINGLE VOUCHER (FAQ-007702) in BELOW GRID as below. I expect to get voucher FAQ-007702, FAQ-007706, FAQ-007709

CODE : Include button > Clicked method >

void clicked()
{
    LedgerTrans ledgerTransLocal;
    ;
    ttsbegin;
    ledgerTransLocal.recordLevelSecurity(true);
    for (ledgerTransLocal = ledgerTrans_ds.getFirst(true) ? ledgerTrans_ds.getFirst(true) : ledgerTrans;
         ledgerTransLocal;
         ledgerTransLocal = ledgerTrans_ds.getNext())
    {
        element.includeTrans(ledgerTransLocal);
    }
    ttscommit;

    tmpLedgerTrans_ds.research();
    ledgerTrans_ds.next();
}


IncludeTrans() --

void includeTrans(LedgerTrans   _ledgerTrans)
{
    ;
    if (!mapTrans2TmpTrans.exists(_ledgerTrans.RecId))
    {
        tmpLedgerTrans.data(_ledgerTrans);
        tmpLedgerTrans.doInsert();

        mapTrans2TmpTrans.insert(_ledgerTrans.RecId,    tmpLedgerTrans.RecId);
        mapTmpTrans2Trans.insert(tmpLedgerTrans.RecId,  _ledgerTrans.RecId);

        balanceAmountMST += _ledgerTrans.AmountMST;
    }
}

Kindly let me know how will achieve this ?

Please give me more shed on this.


E-Invoicing Saudi Arabia

$
0
0

Hi Experts,

Do you know any update about  E-Invoicing patch. Because Saudi are going to implement  E-Invoicing .

Thanks,

Faiz

Upload of 'Name' failed. An error occurred writing to Azure storage.

$
0
0

Hello, 

We have a cloud-hosted environment that uploads attachments into azure blob storage.

I made a new SAS and a new access key and ever since I'm facing that error on my form that uploads attachments.

how do I fix it? 

GDPdU problems

$
0
0

Hi 

I try to run GDPdU export for the first time and do have following issues:

1. Import never ends (Form "Export data" hangs for 24 hours know)

2. I set timeslot from 01.01.2016. to 31.12.2016 but generated File "GeneralLedgerTransactions.txt" shows values from 2017, 2018,...

3. now index.html file is created

Question1. do I have to run the export for each defined table on its own or can I run the export for all defined tables at once

Question2: any suggestions about the problems above?

How to change workflow approver as per customized field

$
0
0

Dear All,

I have requirement in workflow .I have created custom workflow in prospect creation under sales and marketing module .my requirement is i have created one more field in prospects that is workflow approver. that field will holds HCMWORKER employee details. Basically when we submit to workflow, approval will happen based on workflow configuration.in my case approval should happen based in my customized field, which means  in prospects creation ill select workflow approver then my workflow should go to particular user only for approve ....how we can do this?

thanks in advance.

Account Receivable Module Tick All Items Option

$
0
0

Quick question - does anyone know for Microsoft Dynamic AX's account receivable module, is there a box to tick which can automatically select ALL items/invoices on the list on screen? It appears that we can only MANUALLY select each item on the list one by one which is too time consuming if there are thousands of items to be selected. Kindly advise. My e-mail is sokambo@gmail.com 

Look forward to urgent feedback. Thank you!

How to create .xpo file of a report in Microsoft Dynamics AX 2012?

$
0
0

There is an urgent need of an answer about how to create .xpo file of a report after deployment. Quick answer will be appreciated.

MRP Calculation and ReqTrans table cleanup


Stockout warning message

$
0
0

I would like to ask sometime when I create an Order confirmation, sometime didn't pop stockout warning message.  Did I miss something for the item creation.  

How to change tracking dimension group for item after its released and transaction are recorded

$
0
0

Hi,

I need to change the tracking dimension for few items but the items are already released and transactions are recorded to that ..

any possibility to change it 

Crystal reports ActiveX - change DSN properties from code

$
0
0

I am using following code to run crystal report in activex control of crystal report in dynamics ax. every thing is working fine when In crystal report the value of "Use DSN Default Properties" is set to False. But I want to change its value from coding. I am stucked how can i change it from code. It is giving me error. on this line.

IConnectionProperty = INameValuePairs.add("Use DSN Default Properties",False);

Error:

Method 'add' in COM object of class 'INameValuePairs' returned error code 0x80070057 (E_INVALIDARG) which means: One or more arguments are invalid.

My code starts here;

public void run()
{
Com comapp;
Com reporting;
Com IDatabase;
Com IDatabaseTable;
Com IDatabaseSingleTable;
Com INameValuePairs;
Com INameValuePairs2;
Com INameValuePairs3;
COM tc;
COM IConnectionProperty2;

Com IConnectionProperty;
Com ds;
COM DLL_Name;
str paramwhole;
str paramfilename;
str paramCond;
str ViewYesNo;
int ret;
str selectionFormula;
COMVariant variant;

DialogButton diagBut;
str strMessage;
str strTitle;
;

super();

variant = new COMvariant(COMVariantInOut::OUT,COMVariantType::VT_BOOL) ;
//paramwhole = this.args().parm("'{Employee.empcode}'='11752'");
paramwhole = this.args().parm();
//paramwhole = this.args().parm("{Employee.empcode}='11752'");
//paramwhole = this.args().parm("{?DateFrom}='01/01/2021';{?DateTo}='03/03/2021';{Employee.empcode}='11752'");

comapp = new COM("CrystalRuntime.Application.11");
ret = strfind(paramwhole,"|",2,strlen(paramwhole));

//paramfilename = "e:\\rptTimeSheet.rpt"; //substr(paramwhole,2,ret-2) ;
paramfilename = "e:\\Report10.rpt"; //substr(paramwhole,2,ret-2) ;
ViewYesNo = substr(paramwhole,1,1);
reporting = comapp.openreport(paramfilename);

reporting.discardsaveddata();


comapp.LogonServer("crdb_odbc.dll","tms","tacs", "sa", "mypassword");
breakpoint;

IDatabase =reporting.Database();

IDatabaseTable = IDatabase.Tables();
IDatabaseSingleTable = IDatabaseTable.Item(1);
INameValuePairs = IDatabaseSingleTable.connectionproperties();
IConnectionProperty = INameValuePairs.add("Use DSN Default Properties",False);


paramcond = substr(paramwhole,ret+1,strlen(paramwhole));

reporting.RecordSelectionFormula(paramCond);
reporting.readrecords();


if(ViewYesNo == 'N')
{
variant.boolean(false);
reporting.PrintOut(variant);
}
else
{
ActiveX.ReportSource(reporting);
ActiveX.width(600);
ActiveX.height(350);
ActiveX.DisplayToolbar(true);
ActiveX.DisplayGroupTree(false);

ActiveX.ViewReport();
ActiveX.Refresh();
}


}

Filter Form records based on checkbox form control.

$
0
0

Hello all,

I have a form checkbox control that when its enabled i want to filter the form for all records that have a specific enum type on a field.

For example if checkbox is enabled, i wanna show on my form all records that are of type Invoices.

Thank you.

Set up a ledger posting account for multi line disc sales ax 2012 ?

$
0
0

Set up a ledger posting account for multi line disc sales ax 2012 ?

Viewing all 46681 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>