c# - Search a substring in another string -


string name = "blk000012345summary.pdf"; string filename = "20150929111111zp2zq23blk000012345summary.pdf"; 

i have string name have find in filename, if exists should return true otherwise false.

string name = "blk000012345summary.pdf"; string filename = "20150929111111zp2zq23blk000012345summary.pdf";  bool value = filename.contains(name); 

Comments

Popular posts from this blog

html - Outlook 2010 Anchor (url/address/link) -

javascript - Why does running this loop 9 times take 100x longer than running it 8 times? -

Getting gateway time-out Rails app with Nginx + Puma running on Digital Ocean -