Reputation: 11
How can i parse this string
https://20.85.239.243:50000/b1s/v1/Orders(26)
to get the value 26 in a variable?
Upvotes: 0
Views: 67
Reputation: 116
If the string literally like that you can use substring instead. Maybe like this :
string.Substring((string.Length-4), 2)
Or maybe you can find what you need here: https://learn.microsoft.com/en-us/dotnet/api/system.string.substring?redirectedfrom=MSDN&view=net-6.0#overloads
Upvotes: 1