Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics NAV (Archived)

Unable to set the space between date format.

(0) ShareShare
ReportReport
Posted on by 1,893

Dear Experts,

I have designed a  report...where I want  to show the posting date. But I am unable to set the spaces between the character.. like if date is 31 12 2017...I want to show 3  1  1  2  2  0  1  7

it always comes with 31 12 20 17

My code is below:

txtDate := COPYSTR(FORMAT("Gen. Journal Line"."Posting Date",8,1),1,2);
txtDate += COPYSTR(FORMAT("Gen. Journal Line"."Posting Date",8,1),4,2);
txtDate += FORMAT(DATE2DMY("Gen. Journal Line"."Posting Date",3),4,1);

intDtLen := 10;

REPEAT
txtDate := INSSTR(txtDate,' ',intDtLen);
intDtLen -= 1;
UNTIL intDtLen = 1;

5466.test01.png

*This post is locked for comments

  • manish.yadav Profile Picture
    1,893 on at
    RE: Unable to set the space between date format.

    I am not able to solve it. There is no progress.

  • Suggested answer
    Mohana Yadav Profile Picture
    60,232 Super User 2025 Season 1 on at
    RE: Unable to set the space between date format.

    then you have to reduce the box sizes to fit the date

  • manish.yadav Profile Picture
    1,893 on at
    RE: Unable to set the space between date format.

    Dear Sir,

    It is not pre-printed preport. I have designed it from scratched my own side.

  • Suggested answer
    Mohana Yadav Profile Picture
    60,232 Super User 2025 Season 1 on at
    RE: Unable to set the space between date format.

    you need to create separate text boxes/columns in your layout as well same as pre printed form (below or columns in report layout)

    [ ]  [ ]  [ ]  [ ]  [ ]  [ ]

    and you need to get 1st character of date and store in a decimal array and show it in above columns

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

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

Kudos to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Microsoft Dynamics NAV (Archived)

Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans