How to copy data from serial port to notepad,by the save button on the form without calling notead to write it in ,can we directly place the data to notepad from textbox which receving data.
thank u wating for reply
i am using this syntax by using scripting object
Dim fsys As New FileSystemObject
Dim Txtfl As TextStream
Set Txtfl = fsys.CreateTextFile(App.Path & "\" & "New Text Document.txt", True)
it displaying the text2 value on the Form ,on which i working.is there is a mistake in the Path specification i have kept "New Text Document.txt" text in the C:\Program Files\Microsoft Visual Studio\VB98 but is the path is write
Sorry veena it work 's using FileSystemobject
my mistake at defining the path for it
thank u can we add string befor pasting text data to file like if i outputing the data then in the file it should look
Output Text1.Text value
Input Text2.Text value can we do this way
OK If u want to use File hanling with "I/O" then, open File this way:
Dim FN As Long
FN = FreeFile
Open "c:\MtFile.txt" For Output As FN
'(Here File will be OverWritten)
Open "c:\MtFile.txt" For Append As FN
'(here u can modify into ths same File)
Add data to file:
Print #FN, "My First File"
If u want to read TextFile:
Open "c:\MyFile.txt" For Input As FN
Dim TStr As String
Line Input FN, TStr
And After all the operations, u need to close them :
thank u veena i tryed with u r last post on saturday which work for me .I want to know something about Needdle whih will show some fluxation when it will recieve some data ,how's the car speed shows .Is there is any control in vb6 which can be used .And i am also using Slider control in vertical position ,my problem in this it showing it 0 value at the top and maximam value at the bottom ,I want to change this setting 's i want to bring min value to bottom and max val to the top of the slider ie is from bottom to top bottom should be 0 and top should be 250 is there is any other slider we can use .Important to know about Needle Control.
Instead of Slider, why dont u use a "Flat ScrollBar"
which comes with "Microsoft Windows Common Control 2 6.0"
Make Oientation = 0 (Verical)
and give Min / Max.
For the Visual Speed, Use a Line Control and a Shape(Circle) Control, Place the Line as the adius of circle, Change the CoOrdinates (X1,Y1) of Line Control Proprtionate to the speed. keeping (X2,Y2) Fixed....
I have to log the data flowing between com ports of my instrument, through a bus, using datatap. I have to keep reading the datatap and log the data into a bin file. Also i have to capture the real time data like timestamp from the COM4 of the instrument along with data from datatap. Pls help me out as am formally familiar with VB and not much aware of Comm controls. can this required implementation be done in VB?
Am new to VB. I have learnt a lot following ur threads.
Need ur help. I have to tap data from 2 com ports from a instrument.
How can i read the data and store it into a bin file so that it can be decoded again at a later point of time. Am using VB 6.0.
rEQUEST UR HELP ASAP.
THANKS IN ADVANCE.
Start a New Thread for a New Question, otherwise your Question may go Un-noticed.
Anyway, Yes, if you want to Get Data from 2 Com ports, you have to place 2 MSComm controls on the Form. Configure them,
After Start, Store the Incoming data in 2 Seperate Text Files using FSO or Text I/O.