D365 SCM’ Vendor Collaboration portal enables external vendors to access related purchase orders, invoices, consignment inventory, and requests for quotation information.
If you are new to Vendor Collaboration portal, I advise you to start here. This topic discusses how to enable Gmail accounts to access Vendor Collaboration Portal.
Set up and maintain vendor collaboration.
Not all vendors use Microsoft 365 accounts and therefore use their personal email accounts to sign up for and access Vendor Collaboration portal. As you might know this is not supported officially. If you followed steps listed here using Gmail accounts, you will receive this error.
You are not authorized to login with your current credentials
To enable Gmail (or other non-Microsoft accounts) accounts to access Vendor Collaboration portal, you need to sign up to create Microsoft account for these personal accounts. Below I will show you how can achieve that in simple steps:
For Gmail accounts you DO NOT need to invite them to Azure Portal as guest accounts when you create Microsoft account for them.
Enter your personal accounts, then click Next button.
Signup for Microsoft accounts
Create password that you can use to access your Microsoft account later (this is different that your personal account password), then click Next button.
Signup for Microsoft account
After this point Microsoft account service should send you verification email including security code you will need to use to verify your personal account.
Verification email
use security code to continue signup process. Click Next button.
Verify email
You will be asked to resolve a puzzle to ensure you are not a robot. Complete it then click Next button.
Enter your Birth date and country, then click Next button.
If you recently provisioned Dynamics 365 Development environment using 10.0.29 release, you will notice Event Viewer is missing Dynamics folder.
Dynamics 365 Development Environment Event Viewer after Provisioning 10.0.29 environment.
After some research I found a solution that is shared by “Daniel Codes” he received from Microsoft Support 3 weeks ago. Find details below:
Dynamics folder missing in event viewer on CHE environment was discovered recently and it is being worked on. We expect the fix to be available some time in close future.
In the meantime, you can use this script to install the ETW Provider (which is what adds the event viewer Dynamics folder) attached with this mail (rename it to PS1 and run it on the VM from c:\temp folder).
Microsoft Support
While waiting on permanent fix from MS execute this PowerShell script in your development environment. Make sure you open PowerShell ISE in Administrator mode, then paste the following script and execute:
In this blog I will share with you my first impressions of latest Dynamics 365 for Finance / SCM development environment (version 10.0.28) that I have provisioned recently.
Visual Studio Professional 2019 First and foremost Visual Studio Professional 2019 is the new default development environments (Previously was VS Professional 2017 and before that VS Professional 2015).
I never provisioned D365 10.0.27 Dev environment but I think it is the first version that started using VS 2019.
The Dynamics 365 menu that is used by x++ developers has been moved under Extensions menu:
Dynamics 365 Menu
Update Model Parameters If you tried updating model parameters (Extensions > Dynamics 365 > Model Management > Update model parameters…) You will notice a new tab (step) called select friend packages. I looked up Microsoft docs to check related documentation but found nothing about it. So I did some testing myself, the purpose of this step is to allow models referencing a specific model to access its internal artifacts. For example, if you have model X referencing model Y, then model X will appear under select friend packages tab for model Y, when you updat model Y parameters and select model X as a freind package, then model X will be able to access internal methods/classes of Y.
I created 2 models AZ Demo and AZ Demo 2, AZ Demo 2 references AZ Demo. AZ Demo added AZ Demo 2 as friend package. When I open AZ Demo descriptor files I see AZ Demo 2 added under <InternalsVisibleTo> tag.
Create new project in Visual 2019 the create new project dialog has changed, ensure to enter Finance keyword to find the right project template.
Once selected, it will appear under Recent project templates on the left side for the next time you are creating new project:
Create Project
Visual Studio 2019 Debugging Options for D365 Dev Environment In VS 2019, to debug D365 code you will need to have the correct settings which can be found under: Extensions > Dynamics 365 > Options > Dynamics 365 > Debugging. Under this tab you have the option to select which packages/models you want to include in your debugging, this is newly introduced by Microsoft to speed up debugging process and avoid VS crashes.
Debug items in the solution and items in specific packages. limiting the number of items being debugged provides a better debugging experience > Include Packages:
Debugging D365 Code
As you might know in previous Visual Studio versions you had 1 option to select: “Load symbols only for items in the solution”. if the option is selected, then you can only debug current solution items’ code, if not selected then you can add breakpoint to any artifact under any package/Model.
After recent development environment upgrade to 10.0.26 release, I noticed when I compile any D365 project containing label file, the label IDs in the file get re-ordered alphabetically. This is a new out of the box feature added by MS probably to enhance fetching labels.
If you want to turn this feature off/on in Visual Studio, Open Options menu by navigating to Dynamics 365 > Options…
D365 Options Menu
Click on Projects tab under Dynamics 365 menu. You will see a new option added:
Recently I was looking into cloud-hosted dev environment upgrade issue on Step 25. This step performs 2 main activities:
Report Deployment
Database Sync
I downloaded execution log file and started investigating Step 25 issue by looking in Step25UpdateReports_############.log under RunbookExecution folder. I noticed multiple reports errored out, I searched by one of the reports names in the log and found this error:
Publish-AXReport : An error occurred while deploying the report BankDepositbyCustomer.Report, PersonnelManagement.
This might be because the SQL Server Reporting Services has not been installed, or is not configured correctly.
At K:\AosService\PackagesLocalDirectory\Plugins\AxReportVmRoleStartupTask\Reporting.psm1:503 char:9
+ Publish-AXReport -MaxDegreeOfParallelism 1 -ErrorAction Conti …
Something seemed odd with this report, so I searched for the report in Application Explorer and noticed that BankDepositbyCustomer report does not belong to PersonnelManagement model! it belongs to a different model.
Solution: Since the report is not part of PersonnalManagement model, I opened K:\AosService\PackagesLocalDirectory\PersonnalManagement\Reports folder and removed unrelated .rdl files. I repeated the same for couple more models and this did the trick.
To post packing slip using custom PackingSlipId value against sales order and use custom value to set PackingSlipId you will need to follow these steps.
As you know PackingSlipId is set by the system using Number Sequence.
After digging I found a safe way pass custom PackingSlipId value. first, extend SalesFormLetterContract class to accept custom PackingSlipId:
[ExtensionOf(classStr(SalesFormLetterContract))]
final class AZSalesFormLetterContract_extension
private Num AZOverridePackingSlipId;
[DataMemberAttribute]
public Num parmAZOverridePackingSlipId(Num _overridePackingSlipId = AZOverridePackingSlipId)
{
AZOverridePackingSlipId = _overridePackingSlipId;
return AZOverridePackingSlipId;
}
Then extend SalesPackingSlipJournalCreate class object to set PackingSlipId
[ExtensionOf(classStr(SalesPackingSlipJournalCreate))]
public final class AZSalesPackingSlipJournalCreate_Extension
/// <summary>
/// Initializes non-correctable fields on the journal header.
/// </summary>
public void initHeader()
{
next initHeader();
SalesFormLetterContract contract = this.parmInterCompanyFormletterContract();
if (contract.parmAZOverridePackingSlipId())
{
custPackingSlipJour.PackingSlipId = contract.parmAZOverridePackingSlipId();
}
}
All set!
Now initialize SalesFormLetter object, then get SalesFormLetterContract and pass custom PackingSlipId value:
Finally, on CustPackingSlipSalesLink table there is unique index that includes following fields: SalesId, DeilveryDate and PackingSlipId. before overriding PackingSlipId with custom value, ensure you are not breaking that index, otherwise you will get an error.
Issue 1: When you modify SSRS report in Visual Studio, then compile the solution and Deploy report, most of the time when you try executing the report you might get below error:
Serialization version mismatch detect, make sure the runtime dlls are in sync with the deployed metadata. Version of file '27746'. Version of dll '200'.
The solution to fix this error is to compile the entire AX model.
Sometimes you might need to redeploy the report however compiling the model would be sufficient.
Issue 2: SSRS report compilation error:
Deploying rdl files for report AZCustomReport : AZCustomReport.Report.rdl An error occurred while deploying the report AZCustomReport.Report, AZModel. This might be because the SQL Server Reporting Services has not been installed, or is not configured correctly. System.Web.Services.Protocols.SoapException: The number of defined parameters is not equal to the number of cell definitions in the parameter panel. at Microsoft.ReportingServices.Library.ReportingService2005Impl.CreateReport(String Report, String Parent, Boolean Overwrite, Byte[] Definition, Property[] Properties, Guid batchId, Warning[]& Warnings) at Microsoft.ReportingServices.WebServer.ReportingService2005.CreateReport(String Report, String Parent, Boolean Overwrite, Byte[] Definition, Property[] Properties, Warning[]& Warnings) Deploying rdl files for report AZCustomReport failed.
The solution to fix this issue, is to check Report datasource Parameters, since I am modifying the report, I would right click the report added to the solution, then choose compare with latest version. If there are extra parameters added but they are not supposed to be on the report, remove them by editing the report xml file. If there are missing parameters, then add them.
SSRS Report Parameters
Issue 3: Newly added fields to the report are now showing when I run the report.
The Solution is to remove these fields from the report, then add them back. Compile and Deploy report.
Using System.IO.Stream library you can read text files. here is a runnable class to load the file using FileUploadBuild control, then read its content:
class AZTxtFileRead
{
/// /// Runs the class with the specified arguments. ///
/// The specified arguments.
public static void main(Args _args)
{
#File;
System.IO.Stream stream;
FileUploadBuild fileUpload;
DialogGroup dlgUploadGroup;
FileUploadBuild fileUploadBuild;
FormBuildControl formBuildControl;
Dialog dialog = new Dialog("Import the data from File");
dlgUploadGroup = dialog.addGroup("@SYS54759");
formBuildControl = dialog.formBuildDesign().control(dlgUploadGroup.name());
fileUploadBuild = formBuildControl.addControlEx(classstr(FileUpload), 'Upload');
fileUploadBuild.style(FileUploadStyle::MinimalWithFilename);
fileUploadBuild.fileTypesAccepted('.txt');
if (dialog.run() && dialog.closedOk())
{
FileUpload fileUploadControl = dialog.formRun().control(dialog.formRun().controlId('Upload'));
FileUploadTemporaryStorageResult fileUploadResult = fileUploadControl.getFileUploadResult();
if (fileUploadResult && fileUploadResult.getUploadStatus())
{
CommaTextStreamIo textStream = CommaTextStreamIo::constructForRead(File::UseFileFromURL(fileUploadResult.getDownloadUrl()));
textStream.inFieldDelimiter(',');
textStream.inRecordDelimiter(#delimiterCRLF);
// First line might have header information
container currentLine = textStream.read();
while(currentLine)
{
info(strFmt("%1, %2, %3",
conPeek(currentLine, 1),
conPeek(currentLine, 2),
conPeek(currentLine, 3)));
currentLine = textStream.read();
}
}
}
}
}