15,300 Posted Topics

Member Avatar for John A

using vista home and ie7: I see the same behavior. Sometimes its two or three threads repeated over and over.

Member Avatar for Dani
0
145
Member Avatar for triadR

how in the world did you think you can stuff that structure into a short int ? I'd like to wear a size 32 pants too but my fat butt won't fit into it. Perform the checksum calculation on the individual members of the structure.

Member Avatar for jephthah
0
223
Member Avatar for GrimJack

[QUOTE=cscgal;641390]No but you can go into your control panel and always see all of the reputation you've received[/QUOTE] I can only see the first 15 reps. When I click on the arrow in the upper right corner of the rep box it blanks out the box and I see nothing, …

Member Avatar for Ancient Dragon
0
125
Member Avatar for Sa_FF
Re: file

don't use scanf() because it won't let you put spaces in the file name. [code] char filename[255]; // max possible length on MS-Windows printf("Enter a file name\n"); fgets(filename, sizeof(filename), stdin); // truncate the '\n' if it exists if( filename[strlen(filename)-1] == '\n') filename[strlen(filename)-1] = 0; file = fopen(filename, "a"); [/code]

Member Avatar for Sa_FF
0
215
Member Avatar for lahom
Member Avatar for Sa_FF
Re: sort

just change line 16 to use > instead of < comparison operators.

Member Avatar for Sa_FF
0
145
Member Avatar for pidven

Just look at all the programs that are running on your computer. Probably 90% of them are written in C or C++ languages. >>webdesigning -- C/C++ is not very popular for that. Java and PHP are probably the two most popular languages.

Member Avatar for Luckychap
0
111
Member Avatar for nesalang

>>g++-4.2 memJpegDecoder.cpp That is attempting to compile the *.cpp and create the executable program a.out. From the error message I assume that *.cpp file doesnot contain a main() function, which is required of all c and c++ executable programs.

Member Avatar for hazmatt
-1
241
Member Avatar for titaniumdecoy

Depends on the compiler -- most c++ compilers will complain about that.

Member Avatar for sarehu
0
101
Member Avatar for adamj2

>>How would I go about making the second payload exactly the same as the first payload? You can't without reallocating the entire string because the way the arrays are declared there is no room for expansion. BTW: neither apayload nor received_payload are null-terminated strings. When you initialize character arrays like …

Member Avatar for Ancient Dragon
0
164
Member Avatar for shriagni

you could convert one character at a time. start out by multiplying the result by 10 add the character and subtract '0', similar to how you would convert an integer [code] char inputstr[] = "123.45"; float result = 0.0F; // convert 1st character result = (result * 10) + inputstr[i] …

Member Avatar for Prabakar
0
279
Member Avatar for solaf_111

>>when we run the interface and click the button excute the programing code"proto1.exe" but the result false Do you mean ShellExecute() return 0? My guess is that you need to add the full path to the proto1.exe program. Example: [icode]ShellExecute(this->m_hWnd,"open","c:\\mydir\\proto1.exe","","", SW_SHOW );[/icode]

Member Avatar for mitrmkar
0
170
Member Avatar for rob_xx17

you can use fscanf("%f", ...) to input the values from the file. Use a counter integer to count 8 fscnaf(). [code] int i; float nums[8]; FILE* in = fopen("filename.txt"); for(i = 0; i < 8; i++) { fsscanf("%f", &nums[i]); } [/code]

Member Avatar for Prabakar
0
125
Member Avatar for titaniumdecoy

I don't think [icode]*p = new Piece[/icode] should be any concern because it won't affect [icode]Board b;[/icode] at all.

Member Avatar for titaniumdecoy
1
123
Member Avatar for solaf_111

yes, but can't help you unless you post the code. Most likely its the way you opened file2. Look at [URL="actorname[strlen(actorname)-1] ="]this description [/URL]of the second parameter. If you want to delete the previous contents of file2 then you have to add the ios::truncate flag in the open() method.

Member Avatar for Ancient Dragon
0
63
Member Avatar for newbiecoderguy

My first thought was to use the time functions in time.h standard header file, but the problem with that is that the earliest date that can be use by those functions is 1970, which clearly will not work for your program. So you will have to do the calculations yourself. …

Member Avatar for newbiecoderguy
0
955
Member Avatar for integer*09

Most files that are opened for writing are opened for exclusive use -- that denys write access by other programs and processes, and sometimes denys read access too. [quote]So in between the 1mins times can Program B copy its content and after copying delete all the content in AAA.txt?[/quote] No. …

Member Avatar for ninjaneer
0
146
Member Avatar for amrith92

