Solved

Saving Data Like A Log Book

Posted on 1999-01-16
5
186 Views
Last Modified: 2010-05-03
How do you save data(text) so it can be loaded later for further referance. Like a sports log book?
0
Comment
Question by:gordolove
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 3

Expert Comment

by:traygreen
ID: 1469047
The data can be saved either in a database, flat file or binary file
Are you looking for a simple file solution?
0
 
LVL 3

Expert Comment

by:traygreen
ID: 1469048
a simple ascii text file example
Private Sub WriteRecord(pName As String, pSport As String, pPosition As String)
   Open "c:\temp.txt" For Output As #1
   Write #1, pName, pSport, pPosition
   Close #1
End Sub
0
 

Author Comment

by:gordolove
ID: 1469049
I keep getting error messages when I try the string. I am new at this, so what do I have to custimize to get it to work?
0
 
LVL 1

Accepted Solution

by:
carlosvs earned 100 total points
ID: 1469050
If you need a log file try this:
sub WriteLog(LFile as String,LogTitle as String, LogText as String)
     Open LFile For Append As #1
     print #1, LogTitle & ": " & LogText
     close #1
end sub

example:
WriteLog "C:\MyFile.txt","Start UP","The Aplication Start"
This program will append to the Lfile...
0
 
LVL 1

Expert Comment

by:carlosvs
ID: 1469051
if you need to see your log in a form try
Rich Textbox Control.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
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…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses
Course of the Month9 days, 23 hours left to enroll

623 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