Substring / IndexOf - Get Data In Middle Of String

Stimulsoft Reports.NET discussion
Post Reply
nathan
Posts: 4
Joined: Wed May 15, 2024 7:54 am

Substring / IndexOf - Get Data In Middle Of String

Post by nathan »

Good morning,

We are using Stimulsoft Report.Net 2016.3. One of our requirements is to print a piece of data on the report that is contained in a field between delimiters. For example

Code: Select all

DATA1~DATA2~DATA3~DATA4~
If I wish to print only DATA3, I and I know that it will always be in between the second and third '~' delimiter, is there a function, or combination thereof, that will achieve this?

Many thanks for any suggestions!
Lech Kulikowski
Posts: 7334
Joined: Tue Mar 20, 2018 5:34 am

Re: Substring / IndexOf - Get Data In Middle Of String

Post by Lech Kulikowski »

Hello,

You can try to use Split() method.

Thank you.
Attachments
Screenshot 2024-05-15 103427.png
Screenshot 2024-05-15 103427.png (33.02 KiB) Viewed 1300 times
Post Reply