Click here to Skip to main content
15,893,564 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: ProgressBar (Vista) How do I: Split a PB to a few internal colors with different colors, and merging a Percentage indicator label within it? Pin
Dave Kreskowiak26-Dec-07 2:10
mveDave Kreskowiak26-Dec-07 2:10 
GeneralRe: ProgressBar (Vista) How do I: Split a PB to a few internal colors with different colors, and merging a Percentage indicator label within it? Pin
Shimmy Weitzhandler26-Dec-07 14:56
Shimmy Weitzhandler26-Dec-07 14:56 
GeneralRe: ProgressBar (Vista) How do I: Split a PB to a few internal colors with different colors, and merging a Percentage indicator label within it? Pin
Dave Kreskowiak27-Dec-07 5:04
mveDave Kreskowiak27-Dec-07 5:04 
GeneralRe: ProgressBar (Vista) How do I: Split a PB to a few internal colors with different colors, and merging a Percentage indicator label within it? Pin
Shimmy Weitzhandler30-Dec-07 8:57
Shimmy Weitzhandler30-Dec-07 8:57 
QuestionCan a Label.BackColor be transparent? Pin
Shimmy Weitzhandler25-Dec-07 16:48
Shimmy Weitzhandler25-Dec-07 16:48 
GeneralRe: Can a Label.BackColor be transparent? Pin
Nilesh Hapse25-Dec-07 18:49
Nilesh Hapse25-Dec-07 18:49 
GeneralRe: Can a Label.BackColor be transparent? Pin
Shimmy Weitzhandler26-Dec-07 15:01
Shimmy Weitzhandler26-Dec-07 15:01 
GeneralLineInput LineFeed problem Pin
MohammadAmiry24-Dec-07 21:23
MohammadAmiry24-Dec-07 21:23 
Hi I have a very large file in whose format is like this:
KEYWORD
SomeInformationLines

KEYWORD
SomeInformationLines

I need to pass through the file and save the position of each keyword, so that when later, user wants me
to read the keyword data from the file, I can seek to the position of the keyword and read the data.

The problem is some files are unix format (i.e. their lines end with linefeed, Chr(10), only rather than CR-LF, Chr(13)+Chr(10)).
This is My Code:
FileOpen(1,FileName)

Do Until EOF(1)
    strLine = LineInput(1)
    If IsKeyword(strLine) Then
        SaveKeywordPosition( strLine, Seek(1) )
        ' The above line is where the bug comes from:
        ' e.g if the line is empty, and only an LF is in it, Seek(1) returns 2!!
        ' i.e. it virtually adds a CR and this is done for all further lines too.
        ' But whem I use Seek(1, aPreviouslySavedPosition) it goes exactly to where
        ' it should go, without accounting for extra CRs which it added while reading
                    ' the file.
    End If
Loop

FileClose(1)


I also have tried to with InputString function, StreamReader and FileStream classes and check the last character of
the line manually, but the IO was raises from 800KB/s to 18MB/s and runtime from 15sec to 2min.

Could someone please tell me how should I handle this?!
GeneralRe: LineInput LineFeed problem Pin
Dave Kreskowiak26-Dec-07 6:14
mveDave Kreskowiak26-Dec-07 6:14 
Generalarrary of button Pin
break_day24-Dec-07 4:06
break_day24-Dec-07 4:06 
GeneralRe: arrary of button Pin
darkelv24-Dec-07 4:34
darkelv24-Dec-07 4:34 
GeneralRe: arrary of button Pin
DigiOz Multimedia24-Dec-07 6:32
DigiOz Multimedia24-Dec-07 6:32 
GeneralRe: arrary of button Pin
break_day27-Dec-07 4:45
break_day27-Dec-07 4:45 
GeneralGet graphics Pin
The real $M@24-Dec-07 2:47
The real $M@24-Dec-07 2:47 
GeneralRe: Get graphics Pin
Paul Conrad24-Dec-07 5:11
professionalPaul Conrad24-Dec-07 5:11 
GeneralRe: Get graphics Pin
The real $M@26-Dec-07 3:14
The real $M@26-Dec-07 3:14 
GeneralRe: Get graphics Pin
Luc Pattyn24-Dec-07 5:12
sitebuilderLuc Pattyn24-Dec-07 5:12 
GeneralSerializable control. Pin
divyesh143224-Dec-07 1:19
divyesh143224-Dec-07 1:19 
GeneralRe: Serializable control. Pin
Manikandan.net25-Dec-07 22:57
Manikandan.net25-Dec-07 22:57 
GeneralMySQL Visual Basic API compunent control Pin
cedonulfi23-Dec-07 22:49
cedonulfi23-Dec-07 22:49 
GeneralRe: MySQL Visual Basic API compunent control Pin
Dave Kreskowiak24-Dec-07 4:59
mveDave Kreskowiak24-Dec-07 4:59 
GeneralRe: MySQL Visual Basic API compunent control Pin
nishkarsh_k24-Dec-07 18:05
nishkarsh_k24-Dec-07 18:05 
GeneralTry and Catch Pin
nishkarsh_k23-Dec-07 20:38
nishkarsh_k23-Dec-07 20:38 
GeneralRe: Try and Catch Pin
Michael Sync23-Dec-07 21:25
Michael Sync23-Dec-07 21:25 
Questionwebusercontrols Pin
mvkrishnas23-Dec-07 17:01
mvkrishnas23-Dec-07 17:01 

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.