>>A calculator program built using MFC dialog box You can not use the express version of those compilers to compile that code because those compilers do not support MFC. You have to buy $$$$ one of the other versions of the compiler.

Member Avatar for mitrmkar
0
261
Member Avatar for Sa_FF

line 30: [b]valar[/b] is not a member of CARD. What you want here is [b]value[/b], not valar. line 32: what is SUIT ? If it is anything other than POD (Plain Old Data) type or an enumeration then the ocmparison on line 32 can't be done like that because you …

Member Avatar for Ancient Dragon
0
278
Member Avatar for maxiam

line 21: you can delete it because the file pointer is already at the beginning of the file when it is opened. line 26: you don't need the ios::in flag because ifstream is an input stream. All you need is [icode]infile.open( filename.c_str());[/icode] >>Is there a way to use an array …

Member Avatar for maxiam
0
139
Member Avatar for himsymcpp

We need to see actual code. I suspect the problem is actually somewhere else in your program, quite possibly trashing memory somewhere during the first file read operation, or failing to delete memory when necessary making your program gobble up all the computers resources. Look at Task Manager while your …

Member Avatar for Ancient Dragon
0
128
Member Avatar for casper_wang

Hello Casper. Glad to see you joined DaniWeb. I don't know diddly squat about PHP or web development, so you will rarely see me in any of those boards. But don't hesitate to help others when needed.

Member Avatar for casper_wang
0
157
Member Avatar for HLA91

I've seen similar problems with Windows XP and earlier versions, and the only way I could resolve the problem was to reboot the computer. I'm using Vista Home now and have not had that problem with this version of Windows.

Member Avatar for HLA91
0
105
Member Avatar for JeffBot

Welcome to DaniWeb. Sorry to hear about all those problems. If you post questions/comments in one of the technical board I'm certain you can get pointers and a lot of help.

Member Avatar for MakeMoneyOnline
0
137
Member Avatar for red devils

First you have to declare a structure that is each node. If you search for "linked lists" you will get lots of examples, such as [URL="http://cslibrary.stanford.edu/103/"]this tutorial[/URL] by Stanford University.

Member Avatar for red devils
0
174
Member Avatar for iansane

line 22: The ios::ate flag does nothing for input files. Its use it intended for output files. line 19 and 26: memblock should be unsigned char because a binary byte can be any value between 0 and 255. line 33: can't do that with a binary file. cout expects a …

Member Avatar for Ancient Dragon
0
932
Member Avatar for michinobu_zoned

this is a lot simpler [code] int main(int argc, char **argv) { int sum = 0; int i; for(i = 1; i < argc; i++) sum += atoi(argv[i]); } [/code]

Member Avatar for dwks
0
2K
Member Avatar for mike issa

1) What kind of project did you create? console, win32 windows, something else? 2) what libraries did you try to link with?

Member Avatar for mike issa
0
337
Member Avatar for cam875

1. Yes. just use standard stream file i/o to sequentially read the file one line at a time. Look for the tag name, when found look for the value on that line. 2. Yes. The programmer has to write the server program in such a way that it knows what …

Member Avatar for cam875
0
185
Member Avatar for Smalls

[QUOTE=Smalls;623622Cons] [LIST] [*]No support for DVD drives lacking firmware region coding [/LIST] [/quote] That's funny because DVD works in my machine. [QUOTE=Smalls;623622Cons] [LIST] [*]New monitor needed to view Hi-Definition content [/LIST] [/quote] And why is that Vista's fault? My old anolog tv doesn't work with hi-def either, so is that …

Member Avatar for Smalls
0
523
Member Avatar for integer*09

[URL="http://msdn.microsoft.com/en-us/library/chzww271(VS.80).aspx"]Here [/URL]is how to monitor file changes in MS-Windows operating systems. You can't do it the way you are trying to.

Member Avatar for Ancient Dragon
0
140
Member Avatar for TeCNoYoTTa

1) GetData() must be declare [b]virtual[/b] in each class for that to work. 2) [icode](arr.front())->GetData();[/icode]. Don't call the GetData() method like that because the front() item in the array will most likely not be the item that was most recently added. push_back() puts the item at the tail of the …

Member Avatar for TeCNoYoTTa
0
113
Member Avatar for SteveDB

As you must have found out, the exit(0) function exits the entire program, not just the function in which it appears. It would appear you have the wrong notion about how to return from a function in C or C++ [code] int foo1() // This function will return the value …

Member Avatar for SteveDB
0
155
Member Avatar for Jennifer84

