Notifications
Announcements
No record found.
Hi All,
I have a requirement to create and update customers such as dob,address etc.
Can I get some x++ code for this please?
Or any blog or link which has the code also fine please.
Please send me ax 2009 based code
Can I have suggestions here please ?
What are you trying to achieve and what exactly is the problem that you need help with?
For example, if you want to import customers, this might help you: How to import customers and vendors in Microsoft Dynamics AX 2009. Or you might utilize the existing AIF document service for customers.
If you need custom code anyway, do you have any particular problem with it? Or do we need to start with the basics such as how to use insert() and update() methods?
Hi Martin,
Thanks for the reply....
My requirement is to get data from 3rd party tool and based on that create customer if not already exists or update already exists.....
My main problem is updating address to customer as I don't find code or blog for ax2009.
Could you please share me the code to update customer address for ax 2009 via CustCustomerService.update operation or any custom code is also fine...
If you want to use AIF, how do you want to do it? For example, do you want to import a XML file through the file system adapter? Or do you want to consume the SOAP web service? Or something else?
Actually from a Third party tool they will consume my custom web service and pass the required parameters for customer, and based on that if customer already exists it will update or if it does not exists it will create new.
So could you please let me know how can I create or update data for customers using the parameter they pass such as (CustAccount,CustGroup,Address) etc.,
Are you saying that you're developing your own web service? If so, it would make sense to call the SOAP service offered by AIF, if the web service will run in the same network as AX 2009 AOS.
Do you use C# to develop your web service?
Yes Martin, you are right I want to develop my own web service.
And I am not sure how to proceed further on this whether to use C# or we can in x++ it self.
Really need your suggestion on this please?
You'll need to think about your architecture before you can write code.
AX 2009 doesn't have a support for developing and hosting custom web services. If it was enough for you to use the AIF document service, you could expose it to the other system.
But if you have a need to develop a custom web service, AX isn't isn't the right tool. You should use something like ASP.NET instead. Then the question is what the web service will do - my suggestion was calling the AIF document service.
Both approaches would use the AIF document service as a web service, therefore you should familiarize yourself with the related documentation: Consume Web Services.
Thanks for your suggestion Martin.
I am struggling with customer address update in C# code.
Could you please give me a sample code for customer address update using C# by calling CustCustomerService.Update?
That would be much helpful to me
Sorry, I don't have that particular piece of code for that particular version of AX.
But I (and others) could help if you explain your particular problem.
You said that you have a problem with the address - does it mean that you know how to update other information, such as customer name?
What exactly are struggling with?
Under review
Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.
As AI tools become more common, we’re introducing a Responsible AI Use…
We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
Martin Dráb 646 Most Valuable Professional
André Arnaud de Cal... 529 Super User 2025 Season 2
Sohaib Cheema 285 User Group Leader