Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
~7K People Reached
Favorite Forums
Favorite Tags
c++ x 26
c x 2
Member Avatar for driplet

I need to read a txt file as data input. The format of the txt data is: ... x x C C x x C x x C C C ... where x represent numeric value, C is charater, and the same format repeated many times, but may change to …

Member Avatar for Lerner
0
87
Member Avatar for driplet

Hi there: I need to copy character data from one class A to another class B. In Class A, I defined a character variable: char v1[30]; In Class B, I defined another character variable: char v2[30]; In Class A, I read v1 from a txt file and want to copy …

Member Avatar for Dave Sinkula
0
167
Member Avatar for driplet

Hi there: I defined several variables and assigned them values (nonzero) on a form. But I always got zero values of them when I cite them from another form. I am using BCB and never met this problem before even when I was doing the similar things. Can somebody give …

Member Avatar for MrGobroski
0
125
Member Avatar for driplet

Can any body tell me how to change a Cancel button to Ok button after a process finished? (maybe just change the caption of the button? I guess) Thank you in advance!

Member Avatar for mitrmkar
0
90
Member Avatar for driplet

Hi there: I am trying to output a single variable to a binary file, but couldn't get it done correctly. [code] result = 17.0; if ((OutFp1 = fopen("myfile.bin", "wb")) == NULL) { Application->MessageBox("File can't open.", NULL, IDOK); return; } fwrite(&result,sizeof(result), 1, OutFp1); fclose(OutFp1); if ((InFp15 = fopen("myfile.bin", "rb")) == NULL) …

Member Avatar for driplet
0
115
Member Avatar for driplet

I use the following code to read data from a txt file: File2Open = "data.dat"; if((In=fopen(File2Open,"rt")) == NULL) { Application->MessageBox("Open data file failed.", NULL, MB_OK); return; } handle = open(File2Open, O_RDONLY); do { Readin1; Readin2; }while(!eof(handle)); Readin1 and Readin2 are two subroutines and consist of many lines of fscanf(In,"%s",&TTT) to …

Member Avatar for Salem
0
104
Member Avatar for driplet

The function is as follows: void Runthrough(double * from, double * to, double * when, double * howmuch) { nflows += 1; if (nflows > LENFST) { /* Stack Overflow */ Application->MessageBox("Error occurred.", MB_OK); return; } else { /* Store the arguments in the stack */ flowstack[nflows].from = from; flowstack[nflows].to …

Member Avatar for Duoas
0
133
Member Avatar for driplet

Hi masters: I got an error message when I was compiling my code: "E2293 ) expected" It indicates some thing wrong in a line on which I defined a function. There are a lot of arguments in this function and some ones are array. I checked this section many times …

Member Avatar for driplet
0
148
Member Avatar for driplet

In FORTRAN, we can have a common data block in which all exchanging data are stored. When a subroutine/function needs data from the data block, it can automatically get them from the data block if the program found data with the same variable name. In C++, I am wondering how …

Member Avatar for Ancient Dragon
0
114
Member Avatar for driplet

Hi there: I need to convert a variable of single character to corresponding ASCII number. Can some body tell me how to do this? I tried int(), static_cast(), atoi(), not working. Thx in advance!

Member Avatar for Narue
0
448
Member Avatar for driplet

there is a intrinsic function, ichar(C), to convert character to a numerical value (ASCII?) in FORTRAN. Can any one tell me a similar function in C++?

Member Avatar for Ancient Dragon
0
86
Member Avatar for driplet

I need to input a space, a tab, and a comma from keyboard and then judge if the input is a space, a tab, or a comma. I used the following code but it doesn't work. bool ST, COMMA; AnsiString HH; HH = Edit1->Text; strcpy(CR, HH.c_str()); if (CR == " …

Member Avatar for Narue
0
4K
Member Avatar for driplet

Can any body tell me how to convert the following Fortran arrays to C++? CHARACTER ST1*10 CHARACTER ST*(*) Thank you in advance!

Member Avatar for WaltP
0
167
Member Avatar for driplet

I have the following code, but compiling error message: "cannot convert parameter 1 from 'float' to 'float " when I call flow(v1, v2, v3, v4). Could any one out there help me to find the problem and fix it? Thank you! [code] #include "stdafx.h" #include <stdio.h> #include <stdlib.h> #define Length …

Member Avatar for Salem
0
172
Member Avatar for driplet

In BCB, I need to pass a two dimensional array to a function Ratio. I did this without pointers or reference. Could any body else tell me what I should revise if I want to use pointers or reference for input? [code] double Ratio(double a[3], double VA[3][3], int i) { …

Member Avatar for driplet
0
139
Member Avatar for driplet

Hi guys: I am using Borland C++ Builder to make a window application. I need to use a list box to display the items I selected. Besides, I need to chang the order of the selected items in the box. Could any body please give me a clue how I …

Member Avatar for WolfPack
0
530