Does someone know a C++ funktion that returns the number of lines of a .txt File?
Type: Posts; User: overspray
Does someone know a C++ funktion that returns the number of lines of a .txt File?
Hi,
I`m trying to read Hexnumbers of a text file, bytewise, and send them through a serial port, one after the other. with the same routine I want to receive a message.
The following routine...
Hi,
I`mworking on a cnc application, which involves some c++ programming.
I wonder what would be an upper limit for array size?
If I'd store all individual steps of a steppermotor in an array, it...
I figured it out by trial.
But I dont understand how it works.
buff[8] , (sscanf(&buff[0], "%x", &x[i]) reads out the 1. row (x)
buff[9] , (sscanf(&buff[2], "%x", &x[i]) reads out the 2....
Here´s the complete code:
It does everything twice.
#include<iostream.h>
#include<stdio.h>
#include<conio.h>
#include<ctype.h>
//-------------------------------------------------
Hi,
I`m trying to read the first out of two collums.
Im using the sscanf function, and get one surprise after the other.
Why is the following code printing everything twice?
FILE...
I`m not shure.I think it should be sent as one byte, sunce that`s what the µp processes at he other end.
Is that what happens when I hit a key of the keyboard?
the [][] contain the indexes of the...
Hi,
I´d like to send hexnumbers through the serial interface of a PC to a µ processor.
It works with a terminal, when I hit a key, for example 'a', 0100001 is stored in the µp register.
This I`d...
My programm reads out the first 2 Numbers of a hpgl plotfile, calculates the distance between those coordinates, and writes acordingly to the distance ones and zeros to another file.
Two long rows...
HI,
at school we`re going to use MS Visual c++ version6.0.
I`m having a hard time with it, maybe I`m doing something wrong.
The first thing I found, or better didn`t find was the help section.
I...
void __fastcall TForm1::Button1Click(TObject *Sender)
{
int i,d,z;
char c[5];
for(i=0;i<=7;i++) {
z++;
c[i]= Edit1->Text[z]; // c... Data being generated
}
HI,
When I run the ISexpress, I get my program installed lets say c:\programs\myprog.exe
I then drag&drop the Icon onto the desctop.
Under the Icon it says:"linked to myprog .exe ".
Is it...
How can I create or where do I find Icons (*:ico)to use in the Builder3.
How can I place a jpg.on a Form?
Is there a way to convert .bmp to .ico with the Builders imageEditor ?
How can I...
Hi,
This code works fine:
#include<iostream.h>
#include<stdio.h>
#include<conio.h>
#include<ctype.h>
Hi,
Im using this code to address my ComPort:
#pragma hdrstop
#include <condefs.h>
#pragma argsused
#include <iostream.h>
#include <stdio.h>
Hi,
#include <fstream>
using namespace std; [/code ]
Can anyone give me the entire code to get the printer to work on the cbuilder?
I`m not familiar with namespace.
this always...
Hi,
I`m using the following code:
freopen("RPN","w",stdout);
or:
#include<fstream.h>
void main()
{
I`m using a rutine that works fine using this char array.
char Data[8]={'-','1','3','4','5','6','7'};
I`d like to enter these chars through a TextField,
in this form :
...
Anyone programming his TI calc in c here`s a fine input routine to enter numbers.Only problem is,that at the end, function atof will not convert the string properly when compiled with TIGCC IDE.
The...
Actually I have nothing against white spaces and I am concerned about readability but it looks like that I`m not very good at it.Input is float type, and her`s the eintire code:Its for my TI...
I`m using the following code and it works fine till the last line.atof should convert a string to float.It works fine with atoi(ansi to int).With the atof it turns out weird numbers in the range of...