<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/css" href="https://www.schweda.net/style_feed.css" ?>
<rss version="2.0" 
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
    xmlns:atom="http://www.w3.org/2005/Atom"	
	xmlns:dc="http://purl.org/dc/elements/1.1/" > 
<channel>
    <title>schweda.net - Dynamics 365 Blog</title>
    <link>https://www.schweda.net/</link>
    <description>schweda.net - Dynamics 365 Blog - Blog-Beitraege</description>
    <language>de-at</language>
    <copyright>Copyright 2006-2026</copyright>
    <generator>schweda.net</generator>
    <managingEditor>heinz.schweda@schweda.net (Heinz Schweda)</managingEditor>
    <webMaster>heinz.schweda@schweda.net (Heinz Schweda)</webMaster>
    <category>Blog</category>
	<atom:link href="https://www.schweda.net/blog_rss.php?icid=3&amp;wld=en" rel="self" type="application/rss+xml" />
<item>
<title><![CDATA[SysOperation-Framework: Finanzdimension als Parameter anbieten]]></title>
<description><![CDATA[
<p>Um in einer Funktion, die &uuml;ber das SysOperation-Framework umgesetzt wurde, dem Benutzer einen Finanzdimensionswert einer bestimmten Dimension als Parameter anzubieten, kann man sich des folgenden Codes bedienen:
</p>


<h2>DataContract
</h2>


<pre class="pre_blog_axcode">
[
    DataContractAttribute
    ,SysOperationContractProcessingAttribute(classStr(SysOperationTemplateUIBuilder))
]
internal final class SysOperationTemplateDC implements SysOperationValidatable
{
    private DimensionValue myDimensionValue;

    [
        DataMember,
        SysOperationLabelAttribute(literalStr(&quot;@SYS105870&quot;)), 
        SysOperationDisplayOrderAttribute(&#39;3&#39;)
    ]
    public DimensionValue parmMyDimensionValue(DimensionValue _dimensionValue = myDimensionValue)
    {
        myDimensionValue = _dimensionValue;
        return myDimensionValue;
    }

}
</pre>


<h2>UI-Builder
</h2>


<pre class="pre_blog_axcode">
internal final class SysOperationTemplateUIBuilder extends SysOperationAutomaticUIBuilder
{
    private DialogField myDimensionValueField;

    public void postBuild()
    {
        super();

        myDimensionValueField= this.bindInfo().getDialogField(
            this.dataContractObject(), 
            methodStr(SysOperationTemplateDC, parmMyDimensionValue));

        if (myDimensionValueField)
        {
            myDimensionValueField.lookupButton(FormLookupButton::Always);
        }
    }

    public void postRun()
    {
        super();
    
        // register overrides for form control events
        myDimensionValueField.registerOverrideMethod(
            methodStr(FormStringControl, lookup), 
            methodStr(SysOperationTemplateUIBuilder, lookupMyDimension), 
            this);
    }

    public void lookupMyDimension(FormStringControl _dimensionValueControl)
    {
        Name dimensionAttributeName = &quot;CostCenter&quot;;

        if (_dimensionValueControl != null)
        {
            // Construct arguments for the custom lookup
            Args args = new Args();
            args.name(formStr(DimensionLookup));
            args.lookupValue(_dimensionValueControl.text());
            args.caller(_dimensionValueControl);

            DimensionAttribute dimensionAttribute = DimensionAttribute::findByLocalizedName(
                dimensionAttributeName, 
                false, 
                SystemParameters::find().SystemLanguageId);

            args.lookupField(dimensionAttribute.ValueAttribute);
            args.record(dimensionAttribute);

            // Do the lookup
            FormRun lookupFormRun = classFactory.formRunClass(args);
            lookupFormRun.init();

            _dimensionValueControl.performFormLookup(lookupFormRun);
        }
    }

}

</pre>


<p>&nbsp;
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Wed, 25 Jan 2023 13:38:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=707</link>
<comments>https://www.schweda.net/blog_d365.php?bid=707</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=707</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=707</wfw:commentRss>
</item>
<item>
<title><![CDATA[Unit-Tests per Powershell ausführen]]></title>
<description><![CDATA[
<p>Um auf einer Entwicklungsumgebung Unit-Tests per Powershell auszuf&uuml;hren, kann man die SysTestConsole.exe nutzen:
</p>


<pre class="pre_blog_axcode">
.&#092;SysTestConsole.exe /test:NameOfTestClass1,NameOfTestClass2 /database:axdb
</pre>


<p><a href="https://www.schweda.net/pictures/blogpics/d365_systestconsole1.jpg" rel="lightbox" target="_blank"><img alt="SysTestConsole" height="82" src="https://www.schweda.net/pictures/blogpics/d365_systestconsole1.jpg" style="border-style:solid; border-width:0px" title="SysTestConsole" width="1003" /></a>
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Thu, 22 Apr 2021 08:14:00 +0200</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=705</link>
<comments>https://www.schweda.net/blog_d365.php?bid=705</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=705</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=705</wfw:commentRss>
</item>
<item>
<title><![CDATA[Microsoft Dynamics 365 - Translation Service]]></title>
<description><![CDATA[
<p>Kennt ihr das&nbsp;Microsoft Dynamics 365 - Translation Service in LCS?
</p>


<p>Damit kann man Labelfiles voll automatisiert &uuml;bersetzen lassen - sehr cool!
</p>


<p>Details dazu sind <a href="https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/lifecycle-services/use-translation-service" target="_blank" title="Translation Service">hier</a> zu finden.
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Wed, 30 Sep 2020 11:57:00 +0200</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=704</link>
<comments>https://www.schweda.net/blog_d365.php?bid=704</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=704</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=704</wfw:commentRss>
</item>
<item>
<title><![CDATA["Cannot create a file when that file already exists" beim Datenupgrade von AX 2012 auf Dynamics 365 for Finance and Operations]]></title>
<description><![CDATA[
<p>Beim <strong>Datenupgrade</strong> eines AX 2012 R2 auf <strong>Dynamics 365 for Finance and Operations</strong> hatte ich beim Ausf&uuml;hren des &quot;DataUpgrade-Packages&quot; bei Schritt 9 folgenden Fehler:
</p>


<blockquote>Error during AOS start: Cannot create a file when that file already exists.
</blockquote>


<p>In meinem Fall hat ein Neustarten der auf Azure gehosteten Umgebung und Neustarten des Schrittes geholfen.
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Thu, 04 Jun 2020 19:19:00 +0200</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=702</link>
<comments>https://www.schweda.net/blog_d365.php?bid=702</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=702</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=702</wfw:commentRss>
</item>
<item>
<title><![CDATA[DuplicateKeyException in Tabelle LogisticsLocationRole beim Datenupgrade von AX 2012 auf Dynamics 365 for Finance and Operations]]></title>
<description><![CDATA[
<p>Beim <strong>Datenupgrade</strong> eines AX 2012 R2 auf <strong>Dynamics 365 for Finance and Operations</strong> hatte ich beim Ausf&uuml;hren des &quot;DataUpgrade-Packages&quot; bei Schritt 8 folgende Fehler:
</p>


<blockquote>

<p>Infolog diagnostic message: &#39;Cannot create a record in Roles (LogisticsLocationRole). Role: F?hrendes Unternehmen, Head company. The record already exists.&#39; on category &#39;Error&#39;.&nbsp;<br />
Application configuration sync failed. &nbsp;&nbsp;
</p>

</blockquote>


<p>Bzw.
</p>


<blockquote>

<p>Infolog diagnostic message: &#39;Cannot create a record in Roles (LogisticsLocationRole). Role: Stabile Organisation, Stable organization. The record already exists.&#39; on category &#39;Error&#39;. 08/20/2019 14:52:12: Application configuration sync failed.
</p>

</blockquote>


<p>Ursache waren zwei Datens&auml;tze in der Tabelle <em>LogisticsLocationRole</em>, die in der Quellumgebung (AX 2012 R2) &uuml;ber den Hotfix KB4048614 erstellt wurden. Dieser Hotfix ist interessanterweise genau jener, den man vor einem Upgrade von AX 2012 R2 auf D365 einspielen soll.
</p>


<p>In meinem Szenario konnte ich &uuml;ber das nachstehende Statement die Datens&auml;tze l&ouml;schen, und den Schritt 8 erfolgreich neu starten.
</p>


<pre class="pre_blog_sqlcode">
delete from LOGISTICSLOCATIONROLE
where type = 104 or type = 105

</pre>


<p><a href="https://www.schweda.net/pictures/blogpics/d365_ax2012_upgrade_logisticslocationrole.png" rel="lightbox" target="_blank"><img alt="Tablebrowser LogisticsLocationRole" height="304" src="https://www.schweda.net/pictures/blogpics/d365_ax2012_upgrade_logisticslocationrole.png" style="border-style:solid; border-width:0px" title="Tablebrowser LogisticsLocationRole" width="769" /></a>
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Mon, 04 May 2020 19:20:00 +0200</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=684</link>
<comments>https://www.schweda.net/blog_d365.php?bid=684</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=684</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=684</wfw:commentRss>
</item>
<item>
<title><![CDATA[Fehler "The step failed" beim Platformupdate 32 beim Synchronisieren der Datenbank]]></title>
<description><![CDATA[
<p>Tritt w&auml;hrend eines Platform Updates eines lokalen VPCs folgender Fehler auf...
</p>


<blockquote>

<p>GlobalUpdate script for service model: AOSService on machine: D365Local<br />
Sync AX database<br />
The running command stopped because the preference variable &quot;ErrorActionPreference&quot; or common parameter is set to Stop: System.Management.Automation.RuntimeException: An exception of type System.Net.WebException occurred when making an http request to: http://127.0.0.1/ReportServer. Refer to the log file for more details.<br />
The step failed<br />
The step: 25 is in failed state, you can use rerunstep command to debug the step explicitly<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstallerBase.RunbookExecutor.ExecuteRunbookStepList(RunbookData runbookData, String updatePackageFilePath, Boolean silent, String stepID, ExecuteStepMode executeStepMode, Boolean versionCheck, Parameters parameters)<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstallerBase.AXUpdateInstallerBase.execute(String runbookID, Boolean silent, String updatePackageFilePath, IRunbookExecutor runbookExecutor, Boolean versionCheck, Parameters param)<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstaller.Program.InstallUpdate(String[] args)<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstaller.Program.Main(String[] args)
</p>

</blockquote>


<p>...kann es m&ouml;glicherweise helfen, die Reporting Services &uuml;ber den&nbsp;Reporting Services Configuration Manager for SQL Server 2016 manuell zu starten und danach den Updatevorgang beim betroffenen Schritt fortzusetzen.
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Mon, 27 Apr 2020 10:32:00 +0200</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=695</link>
<comments>https://www.schweda.net/blog_d365.php?bid=695</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=695</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=695</wfw:commentRss>
</item>
<item>
<title><![CDATA[Zeile in einem Grid fett darstellen]]></title>
<description><![CDATA[
<p>Um in einem Grid eine Zeile fett darzustellen kann man die Methode <strong>displayOption()</strong> der jeweiligen FormDataSource &uuml;berschreiben:
</p>


<pre class="pre_blog_axcode">
public void displayOption(Common _record, FormRowDisplayOption _options)
{
    MyTable myTable = _record as MyTable;
            
    super(_record, _options);
            
    _options.fontBold(false);
            
    if (<em>true</em>)  
    {
        _options.fontBold(true);
    }
}
</pre>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Fri, 24 Apr 2020 11:24:00 +0200</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=682</link>
<comments>https://www.schweda.net/blog_d365.php?bid=682</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=682</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=682</wfw:commentRss>
</item>
<item>
<title><![CDATA[Zugriff verweigert beim Aufruf eines SysOperationControllers]]></title>
<description><![CDATA[
<p>Wenn beim Aufruf eines SysOperationControllers der nachstehende Fehler auftritt, kann eine m&ouml;gliche Ursache sein, da&szlig; am aufrufenden MenuItem die Eigenschaften <em>Enum Type Parameter, Enum Parameter</em> und <em>Parameters </em>nicht bef&uuml;llt sind.
</p>


<blockquote>

<p>Zugriff verweigert: SysOperationController
</p>

</blockquote>


<p>Ein MenuItem f&uuml;r einen SysOperationController sollte in der Regel wie folgt aussehen:
</p>


<p><a href="https://www.schweda.net/pictures/blogpics/d365_menuitemsysopsimplesync.png" rel="lightbox" target="_blank"><img alt="Screenshot MenuItem" height="625" src="https://www.schweda.net/pictures/blogpics/d365_menuitemsysopsimplesync.png" style="border-style:solid; border-width:0px" title="Screenshot MenuItem" width="435" /></a>
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Thu, 16 Apr 2020 08:43:00 +0200</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=691</link>
<comments>https://www.schweda.net/blog_d365.php?bid=691</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=691</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=691</wfw:commentRss>
</item>
<item>
<title><![CDATA[Eingebaute Symbole als Display-Methode verwenden]]></title>
<description><![CDATA[
<p>Wer eines der in Dynamics 365 for Finance and Operations eingebundenen Symbole als Display-Methode einbinden m&ouml;chte, der findet im folgenden ein Beispiel daf&uuml;r:
</p>


<pre class="pre_blog_axcode">
[SysClientCacheDataMethodAttribute(true)]
public display container displayOnHoldImage()
{
    if (trueContition)
    {
        return ImageReference::constructForSymbol(ImageReferenceSymbol::Pause).pack();
    }
    return connull();
}
</pre>


<p>&nbsp;
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Wed, 08 Apr 2020 09:50:00 +0200</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=700</link>
<comments>https://www.schweda.net/blog_d365.php?bid=700</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=700</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=700</wfw:commentRss>
</item>
<item>
<title><![CDATA[Fehler "The step failed" beim Platformupdate 32 beim Aktualisieren des Retail self service]]></title>
<description><![CDATA[
<p>Tritt w&auml;hrend eines Platform Updates eines lokalen VPCs folgender Fehler auf...
</p>


<blockquote>

<p>GlobalUpdate script for service model: RetailSelfService on machine: D365Local<br />
Update Retail self service.<br />
UpdateRetailSelfService.ps1 failed.<br />
The step failed<br />
The step: 52 is in failed state, you can use rerunstep command to debug the step explicitly<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstallerBase.RunbookExecutor.ExecuteRunbookStepList(RunbookData runbookData, String updatePackageFilePath, Boolean silent, String stepID, ExecuteStepMode executeStepMode, Boolean versionCheck, Parameters parameters)<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstaller.Program.InstallUpdate(String[] args)<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstaller.Program.Main(String[] args)
</p>

</blockquote>


<p>...kann es m&ouml;glicherweise helfen, den Azure Storage Emulator&nbsp;zu starten und danach den Updatevorgang beim betroffenen Schritt fortzusetzen.
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Sun, 29 Mar 2020 15:29:00 +0200</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=698</link>
<comments>https://www.schweda.net/blog_d365.php?bid=698</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=698</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=698</wfw:commentRss>
</item>
<item>
<title><![CDATA[Labelfile auf einer Entwicklungsumgebung entfernen]]></title>
<description><![CDATA[
<p>Wenn man in die Verlegenheit kommen sollte, auf einer Entwicklungsumgebung ein Labelfile l&ouml;schen zu m&uuml;ssen, sollte man in jedem Fall anschlie&szlig;end pr&uuml;fen, ob in der folgenden Verzeichnissen noch Fragmente dieses Labelfiles &uuml;brig geblieben sind:
</p>


<ul>
	
<li>C:&#092;AOSService&#092;PackagesLocalDirectory&#092;MyModel&#092;MyModel&#092;AxLabelFile
</li>
	
<li>C:&#092;AOSService&#092;PackagesLocalDirectory&#092;MyModel&#092;Resources (inkl. Unterverzeichnisse je Sprache)
</li>

</ul>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Sat, 28 Mar 2020 18:10:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=699</link>
<comments>https://www.schweda.net/blog_d365.php?bid=699</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=699</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=699</wfw:commentRss>
</item>
<item>
<title><![CDATA[Einfache Zeitmessung im Code]]></title>
<description><![CDATA[
<p>Um die Ausf&uuml;hrungsdauer einer Funktion/Logik zu messen, kann man&nbsp;System.Diagnostics.Stopwatch verwenden:
</p>


<pre class="pre_blog_axcode">
System.Diagnostics.Stopwatch watch = new System.Diagnostics.Stopwatch();
watch.Start();
// ... do something
watch.Stop();
info(strFmt(&quot;%1ms&quot;, watch.ElapsedMilliseconds));
</pre>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Sun, 15 Mar 2020 18:03:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=675</link>
<comments>https://www.schweda.net/blog_d365.php?bid=675</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=675</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=675</wfw:commentRss>
</item>
<item>
<title><![CDATA[[BPFrameworkFatalException]:A fatal exception occured in the Best Practices framework]]></title>
<description><![CDATA[
<p>Ich hatte in der Vergangenheit immer wieder das Problem, da&szlig; die BP-Pr&uuml;fung nicht alle zu erwartetenden Abweichungen gefunden hat oder sogar der folgende Fehler ausgegeben wurde:
</p>


<blockquote>

<p>[BPFrameworkFatalException]:A fatal exception occured in the Best Practices framework.
</p>

</blockquote>


<p>In all diesen F&auml;llen hat es geholfen, die folgende Regel zu deaktivieren:&nbsp;<strong>BPCheckTableDimensionFields</strong>
</p>


<p><a href="https://www.schweda.net/pictures/blogpics/d365_bpdisablebpchecktabledimensionfields.png" rel="lightbox" target="_blank"><img alt="D365 Best practice rules" height="434" src="https://www.schweda.net/pictures/blogpics/d365_bpdisablebpchecktabledimensionfields.png" style="border-style:solid; border-width:0px" title="D365 Best practice rules" width="743" /></a>
</p>


<p>Gefunden habe ich den entscheidenden Tip in der <a href="https://community.dynamics.com/365/financeandoperations/f/dynamics-365-for-finance-and-operations-forum/308386/ax2012-vs-finops-bp-checks" target="_blank">Dynamics 365 Community</a>
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Thu, 05 Mar 2020 19:49:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=697</link>
<comments>https://www.schweda.net/blog_d365.php?bid=697</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=697</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=697</wfw:commentRss>
</item>
<item>
<title><![CDATA[Dimensions-Anzeigewert auf Basis eines LedgerDimension-Feldes ermitteln]]></title>
<description><![CDATA[
<p>Wenn man sich per Code den Anzeigewert einer als <em>RefRecId </em>gespeicherten Finanzdimension ermitteln m&ouml;chte, kann sich der nachstehenden Funktion aus der <strong>LedgerDimensionFacade </strong>bedienen:
</p>


<pre class="pre_blog_axcode">
DimensionDisplayValue displayValue = 
LedgerDimensionFacade::getDisplayValueForLedgerDimension(ledgerJournalTrans.LedgerDimension);
</pre>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Fri, 28 Feb 2020 08:04:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=693</link>
<comments>https://www.schweda.net/blog_d365.php?bid=693</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=693</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=693</wfw:commentRss>
</item>
<item>
<title><![CDATA[FormViewOption einer Form per Code steuern]]></title>
<description><![CDATA[
<p>Um die FormViewOption einer&nbsp;Form zu steuern, kann man Code wie den folgenden verwenden:
</p>


<pre class="pre_blog_axcode">
public static void setFormViewOption(
    FormRun _formRun,
    FormViewOption _formViewOption = FormViewOption::Details
    )
{
    if (_formRun
        &amp;&amp; _formRun.viewOptionHelper())
    {
        _formRun.viewOptionHelper().setViewOption(_formViewOption);
    }
}
</pre>


<p>&nbsp;
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Thu, 20 Feb 2020 07:13:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=696</link>
<comments>https://www.schweda.net/blog_d365.php?bid=696</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=696</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=696</wfw:commentRss>
</item>
<item>
<title><![CDATA[Best-Practice-Abweichungen unterdrücken]]></title>
<description><![CDATA[
<p>Prinzipiell sollte jede L&ouml;sung in <strong>Dynamics 365 for Finance and Operations</strong> frei von Best-Practice-Abweichungen sein, dennoch gibt es ab und an die Notwendigkeit, sie unterdr&uuml;cken zu m&uuml;ssen.
</p>


<p>Ein solcher Fall sind beispielsweise Eventhandler, die ein vorgegebenes Paramterprofil aufweisen,&nbsp;im Falle eine Nicht-Verwendung eines dieser Parameter aber eine BP-Abweichung verursachen.
</p>


<pre class="pre_blog_axcode">
class MyFreeTextInvoiceHeaderFooterTmpEH
{
    [DataEventHandler(tableStr(FreeTextInvoiceHeaderFooterTmp), DataEventType::Inserting)]
    public static void FreeTextInvoiceHeaderFooterTmp_onInserting(Common sender, DataEventArgs e)
    {
        FreeTextInvoiceHeaderFooterTmp freeTextInvoiceHeaderFooterTmp;
    
        freeTextInvoiceHeaderFooterTmp = sender;
    
        if (freeTextInvoiceHeaderFooterTmp.CompanyBankAccount == &quot;&quot;)
        {
            freeTextInvoiceHeaderFooterTmp.CompanyBankName = &quot;Unknown&quot;;
        }
    }
}
</pre>


<p>Bei obigem EH w&uuml;rde folgende BP-Abweichung ausgegeben werden, da der Parameter <em>e</em> nicht verwendet wird:
</p>


<blockquote>

<p>BP Rule: [BPParameterNotUsed]:The parameter &#39;e&#39; is not used.
</p>

</blockquote>

<br /><a class="div_blog_category_gotodetail" href="https://www.schweda.net/blog_d365.php?bid=672" target="_self" title="Weiterlesen...">Weiterlesen...</a>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Sat, 18 Jan 2020 11:10:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=672</link>
<comments>https://www.schweda.net/blog_d365.php?bid=672</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=672</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=672</wfw:commentRss>
</item>
<item>
<title><![CDATA[Exception beim Platformupdate 30]]></title>
<description><![CDATA[
<p>Als ich vor kurzem eine lokales D365-VPC mit dem Platform Update 30 versorgen wollte, trat bei Step 19&nbsp;der folgende Fehler auf:
</p>


<blockquote>

<p>GlobalUpdate script for service model: AOSService on machine: D365Local<br />
Sync AX database<br />
The running command stopped because the preference variable &quot;ErrorActionPreference&quot; or common parameter is set to Stop: System.Management.Automation.RuntimeException: An exception of type System.Net.WebException occurred when making an http request to: http://127.0.0.1/ReportServer. Refer to the log file for more details.<br />
The step failed
</p>

</blockquote>


<p>Die Ursache f&uuml;r diesen Fehler war rasch gefunden - nach dem Download des VPC aus LCS wurde der Name des virtuellen Computers ge&auml;ndert, dieser aber nicht &uuml;berall nachgezogen. Dadurch hatten die SQL Reporting&nbsp;Services ein Problem, hier musste eine neue Database eingetragen werden. Wie dies geht, und was man noch alles beim Umbenennen eines VPCs ber&uuml;cksichtigen muss steht &uuml;brigens <a href="https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/migration-upgrade/vso-machine-renaming" target="_blank" title="Rename a local development (VHD) environment">hier</a>.
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Fri, 17 Jan 2020 08:05:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=673</link>
<comments>https://www.schweda.net/blog_d365.php?bid=673</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=673</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=673</wfw:commentRss>
</item>
<item>
<title><![CDATA[Fehler "The step failed" beim Platformupdate 30 in Verbindung mit Reporting services]]></title>
<description><![CDATA[
<p>Tritt w&auml;hrend eines Platform Updates eines lokalen VPCs folgender Fehler auf...
</p>


<blockquote>

<p>Executing step: 19<br />
GlobalUpdate script for service model: AOSService on machine: D365FOSHLocal<br />
Sync AX database<br />
The running command stopped because the preference variable &quot;ErrorActionPreference&quot; or common parameter is set to Stop: System.Management.Automation.RuntimeException: An exception of type System.Net.WebException occurred when making an http request to: http://127.0.0.1/ReportServer. Refer to the log file for more details.<br />
The step failed<br />
The step: 19 is in failed state, you can use rerunstep command to debug the step explicitly<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstallerBase.RunbookExecutor.ExecuteRunbookStepList(RunbookData runbookData, String updatePackageFilePath, Boolean silent, String stepID, ExecuteStepMode executeStepMode, Boolean versionCheck, Parameters parameters)<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstallerBase.AXUpdateInstallerBase.execute(String runbookID, Boolean silent, String updatePackageFilePath, IRunbookExecutor runbookExecutor, Boolean versionCheck, Parameters param)<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstaller.Program.InstallUpdate(String[] args)<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstaller.Program.Main(String[] args)
</p>

</blockquote>


<p>...kann die Ursache sein, da&szlig; der Computername des VPCs ge&auml;ndert wurde, und dabei aber nicht alle von Microsoft empfohlenen Schritte durchgef&uuml;hrt wurden.
</p>


<p>Welche das sind, ist hier zu finden:&nbsp;<a href="https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/migration-upgrade/vso-machine-renaming" target="_blank" title="docs.microsoft.com">https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/migration-upgrade/vso-machine-renaming</a>
</p>


<p>&nbsp;
</p>


<p>&nbsp;
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Wed, 15 Jan 2020 07:21:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=679</link>
<comments>https://www.schweda.net/blog_d365.php?bid=679</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=679</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=679</wfw:commentRss>
</item>
<item>
<title><![CDATA[Finanzdimension als Display-Methode anzeigen]]></title>
<description><![CDATA[
<pre class="pre_blog_axcode">
[SysClientCacheDataMethodAttribute(true)]
public display DimensionDisplayValue displayLedgerDimensionValue()
{
    return LedgerDimensionFacade::getDisplayValueForLedgerDimension(this.LedgerDimension);
}
</pre>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Fri, 03 Jan 2020 15:52:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=685</link>
<comments>https://www.schweda.net/blog_d365.php?bid=685</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=685</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=685</wfw:commentRss>
</item>
<item>
<title><![CDATA[Fehler "Argument für Methode getFieldValue liegt außerhalb des zulässigen Bereichs" beim Importieren über eine Entität]]></title>
<description><![CDATA[
<p>Beim Importieren von Daten &uuml;ber eine selbst erstellte Data Entity, f&uuml;r eine ebenfalls selbst erstellte Tabelle die Finanzdimensionen enth&auml;lt, hatte ich vor kurzem das Problem, dass der Import immer mit dem folgenden Fehler fehlschlug:
</p>


<blockquote>

<p>Argument f&uuml;r Methode getFieldValue liegt au&szlig;erhalb des zul&auml;ssigen Bereichs.
</p>

</blockquote>


<p>Beim Debuggen stelte sich heraus, da&szlig; in der Methode <em>DimensionDynamicAccountDataEntityResolver.getEnumValue() </em>ein Feldname nicht ermittelt werden konnte. Allerdings ist die verantwortliche Methode<em> DictDataEntityField.dynamicDimensionEnumartionField()</em> nicht einsehbar.
</p>

<br /><a class="div_blog_category_gotodetail" href="https://www.schweda.net/blog_d365.php?bid=678" target="_self" title="Weiterlesen...">Weiterlesen...</a>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Fri, 20 Dec 2019 14:25:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=678</link>
<comments>https://www.schweda.net/blog_d365.php?bid=678</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=678</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=678</wfw:commentRss>
</item>
<item>
<title><![CDATA[Feld vom Typ LedgerDimension zu einer (eigenen) Tabelle hinzufügen]]></title>
<description><![CDATA[
<p>Um in Dynamics 365 for Finance and Operations zu einer (eigenen) Tabelle ein Feld vom Typ <strong>LedgerDimension </strong>hinzuzuf&uuml;gen&nbsp;- also ein Feld, welches Finanzdimensionen aufnehmen soll - sind nur wenige Schritte erforderlich:
</p>


<ol>
	
<li>Neue Foreign-Key-Relation zur Tabelle <em>DimensionAttributeValueCombination </em>erstellen
</li>
	
<li>Als Index dieser Relation RecId ausw&auml;hlen<br />
	Dadurch wird nun ein neues Feld in der Tabelle generiert und die Relation zu diesem Feld erstellt
</li>
	
<li>Die Eigenschaft Extends dieses neuen Feldes sollte nun auf&nbsp;<em>DimensionDynamicAccount</em> ge&auml;ndert werden<br />
	Das Feld kann nun ggf. umbenannt werden, z.B. LedgerDimension
</li>
	
<li>Nun muss ein weiteres neues Feld eingef&uuml;gt werden, da&szlig; von BaseEnum <em>LedgerJournalACType </em>ableitet
</li>

</ol>


<p>Um ein solches Feld nun auch in einem (eigenen) Formular anzuzeigen, sind folgende Schritte notwendig:
</p>


<ol>
	
<li>Per Drag &amp; Drop beide erstellten Felder im Design platzieren
</li>
	
<li>Dabei wird f&uuml;r das Feld, das die Dimension aufnehmen soll&nbsp;(z.B. LedgerDimension), ein Segmented Entry Control erstellt
</li>
	
<li>In den Eigenschaften dieses Controls sind nun folgende Eigenschaften anzupassen
	
<ul>
		
<li>Controller Class: <em>DimensionDynamicAccountController</em>
</li>
		
<li>Account type field: Hier muss jenes Feld eingetragen werden, das von <em>LedgerJournalACType </em>abgeleitet wurde
</li>
	
</ul>
	
</li>

</ol>


<p>Abh&auml;ngig von der Klasse die man am Segmented Entry Control in der Eigenschaft <em>Controller Class</em> hinterlegt, sind noch ggf. weitere Einstellungen vorzunehmen, wobei nicht alle immer zul&auml;ssig sein. Mehr dazu unter <a href="https://docs.microsoft.com/de-at/dynamics365/unified-operations/dev-itpro/financial/segmented-entry-control-metadata-specification" target="_blank">https://docs.microsoft.com/de-at/dynamics365/unified-operations/dev-itpro/financial/segmented-entry-control-metadata-specification</a>
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Mon, 16 Dec 2019 09:14:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=670</link>
<comments>https://www.schweda.net/blog_d365.php?bid=670</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=670</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=670</wfw:commentRss>
</item>
<item>
<title><![CDATA[Fehler beim Platformupdate 30 in Verbindung mit Management Reporter]]></title>
<description><![CDATA[
<p>Tritt w&auml;hrend eines Platform Updates eines lokalen VPCs folgender Fehler auf...
</p>


<blockquote>

<p>Executing step: 42<br />
GlobalUpdate script for service model: MROneBox on machine: localhost<br />
Update the financial reporting database<br />
Job AutoGlobalUpdateMR job failed<br />
The step failed<br />
The step: 42 is in failed state, you can use rerunstep command to debug the step explicitly<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstallerBase.RunbookExecutor.ExecuteRunbookStepList(RunbookData runbookData, String updatePackageFilePath, Boolean silent, String stepID, ExecuteStepMode executeStepMode, Boolean versionCheck, Parameters parameters)<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstaller.Program.InstallUpdate(String[] args)<br />
&nbsp; &nbsp;at Microsoft.Dynamics.AX.AXUpdateInstaller.Program.Main(String[] args)
</p>

</blockquote>


<p>...kann die Ursache sein, da&szlig; der Computername des VPCs ge&auml;ndert wurde, und dabei aber nicht alle von Microsoft empfohlenen Schritte durchgef&uuml;hrt wurden.
</p>


<p>Welche das sind, ist hier zu finden:&nbsp;<a href="https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/migration-upgrade/vso-machine-renaming" target="_blank" title="docs.microsoft.com">https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/migration-upgrade/vso-machine-renaming</a>
</p>


<p>&nbsp;
</p>


<p>&nbsp;
</p>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Sat, 14 Dec 2019 17:09:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=681</link>
<comments>https://www.schweda.net/blog_d365.php?bid=681</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=681</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=681</wfw:commentRss>
</item>
<item>
<title><![CDATA[Buttons, MenuItems und Tiles über die Eigenschaft Normal Image mit Symbolen ergänzen]]></title>
<description><![CDATA[
<div class="div_table_100_wo_border">

<div class="div_tablerow">

<div class="div_tablecolumn" style="padding-right:10px">

<p>Um einen Button, ein MenuItem oder einen Tile um ein Bild/Icon zu erg&auml;nzen kann man die Eigenschaften <strong>Image Location</strong> und <strong>Normal Image</strong> verwenden.
</p>


<p>In Dynamics 365 for Finance and Operations ist die <em>Image Location</em> &quot;Symbol&quot; dazugekommen, wenn man diese verwendet muss man in <em>Normal Image</em>&nbsp;den Namen eines Symboles eintragen.
</p>


<p>Welche Symbolnamen es gibt, findet man unter:<br />
<a href="https://mbs.microsoft.com/customersource/Global/AX/downloads/hot-fixes/AXSymbolFont" target="_blank" title="docs.microsoft.com">https://mbs.microsoft.com/customersource/Global/AX/downloads/hot-fixes/AXSymbolFont</a>
</p>


<p>Mehr zu dem Thema ist &uuml;brigens hier zu finden:<br />
<a href="https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/user-interface/action-controls#button-images" target="_blank" title="docs.microsoft.com">https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/user-interface/action-controls#button-images</a>
</p>

</div>


<div class="div_tablecolumn" style="width:30%">

<p><a href="https://www.schweda.net/pictures/blogpics/d365_normalimage_property.png" rel="lightbox" target="_blank"><img alt="Property Nomal Image" height="169" src="https://www.schweda.net/pictures/blogpics/d365_normalimage_property.png" style="border-style:solid; border-width:0px; padding-left:10px" title="Property Normal Image" width="362" /></a>
</p>

</div>

</div>

</div>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Thu, 12 Dec 2019 15:38:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=676</link>
<comments>https://www.schweda.net/blog_d365.php?bid=676</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=676</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=676</wfw:commentRss>
</item>
<item>
<title><![CDATA[Enum-Werte im Formular ausblenden]]></title>
<description><![CDATA[
<p>Um in einem Formcontrol, das von einem Base enum abgeleitet ist, bestimmte Werte auszublenden, kann man sich der <em>enter()</em>-Methode bedienen.&nbsp;
</p>


<pre class="pre_blog_axcode">
[Control(&quot;ComboBox&quot;)]
class LedgerJournalTypeCB
{
    public void enter()
    {
        super(); 

        this.delete(enum2str(LedgerJournalACType::Vend));
        this.delete(enum2str(LedgerJournalACType::Cust));
    }
}
</pre>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Thu, 31 Oct 2019 20:39:00 +0100</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=674</link>
<comments>https://www.schweda.net/blog_d365.php?bid=674</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=674</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=674</wfw:commentRss>
</item>
<item>
<title><![CDATA[Best-Practice-Prüfungen über Kommandozeile ausführen]]></title>
<description><![CDATA[
<p>&Uuml;blicherweise l&auml;sst man die Best-Practice-Pr&uuml;fungen ja beim Build eines Projektes/einer Solution mitlaufen. Ab und an kann es aber recht praktisch ein, diese auch getrennt von einem Build zu starten.
</p>


<p>Daf&uuml;r bietet uns Microsoft das <strong>XppBp</strong>-Tool an, siehe&nbsp;<a href="https://docs.microsoft.com/en-us/dynamics365/unified-operations/dev-itpro/dev-tools/author-best-practice-rules" target="_blank" title="Write best practice rules">https://docs.microsoft.com/en-us/dynamics365/unified-operations/dev-itpro/dev-tools/author-best-practice-rules</a> (ganz unten).
</p>


<p>Dieses Tool liegt im <em>PackagesLocalDirectory&#092;bin</em>-Verzeichnis und kann exemplarisch wie folgt verwendet werden:
</p>


<pre class="pre_blog_axcode">
Xppbp.exe 
&nbsp;   -module:MyModel 
&nbsp;   -model:MyModel 
&nbsp;   -metadata:&quot;C:&#092;AOSService&#092;PackagesLocalDirectory&quot; 
    -all
</pre>]]></description>
<category>Microsoft Dynamics 365 for Finance and Operations</category>
<pubDate>Sun, 06 Oct 2019 16:16:00 +0200</pubDate>
<link>https://www.schweda.net/blog_d365.php?bid=665</link>
<comments>https://www.schweda.net/blog_d365.php?bid=665</comments>
<guid isPermaLink="true">https://www.schweda.net/blog_d365.php?bid=665</guid>
<author>heinz.schweda@schweda.net (Heinz Schweda)</author>
<wfw:commentRss>https://www.schweda.net/blog_d365.php?bid=665</wfw:commentRss>
</item>
</channel>
</rss>	
