I've written some code to query the ODATA endpoint in Dynamics Nav 2016. I did this by creating an ODATA connected service. I wrote the following code to add a record:
var navision = new Navision(
new Uri("http://navision:7048/navision/OData/Company('Company1')"))
{
Credentials = new NetworkCredential("MyUser@example.com", "password")
};
navision.AddToFoo(new Foo() { Name = "Bar" });
navision.SaveChangesAsync();
I have enabled 'Change Log Entries' for the Foo
table. However, when the above code executes, the user displayed in the change log entries is MyUser@example.com
. Is it possible to set this user myself explicitly?
*This post is locked for comments