Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
Go Back   Dev Hardware ForumsSOFTWAREProgramming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Hardware Forums Sponsor:
  Trader Rating: 0 · #16  
Old January 3rd, 2007, 04:50 AM
mphill's Avatar
mphill mphill is offline
untitled
Click here for more information
 
Join Date: Oct 2005
Location: Zagreb
Posts: 3,860 mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)mphill User rank is General 110th Grade (Above 100000 Reputation Level)  Folding Points: 14729 Folding Title: Novice Folder
Time spent in forums: 3 Months 3 Weeks 3 Days 7 h 29 m 25 sec
Reputation Power: 8306
Send a message via ICQ to mphill
Facebook
Homework?
__________________
Click Here ->    

Reply With Quote
  Trader Rating: 0 · #17  
Old January 3rd, 2007, 07:25 AM
Salchester Salchester is offline
Contributing User
Dev Hardware Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 293 Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 1 Day 23 h 37 m 7 sec
Reputation Power: 6
Quote:
Originally Posted by mphill
Homework?
NO!, Why does everybody think this/everything else is homework?

This is a place for learning isn't it?

How can you learn with out any visual code to view?

Many Thanks,

Reply With Quote
  Trader Rating: 0 · #18  
Old January 3rd, 2007, 07:52 AM
Salchester Salchester is offline
Contributing User
Dev Hardware Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 293 Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 1 Day 23 h 37 m 7 sec
Reputation Power: 6
As Nilpo is currently offline,

Do you know how the code can be adapted to search actual fields instead of the ":".

At the moment the code searches the following string(s) in a multi line text field, and returns the data after the ":".

Date: 12/12/06
Name: Bill
Age: 19

Is there anyway the code can be adapted, to search the hole field, i.e. Date:, Name: Age:, with the ":"

Reason why, as if the data in the text field contains a ":" the code screws up, and extracts the wrong data. This won't happen if the field name is included aswell i.e. Name:

Many Thanks,

Many Thanks,

Reply With Quote
  Trader Rating: 2 · #19  
Old January 3rd, 2007, 02:15 PM
Nilpo's Avatar
Nilpo Nilpo is offline
Dev Hardware God 1st Plane (5500 - 5999 posts)
 
Join Date: May 2004
Location: Salem, OH
Posts: 5,729 Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)  Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1
Time spent in forums: 1 Month 1 Week 6 Days 2 h 34 m 48 sec
Reputation Power: 10408
Send a message via ICQ to Nilpo Send a message via AIM to Nilpo Send a message via MSN to Nilpo Send a message via Yahoo to Nilpo Send a message via Google Talk to Nilpo Send a message via Skype to Nilpo Send a message via XFire to Nilpo
Facebook MySpace Orkut
Quote:
Originally Posted by Salchester
What is CSV?
CSV stands for Comma Separated Values. I'm asking if you want to have a delimited (database style) text file or just a plain text dump.
Quote:
Originally Posted by Salchester
Is there anyway of making the file unreadable, via storing the data as binary etc.
Do want want it written in binary or encrypted? Why? What is this file going to be used for?
Quote:
Originally Posted by Salchester
Is there anyway you could comment you code, in order for me to work out how it all works, and what values are going in to where?
The code is fully commented. The only thing I haven't commented is the actual VB functions. Google is your friend.
Quote:
Originally Posted by Salchester
is there anyway of extracting the date, with ": " before it?
You want the ":" included in the data dump? I can do that.
Quote:
Originally Posted by Salchester
What needs to be changed in the code now to ignore <Name Field> has sent the following information: and the two line breaks?
Nothing. It already does.
Quote:
Originally Posted by Salchester
Is there anyway the code can be adapted, to search the hole field, i.e. Date:, Name: Age:, with the ":"
Yes, to avoid errors when field data contains colons, we can do a search against the entire field name, but since your field name is always at the beginning of the string and always the same it's easier to do a simple character count instead. Here's your code:
vb Code:
Original - vb Code
  1. Dim sText As String
  2. Dim sDate As String
  3. Dim sName As String
  4. Dim sAge As String
  5. Dim arrText() As String
  6. Dim count As Integer
  7.  
  8. sText = text1.text
  9.  
  10. ' Get line count
  11. count = InStr(sText, vbNewLine)
  12.  
  13. ' Size our dynamic array
  14. ReDim arrText(count)
  15.  
  16. ' Split our text string into an array housing individual lines
  17. arrText = Split(sText, vbNewLine, -1, 1)
  18.  
  19. ' Pull the last 3 strings from our array, ignoring any and all before it
  20. sDate = arrText(Ubound(arrText) - 3)
  21. sName = arrText(Ubound(arrText) - 2)
  22. sAge = arrText(Ubound(arrText) - 1)
  23.  
  24. ' Parse each line for ": " followed by data entry and reassign to our variable
  25. sDate = Right(sDate, Len(sDate) - 4)
  26. sName = Right(sName, Len(sDate) - 4)
  27. sAge = Right(sAge, Len(sDate) - 3)
