m0fl Posted December 3, 2012 at 12:28 PM Report #485544 Posted December 3, 2012 at 12:28 PM Boas.. Tou aqui com uma duvida em vb 2010. Tenho um ficheiro de texto imaginemos neste formato #lalal #lalal #lalal #lalal 312412414,51413414,3141343141,431423423423,423423423423,4234234234 234324234234,2342342343242,4324234234234,23423432432,4234234234234 2,34234234234,32423423432,42344234234,2342342342342,4234234234,234 Como digo para apenas começar a ler a partir da 5 linha neste caso ? Para ignorar as primeiras 4 linhas.. Obrigado!
ribeiro55 Posted December 3, 2012 at 01:05 PM Report #485549 Posted December 3, 2012 at 01:05 PM Parece-me que o que queres é ignorar linhas começadas por cardinal 🙂 Algo como: Using SR As New IO.StreamReader("ficheiro.txt") While Not SR.EndOfStream Dim tmpLinha As String = SR.ReadLine If Not tmpLinha.StartsWith("#") Then 'tmpLinha tem a linha sem cardinal End If End While End Using Sérgio Ribeiro "Great coders aren't born. They're compiled and released""Expert coders do not need a keyboard. They just throw magnets at the RAM chips"
m0fl Posted December 3, 2012 at 02:36 PM Author Report #485557 Posted December 3, 2012 at 02:36 PM Perfeito 🙂 Obrigado 😉
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now