[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

VB.NET equivalent of split() or explode()

Posted on 2007-03-24
4
Medium Priority
?
5,414 Views
Last Modified: 2012-05-05
What is the Visual Basic .NET equivalent of PHP's split() or explode() function?

More info: split() and explode() take a string and split it into array components based on another string.

Given a string named $a: "super;really;seriously"
And given command: split($a,";");
An array would be produced: $b[0]="super", $b[1]="really", $b[2]="seriously"
0
Comment
Question by:richdiesal
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 67

Accepted Solution

by:
sirbounty earned 500 total points
ID: 18787013
split is the same in vb.net...

strData="super;really;seriously"
arrData=strData.Split(strData,";")

Now arrData(0) would equal "super", arrData(1) would equal "really", etc...
0
 
LVL 67

Expert Comment

by:sirbounty
ID: 18787015
Perhaps the explode is the same as Join in vb.net? (joins the array back together...)
0
 
LVL 9

Author Comment

by:richdiesal
ID: 18787035
Aha!  I was treating it as a function instead of a method - and explode is the same as split.  Thanks!
0
 
LVL 67

Expert Comment

by:sirbounty
ID: 18787039
:)
Glad I could be of assistance... (since I can only spell PHP - haha!)
0

Featured Post

[Webinar] Lessons on Recovering from Petya

Skyport is working hard to help customers recover from recent attacks, like the Petya worm. This work has brought to light some important lessons. New malware attacks like this can take down your entire environment. Learn from others mistakes on how to prevent Petya like worms.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

These days socially coordinated efforts have turned into a critical requirement for enterprises.
This article discusses four methods for overlaying images in a container on a web page
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…

649 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question