__________________
Don't like me? Click it.

Scripting problems? Windows questions? Ask the Windows Guru!

Stay up to date with all of my latest content. Follow me on Twitter!

Help us help you! Post your exact error message with these easy tips!

Last edited by Nilpo : February 8th, 2007 at 01:50 AM.

Reply With Quote
  Trader Rating: 0 · #20  
Old January 3rd, 2007, 04:22 PM
Salchester Salchester is offline
Contributing User
Dev Hardware Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 293 Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 1 Day 23 h 37 m 7 sec
Reputation Power: 6
Thats the problem, i forgot to mention ealier that the textbox contains the following (including to new lines after "<Name> has sent the following information:"):

<Name> has sent the following information:


Date: 12/12/06
Name: Bill
Age: 19

Is there anyway the code can be adapted, to search the hole field, i.e. Date:, Name: Age:, with the ":" as if the data contains a ":" the program will get confused, and will therfore extract incorrect information.

Many Thanks, much appreciated
P.S Sorry to be a pain in the arse!!!!

Reply With Quote
  Trader Rating: 2 · #21  
Old January 3rd, 2007, 05:29 PM
Nilpo's Avatar
Nilpo Nilpo is offline
Dev Hardware God 1st Plane (5500 - 5999 posts)
 
Join Date: May 2004
Location: Salem, OH
Posts: 5,729 Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)  Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1
Time spent in forums: 1 Month 1 Week 6 Days 2 h 34 m 48 sec
Reputation Power: 10408
Send a message via ICQ to Nilpo Send a message via AIM to Nilpo Send a message via MSN to Nilpo Send a message via Yahoo to Nilpo Send a message via Google Talk to Nilpo Send a message via Skype to Nilpo Send a message via XFire to Nilpo
Facebook MySpace Orkut
Quote:
Originally Posted by Salchester
Thats the problem, i forgot to mention ealier that the textbox contains the following (including to new lines after "<Name> has sent the following information:"):

<Name> has sent the following information:


Date: 12/12/06
Name: Bill
Age: 19

Is there anyway the code can be adapted, to search the hole field, i.e. Date:, Name: Age:, with the ":" as if the data contains a ":" the program will get confused, and will therfore extract incorrect information.

Many Thanks, much appreciated
P.S Sorry to be a pain in the arse!!!!
I fixed all of those in my last code.

Reply With Quote
  Trader Rating: 0 · #22  
Old January 3rd, 2007, 06:51 PM
Salchester Salchester is offline
Contributing User
Dev Hardware Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 293 Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 1 Day 23 h 37 m 7 sec
Reputation Power: 6
Quote:
Originally Posted by Nilpo
I fixed all of those in my last code.
What you mean this code?

Code:
Dim sText As String
Dim sDate As String
Dim sName As String
Dim sAge As String
Dim arrText() As String
Dim count As Integer

sText = text1.text

' Get line count
count = InStr(sText, vbNewLine)

' Size our dynamic array
ReDim arrText(count)

' Split our text string into an array housing individual lines
arrText = Split(sText, vbNewLine, -1, 1)

' Pull the last 3 strings from our array, ignoring any and all before it
sDate = arrText(Ubound(arrText) - 3)
sName = arrText(Ubound(arrText) - 2)
sAge = arrText(Ubound(arrText) - 1)

' Parse each line for ": " followed by data entry and reassign to our variable
sDate = Right(sDate, Len(sDate) - 4)
sName = Right(sName, Len(sDate) - 4)
sAge = Right(sAge, Len(sDate) - 3)
Many Thanks, much appreciated!

Reply With Quote
  Trader Rating: 0 · #23  
Old January 3rd, 2007, 10:52 PM
Salchester Salchester is offline
Contributing User
Dev Hardware Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 293 Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 1 Day 23 h 37 m 7 sec
Reputation Power: 6
The code you post previously, doesn't search the textbox for the field names "Date:, Name:, & Age:" inorder to extract the data shown below.

Also if the contents of the textbox was to include an additional ":" say within the data, the program returns the wrong value.

