Split

by ssi 12. November 2015 16:34

  sRet = sRet.Replace("DB_backup_", "").Replace(".trn.7z", "");

            char[] delimiter = { '_' };

            string[] split = null;

 

            for (int x = 0; x <= 5; x++)

                split = sRet.Split(delimiter, x);

            string sYr = split[0];

            string sMn = split[1];

            string sDy = split[2];

            string sTm = split[3].Substring(0, 4);

            sRet = string.Format("Last TL from : {0}/{1}/{2} @ {3}", sMn, sDy, sYr, sTm);

            return sRet;

 

Tags: ,

CSharp

Calendar

<<  May 2024  >>
MoTuWeThFrSaSu
293012345
6789101112
13141516171819
20212223242526
272829303112
3456789

View posts in large calendar

RecentComments

None

Development Team @ Shelbysys

We develop custom database applications for our clients. Our development tool of choice is MS Visual Studio. 

Quotations

""All glory is fleeting.""
General George S. Patton, Jr