Solved

Checking for Blank Lines

Posted on 1998-10-26
3
131 Views
Last Modified: 2010-04-30
I'm scanning through a text file line by line, and need to determine whether or not the current line is blank or not.  The problem is that these lines have a varying number of blank spaces.  I assume I need to check for an absence of numeric or alphabetic characters...
0
Comment
Question by:IsleOfView
3 Comments
 
LVL 12

Accepted Solution

by:
mark2150 earned 20 total points
ID: 1441625
Try this:

IF LEN( TRIM( Text$ ) ) < 1 THEN (is blank)


0
 
LVL 2

Expert Comment

by:BergJC
ID: 1441626
You could do something like this:

For x = 1 to Len(FileString)
     If Mid$(FileString, x, 1) <> " " then
          StringIsNotBlank = True
     End-if
next
0
 

Author Comment

by:IsleOfView
ID: 1441627
Perfect!  Thanks.
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
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…
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 Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…

760 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

18 Experts available now in Live!

Get 1:1 Help Now