Is there anyway the code can be adapted, to search the hole field, i.e. Date:, Name: Age:, with the ":" as if the data contains an additional ":" within the data, the program STILL gets confused, and extracts incorrect information.

CURRENT TEXTBOX CONTENTS:

Date: 12/12/06
Name: Bill
Age: 19

DATA EXTRACTED FROM TEXTBOX

12/12/06
Bill
19

Many Thanks, much appreciated!
P.S Sorry to be a pain in the arse! :-)

Last edited by Salchester : January 3rd, 2007 at 11:09 PM.

Reply With Quote
  Trader Rating: 2 · #24  
Old January 4th, 2007, 09:22 AM
Nilpo's Avatar
Nilpo Nilpo is offline
Dev Hardware God 1st Plane (5500 - 5999 posts)
 
Join Date: May 2004
Location: Salem, OH
Posts: 5,729 Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)  Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1
Time spent in forums: 1 Month 1 Week 6 Days 2 h 34 m 48 sec
Reputation Power: 10408
Send a message via ICQ to Nilpo Send a message via AIM to Nilpo Send a message via MSN to Nilpo Send a message via Yahoo to Nilpo Send a message via Google Talk to Nilpo Send a message via Skype to Nilpo Send a message via XFire to Nilpo
Facebook MySpace Orkut
This code is working for me....show me exactly how you want your code output to look.

Reply With Quote
  Trader Rating: 0 · #25  
Old January 4th, 2007, 10:39 AM
Salchester Salchester is offline
Contributing User
Dev Hardware Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 293 Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 1 Day 23 h 37 m 7 sec
Reputation Power: 6
As email messages from Outlook Express, are going to be displayed one-by-one inside the textbox, the textbox will contain the same fields, but not necessarily the same data.

Can the code actually search the textbox for the below field names/strings and then extract the following data, as currently the fields are just trimmed out.

Date:
Name:
Age:


This is OK, only the textbox doesn't always contain the same information, for example the Name field may contain a long name and then a shorter name, leading to the program returning incorrect or partial data.

Many Thanks, much appreciated!!!

Last edited by Salchester : January 4th, 2007 at 11:21 AM.

Reply With Quote
  Trader Rating: 2 · #26  
Old January 4th, 2007, 12:10 PM
Nilpo's Avatar
Nilpo Nilpo is offline
Dev Hardware God 1st Plane (5500 - 5999 posts)
 
Join Date: May 2004
Location: Salem, OH
Posts: 5,729 Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)  Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1
Time spent in forums: 1 Month 1 Week 6 Days 2 h 34 m 48 sec
Reputation Power: 10408
Send a message via ICQ to Nilpo Send a message via AIM to Nilpo Send a message via MSN to Nilpo Send a message via Yahoo to Nilpo Send a message via Google Talk to Nilpo Send a message via Skype to Nilpo Send a message via XFire to Nilpo
Facebook MySpace Orkut
Quote:
Originally Posted by Salchester
As email messages from Outlook Express, are going to be displayed one-by-one inside the textbox, the textbox will contain the same fields, but not necessarily the same data.

Can the code actually search the textbox for the below field names/strings and then extract the following data, as currently the fields are just trimmed out.

Date:
Name:
Age:


This is OK, only the textbox doesn't always contain the same information, for example the Name field may contain a long name and then a shorter name, leading to the program returning incorrect or partial data.

Many Thanks, much appreciated!!!
Dude, trust me. I've already taken all of that into consideration. It will work. I've fully tested it here.

Reply With Quote
  Trader Rating: 0 · #27  
Old January 4th, 2007, 12:20 PM
Salchester Salchester is offline
Contributing User
Dev Hardware Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 293 Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 1 Day 23 h 37 m 7 sec
Reputation Power: 6
It doesn't work properly. If the textbox contains the following:

Bill has sent the following information:


Date: 12/12/06
Name: Bill
Age: 19


..... the data extracted is as follows:

: 12/12/06
: Bill
Age: 19


instead of.......

12/12/06
Bill
19


and if the data is changed to the following:

Peter Harper has sent the following information:


Date: 12/12/2006
Name: Peter Harper
Age: 19


...... the data extracted is follows:

: 12/12/2006
r Harper
Age: 19


instead of........

12/12/2006
Peter Harper
19


What needs to be changed to avoid this?

Many Thanks, much appreciated!

Last edited by Salchester : January 4th, 2007 at 12:48 PM.

Reply With Quote
  Trader Rating: 2 · #28  
Old January 4th, 2007, 01:59 PM
Nilpo's Avatar
Nilpo Nilpo is offline
Dev Hardware God 1st Plane (5500 - 5999 posts)
 
