Click here to Skip to main content
15,921,226 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Crystal report 8.5 with vb 6.0 Pin
AJAYWVK8729-Jul-08 2:28
AJAYWVK8729-Jul-08 2:28 
GeneralRe: Crystal report 8.5 with vb 6.0 Pin
DJ Matthews29-Jul-08 3:36
DJ Matthews29-Jul-08 3:36 
GeneralRe: Crystal report 8.5 with vb 6.0 Pin
AJAYWVK8729-Jul-08 4:47
AJAYWVK8729-Jul-08 4:47 
GeneralRe: Crystal report 8.5 with vb 6.0 Pin
DJ Matthews29-Jul-08 4:57
DJ Matthews29-Jul-08 4:57 
GeneralRe: Crystal report 8.5 with vb 6.0 Pin
Vimalsoft(Pty) Ltd29-Jul-08 4:57
professionalVimalsoft(Pty) Ltd29-Jul-08 4:57 
Question[Message Deleted] Pin
AJAYWVK8729-Jul-08 0:26
AJAYWVK8729-Jul-08 0:26 
AnswerRe: Can i trap crystal report pop up msg in vb 6.0 Pin
Vimalsoft(Pty) Ltd29-Jul-08 1:48
professionalVimalsoft(Pty) Ltd29-Jul-08 1:48 
QuestionArray trouble Pin
tatchung28-Jul-08 22:47
tatchung28-Jul-08 22:47 
Hello,

I'm creating a parser for some logs derived from ssh. I used an array to split the logs for every "next line" I encounter then I have to go through all those lines again (one by one) to check for certain keywords. My problem is after going through the 1st index, the 2nd index acquires a "next line" at the beginning meaning my search can't function accurately. My question is how do I remove that line at the beginning of my 2nd index? I've tried TRIM and REPLACE but none of it doesn't seem to work. Many thanks for any help you could give me. Smile | :)

Oh by the way I'm prehistoric...this is done in vb6 Smile | :)

Here's my code:

a = txtSam.Text
strarray = Split(a, Chr(13))
For b = 0 To 3
strarray(b) = Replace(strarray(b), Chr(13), "")
strarray(b) = Trim(strarray(b))
    If Mid(strarray(b), 21, 4) = "[15]" Then
        pos1 = InStr(1, strarray(b), "<")
        strurl = Mid(strarray(b), pos1)
        strurl = Replace(strurl, "<", "")
        strurl = Replace(strurl, ">", "")
        strurl = Trim(strurl)
    ElseIf Mid(strarray(b), 21, 4) = "Sent" Then
        pos1 = InStr(1, strarray(b), "[msg")
        pos2 = InStr(1, strarray(b), "[udh")
        str1 = Mid(a, pos1, pos2 - pos1)
        str1 = Replace(str1, "[msg:", "")
        str1 = Trim(str1)
        str1 = Mid(str1, InStr(1, str1, ":") + 1)
        str1 = StrReverse(str1)
        str1 = Mid(str1, 2)
        str1 = StrReverse(str1)
    End If
Next b


Aim small, miss small

AnswerRe: Array trouble Pin
paas29-Jul-08 0:40
paas29-Jul-08 0:40 
GeneralRe: Array trouble Pin
tatchung29-Jul-08 0:54
tatchung29-Jul-08 0:54 
QuestionHow to add a button column to the datagrid using vb.net2003 Pin
g.hanuman28-Jul-08 22:40
g.hanuman28-Jul-08 22:40 
AnswerRe: How to add a button column to the datagrid using vb.net2003 Pin
tatchung28-Jul-08 22:58
tatchung28-Jul-08 22:58 
AnswerRe: How to add a button column to the datagrid using vb.net2003 Pin
chandralekha4-Aug-08 20:06
chandralekha4-Aug-08 20:06 
QuestionHow do I detect which Application get focus at run-time? Pin
Anubhava Dimri28-Jul-08 22:05
Anubhava Dimri28-Jul-08 22:05 
AnswerRe: How do I detect which Application get focus at run-time? Pin
Thomas Stockwell29-Jul-08 10:31
professionalThomas Stockwell29-Jul-08 10:31 
QuestionHow to read excel file Pin
BalasubramanianK28-Jul-08 20:48
BalasubramanianK28-Jul-08 20:48 
AnswerRe: How to read excel file Pin
Nilesh Hapse28-Jul-08 22:36
Nilesh Hapse28-Jul-08 22:36 
AnswerRe: How to read excel file Pin
rprateek5-Aug-08 17:50
rprateek5-Aug-08 17:50 
QuestionHow to color some cells of table row based upon condition [modified] Pin
Rameez Raja28-Jul-08 18:26
Rameez Raja28-Jul-08 18:26 
AnswerRe: How to color some cells of table row based upon condition Pin
Paul Conrad28-Jul-08 20:06
professionalPaul Conrad28-Jul-08 20:06 
Questionproblem to detect client after server crash Pin
shee_dee8628-Jul-08 15:22
shee_dee8628-Jul-08 15:22 
AnswerRe: problem to detect client after server crash Pin
Luc Pattyn28-Jul-08 16:16
sitebuilderLuc Pattyn28-Jul-08 16:16 
QuestionFlippable 3D List Items in WPF Pin
sumeetneo28-Jul-08 10:16
sumeetneo28-Jul-08 10:16 
AnswerRe: Flippable 3D List Items in WPF Pin
ChandraRam29-Jul-08 1:23
ChandraRam29-Jul-08 1:23 
GeneralRe: Flippable 3D List Items in WPF Pin
sumeetneo29-Jul-08 4:24
sumeetneo29-Jul-08 4:24 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.