>>I wonder if it is possible to call the function void OneFunction() Don't know myself. Instead of asking us if it is possible, why don't you just try to do it yourself? If you did, what were the results?

Member Avatar for Jennifer84
0
113
Member Avatar for victornil

just google for them -- you can even buy degrees without taking one course :)

Member Avatar for Ken Sharpe
0
338
Member Avatar for scratchnloved

>>i know its a lot, but i have the rest of my life to wait for answers ^^ Then the first place to ask all those questions is google. Some of those questions depends on the operating system and compiler. google first, then come back for answers to what you …

Member Avatar for scratchnloved
0
120
Member Avatar for Synthuir

Are you talking about the digits of a number stored as text? Like this: [code] #include <iostream> #include <string> #include <wchar.h> #include <cstdlib> using namespace std; int _tmain(int argc, _TCHAR* argv[]) { std::wstring iobuf; cout << "Enter a number\n"; getline(wcin,iobuf); wcout << iobuf << "\n"; int n = _wtol(iobuf.c_str()); cout …

Member Avatar for Ancient Dragon
0
120
Member Avatar for Brent.tc

There is no portable way to do it because the number of bytes occupied by a function may vary by compiler and even within the same compiler from one compile to another. Most compilers will generate the assembly code for a program.

Member Avatar for Duoas
0
96
Member Avatar for GrimJack

I don't have a problem with gay marriage. I have heard many straight people say that gay marriage will destroy the concept of triditional marriage between a man and a woman. Nonsense. I've been married (to a woman) for 46 years and nothing gays do will diminish my marriage. Why …

Member Avatar for Ancient Dragon
0
71
Member Avatar for n00b3

what compiler are you using? I used VC++ 2008 Express and could not duplicate your problem. The only problem I had with your code is that [b]hinstDLL[/b] was undefined. I even added cout statement in MyClass constructor -- it displayed ok too. The dll file you did not post was …

Member Avatar for n00b3
0
212
Member Avatar for singal.mayank

[QUOTE=Luckychap;637192]hey its easy try it. read characters from file in a buffer until u encounter a dot(.) save that buffer which is your sentence. What say...?[/QUOTE] But what about other sentence separators such as ? and ! How about a sentence that spans lines. In the case of the second …

Member Avatar for jephthah
0
117
Member Avatar for totaljj

Which Borland compiler do you have? graphics.h and associated lib are not supported by modern 32-bit compilers, only very old MS-DOS compilers such as Turbo C and Turbo C++.

Member Avatar for totaljj
0
85
Member Avatar for singal.mayank

[QUOTE=jephthah;637122]the function that would be helpful for you here, i think, is STRTOK [/quote] Nope -- just use fgets() as previously suggested. No need to read the file one character at a time just to find line terminators because that's doing it the hard way.

Member Avatar for singal.mayank
0
164
Member Avatar for fddrummer06

when the loop at line 196 finished the value of [b]currentPtr[/b] is NULL, so the loop starting at line 209 can not execute.

Member Avatar for Ancient Dragon
0
123
Member Avatar for lahom

In the event handler for the exit button send a WM_QUIT event message to the program's main thread. More information is [URL="http://www.gamedev.net/community/forums/topic.asp?topic_id=135109"]discussed here[/URL].

Member Avatar for Ancient Dragon
0
763
Member Avatar for VernonDozier

Hello World isn't displayed because nobody is logged in. And that's probably why the file doesn't get created too. try putting the *.exe in the AllUsers startup folder C:\Documents and Settings\All Users\Start Menu\Programs\Startup I think it will then get run after someone logges into the computer.

Member Avatar for VernonDozier
0
251
Member Avatar for Alex Edwards

The [b]extern[/b] keyword is used to tell the compiler that a data object is declared in a different *.cpp or *.c file (code unit). Its required for data objects but optional for function declarations. For example, you have two *.cpp files named A.cpp and B.cpp. B.cpp has a global int …

Member Avatar for Alex Edwards
0
5K
Member Avatar for lAmoebal
Member Avatar for stephen84s
0
362
Member Avatar for dmanw100

Have you tried [URL="http://www.lvr.com/usb.htm"]USB Central[/URL] ?

Member Avatar for dmanw100
0
167
Member Avatar for sreein1986

[QUOTE=sreein1986;635737]Hi I want to tell one thing to daniweb if i click mark as solved when my thread completed and it asked again mark as unsolved it's not good, disble Mark as unsolved please and also after solved problem disble reply buttons also Just It's my suggestion only[/QUOTE] The "Mark …

Member Avatar for Ancient Dragon
0
141

The End.