Join Date: May 2004
Location: Salem, OH
Posts: 5,729 Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)  Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1
Time spent in forums: 1 Month 1 Week 6 Days 2 h 34 m 48 sec
Reputation Power: 10408
Send a message via ICQ to Nilpo Send a message via AIM to Nilpo Send a message via MSN to Nilpo Send a message via Yahoo to Nilpo Send a message via Google Talk to Nilpo Send a message via Skype to Nilpo Send a message via XFire to Nilpo
Facebook MySpace Orkut
Shouldn't be doing that....let me take another look.

Reply With Quote
  Trader Rating: 0 · #29  
Old January 4th, 2007, 02:07 PM
Salchester Salchester is offline
Contributing User
Dev Hardware Newbie (0 - 499 posts)
 
Join Date: Aug 2005
Posts: 293 Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level)Salchester User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 1 Day 23 h 37 m 7 sec
Reputation Power: 6
Quote:
Originally Posted by Nilpo
Shouldn't be doing that....let me take another look.
OK!!!

Many Thanks, much Appreciated!

Reply With Quote
  Trader Rating: 2 · #30  
Old January 4th, 2007, 02:35 PM
Nilpo's Avatar
Nilpo Nilpo is offline
Dev Hardware God 1st Plane (5500 - 5999 posts)
 
Join Date: May 2004
Location: Salem, OH
Posts: 5,729 Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)Nilpo User rank is General 141st Grade (Above 100000 Reputation Level)  Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1Folding Points: 214558 Folding Title: Super Ultimate Folder - Level 1
Time spent in forums: 1 Month 1 Week 6 Days 2 h 34 m 48 sec
Reputation Power: 10408
Send a message via ICQ to Nilpo Send a message via AIM to Nilpo Send a message via MSN to Nilpo Send a message via Yahoo to Nilpo Send a message via Google Talk to Nilpo Send a message via Skype to Nilpo Send a message via XFire to Nilpo
Facebook MySpace Orkut
Sorry, there were typos in the last section.....try this:
vb Code:
Original - vb Code
  1. Dim sText As String
  2. Dim sDate As String
  3. Dim sName As String
  4. Dim sAge As String
  5. Dim arrText() As String
  6. Dim count As Integer
  7.  
  8. sText = text1.text
  9.  
  10. ' Get line count
  11. count = InStr(sText, vbNewLine)
  12.  
  13. ' Size our dynamic array
  14. ReDim arrText(count)
  15.  
  16. ' Split our text string into an array housing individual lines
  17. arrText = Split(sText, vbNewLine, -1, 1)
  18.  
  19. ' Pull the last 3 strings from our array, ignoring any and all before it
  20. sName = arrText(Ubound(arrText) - 3)
  21. sDate = arrText(Ubound(arrText) - 2)
  22. sAge = arrText(Ubound(arrText) - 1)
  23.  
  24. ' Parse each line for ": " followed by data entry and reassign to our variable
  25. sName = Right(sName, Len(sName) - 4)
  26. sDate = Right(sDate, Len(sDate) - 4)
  27. sAge = Right(sAge, Len(sAge) - 3)

Last edited by Nilpo : February 8th, 2007 at 01:51 AM.

Reply With Quote
Reply

Viewing: Dev Hardware ForumsSOFTWAREProgramming > Parsing Strings


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump




 Free IT White Papers!
 
How to Present Effectively Online
This white paper offers practical and actionable advice on the key steps that any presenter should consider as they plan and execute a Webinar or online meeting.

 
Open Source Security Myths
Open Source Software (OSS) is computer software whose source code is available to the general public with relaxed or non-existent intellectual property restrictions (or arrangement such as the public domain), and is usually developed with the input of many contributors.

 
Power and Cooling Capacity Management for Data Centers
This paper describes the principles for achieving power and cooling capacity management.

 
Scalable, Fault-Tolerant NAS for Oracle - The Next Generation
For several years NAS has been evolving as a storage alternative for Oracle databases, and for good reason: NAS is quite often the simplest, most cost-effective storage approach for Oracle. Learn about the benefits that HP's approach to scalable NAS brings to Oracle environments in this comprehensive white paper.

 
Understanding Web Application Security Challenges
This white paper discusses many common threats and preventive measures for Web application security, and explains what you can do to help protect your organization.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
     
 




© 2003-2009 by Developer Shed. All rights reserved. DS Cluster 4 Hosted by Hostway
For more Enterprise Application Development news, visit eWeek