Skip to main content

Notifications

Microsoft Dynamics GP (Archived)

Script help for Integration Manager, concatenate fields for Reference field

Posted on by 69

I am working on creating an IM and am trying to find my way through it, but have a couple of questions (posting separately). In the below sample code that is offered in the GP IM script library, how do I code for only the first character of one of the fields? For example, in Segment1 I only want the first character. Also, what if I want the first 5 of another segment? Would that be different than the first character? Is this sample they offer VB? It doesn’t appear to be VB I’m used to, but I am not a programmer and only have fundamental experience.

CurrentField = SourceFields("Accounts.Segment1") + SourceFields("Accounts.Segment2") + SourceFields("Accounts.Segment3")

Can someone please help me with modifying the sample for what I need? Thank you in advance!

*This post is locked for comments

  • ABrown Profile Picture
    ABrown 69 on at
    RE: Script help for Integration Manager, concatenate fields for Reference field

    Figured it out, VB Script, which is slightly different than VB.  Thank you again!

  • ABrown Profile Picture
    ABrown 69 on at
    RE: Script help for Integration Manager, concatenate fields for Reference field

    Thank you!!!  It worked.  What language or syntax is this?  I'd like to be able to find some resources.  Thanks again, I really appreciate it.

  • Verified answer
    Mike Bufano Profile Picture
    Mike Bufano 1,480 on at
    RE: Script help for Integration Manager, concatenate fields for Reference field

    Use the "Left" in your statement and at the end, indicate the number of characters.

    CurrentField = Left(SourceFields("Accounts.Segment1") ,1)

    You can use that same technique for the other fields.

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.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,240 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,149 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans