Solved

Reading and Modifying textbox output vb6

Posted on 2007-12-03
2
261 Views
Last Modified: 2012-05-05
Lets say I have 4 text boxes
They read-
Text1.text -      John James Doe

I want text2 to read    -      John
text3                           -      James
text4                           -      Doe

Now text1.text may read-   Kim Sara Smith
The name was an example.  Basically what is the coding for everything to the right of the 1st space, coding for 2nd space to 1st space, and 2nd space to right end?

This is for VB6
Thanks in advanced
0
Comment
Question by:daneburr
  • 2
2 Comments
 
LVL 76

Expert Comment

by:GrahamSkan
Comment Utility
text1.text = Replace(text1.text, " ", vbcrlf)
0
 
LVL 76

Accepted Solution

by:
GrahamSkan earned 50 total points
Comment Utility
Sorry. I misread the question
Dim strTexts() as string
strTexts() = split (text1.text, " ")
text2.text = strTexts(0)
text3.text = strTexts(1)
text4.text = strTexts(2)
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

763 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now