15,300 Posted Topics

Member Avatar for happygeek

I believe that number also includes all the spammers and porn posters and wouldn't be a bit surprised if they account for about half or more the total membership. Maybe Dani should just delete all those accounts and see what happens to the total membership.

Member Avatar for TrustyTony
0
477
Member Avatar for Taibah

If you are looking for a book and have the money then [URL="http://www.amazon.com/Win32-Programming-Addison-Wesley-Advanced-Windows/dp/0201634929"]this is a good one to buy.[/URL]

Member Avatar for mytich
0
182
Member Avatar for ashrafu1

The first error listed is the most important. The problem is more than likely caused by mis-matched brackets, probably missing a closing } somewhere. Start counting open/closing brackets to find out which one is missing. You are also missing brackets around the multi-line else statement on line 64.

Member Avatar for Ancient Dragon
0
603
Member Avatar for Dexxta27

using one *.cpp as an include in another *.cpp is a BIT NO-NO. Create a project and add both *.cpp files to it. The compiler will compile each *.cpp file and then link them both together, along with other libraries that the program may use. You will see the advantage …

Member Avatar for Dexxta27
0
121
Member Avatar for Doughnuts

This is a prime example of why I hate typdef of plain-old-data-types. It's very difficult to keep track of what's a char* and what's a char**. variable [b]a[/b] is declared on line 9 as char**, and memory allocated for each rows on line 27. So far, so good. No problem …

Member Avatar for Ancient Dragon
0
169
Member Avatar for ben25x

VB can access any dll written in C language, but C++ DLLs have to have special handling, such as the DLL either has to use extern "C" to make the DLL exported functions C style functions or the VB program has to know about name mangling, and you will have …

Member Avatar for Ancient Dragon
0
433
Member Avatar for Smartflight

>>Ok, so time() function (argument being null) returns what? It returns the number of seconds since 1970, as you previously posted. It doesn't matter whether the parameter is NULL or not, it will always return the same value.

Member Avatar for Smartflight
0
267
Member Avatar for fabricetoussain

try using stringstream class [code] #include <sstream> ... std::string line = "8:30 AM"; int hour, minute; std::string ampm; char temp; stringstream s(line); s >> hour >> temp >> minute >> ampm; [/code]

Member Avatar for fabricetoussain
0
333
Member Avatar for dospy

you want to rename main.h to myclass.h so that the name of the file tells you what's in the file. Other than that, there is little, if any, difference between the two methods. It's all a matter of programming style. I prefer the first method when one header file depends …

Member Avatar for dospy
0
116
Member Avatar for emreozpalamutcu

win32 project will require you to learn details of win32 api functions. That can be very time consuming with about a year's learning curve to learn it well. You can do useful things in a lot less time than that. Windows Forms is grad-and-drop, but is C++/CLR, not c++. C++/CLR …

Member Avatar for emreozpalamutcu
0
135
Member Avatar for davidcraigster

IMHO the easiest way to count letter frequencies is to use an array of 255 elements -- which is large enough to count all possible characters. Then you can just use the letter itself as the index into the array. Like this simple example: You would put this in a …

Member Avatar for Ancient Dragon
0
836
Member Avatar for llamaboy

There's a couple ways to avoid storing that extra '\n' at the end of the text file. One way is like this: [code] ofstream myfile("Stock.txt"); if (myfile.is_open()) { for(int i=0; i <8; i++) myfile << number[i] <<endl; myfile << number[i]; } [/code]

Member Avatar for llamaboy
0
3K
Member Avatar for HASHMI007

What do you need help with? We can't help you if you can't tell us.

Member Avatar for Ancient Dragon
1
104
Member Avatar for pseudorandom21

[URL="http://msdn.microsoft.com/en-us/library/a2c7tshk.aspx"]Here is a Microsoft article[/URL] you will want to study. I'm not sure that C# can access DLLs written by non-.NET languages.

Member Avatar for mike_2000_17
0
778
Member Avatar for DaniwebOS

What compiler are you using? I compiled with vc++ 2010 express on MS-Windows and did not get any linking errors.

Member Avatar for Ancient Dragon
-1
137
Member Avatar for ddcc

line 17: p is an uninitialized iterator so the while statement fails. You might want to initiazlize it to p = NumList.begin() before line 17. That won't fix the problem either. Another problem: what happens when the number of elements in NumList is less than the value of q? In …

Member Avatar for ddcc
0
170
Member Avatar for Jennifer84

ReadToEnd() will not read into that String^ vector. It requires a buffer of contiguous memory. If you want to read that file line-by-line then use the example in the link below. [URL="http://msdn.microsoft.com/en-us/library/db5x7c0d.aspx"]Example here[/URL]

Member Avatar for jonsca
0
360
Member Avatar for TailsTheFox
Member Avatar for virtue

Your formatting leaves a lot to be desired. It's a lot easier to read and debug if you only put one statement on a line instead of trying to put several on the same line. Most debuggers can't work with that formatting style. Once you learn how to format your …

Member Avatar for sourabh17
0
136
Member Avatar for TailsTheFox

[QUOTE=ziggystarman;1515610]try #include "windows.h"[/QUOTE] Depends on the compiler. That won't work with vc++ 2010 (or any earlier version of Microsoft compilers). On some other compilers it doesn't matter whether you use quotes or angle brackets. Check your computer to see if it already contains windows.h and associated headers/libraries. If it does, …

Member Avatar for Ancient Dragon
0
1K
Member Avatar for volkang

doubles can not be represented exactly in memory. The value of 0.1 may or may not be represented in memory as 0.100001 or something like that, and that's why incrementing 3.9 by 0.1 may cause the number to be greater than 4.0. There is little, if anything, you can do …

Member Avatar for volkang
0
88
Member Avatar for grandzbee7

You need to check the laws of the country in which you are located. Probably ask a lawyer or solicitor.

Member Avatar for Ancient Dragon
0
32
Member Avatar for alokdhari

What you are asking is how to reformat a simple text file -- csv files are just text files. Read the file one line at a time, make apprporpate changes then write the new line back out to a different file. If the file is small enough you could read …

Member Avatar for Ancient Dragon
0
94
Member Avatar for sneaker

>>I can not see any right for any government to censur or cut off people from Internet Govenments can do as they please, afterall it is the government that makes the rules. I don't like what some governments to either, but there is nothing I can do about it. I …

Member Avatar for Ancient Dragon
0
179
Member Avatar for Khoanyneosr

What compiler are you using? I just successfully compiled/linked using vc++ 2010 Express. First created an empty win32 project, added a *.cpp file and copied your code into it. Compiler and linked without any warnings or errors. Maybe you created a standard console project instead of a win32 project?

Member Avatar for Khoanyneosr
0
310
Member Avatar for peck3277

The "best" way is debatable -- here is one way. [icode] #include <windows.h> #include <stdio.h> void say_hello() { printf("Hello\n"); } int main() { for(;;) { say_hello(); Sleep(1000*10); } } [/icode]

Member Avatar for darkbreaker
0
74
Member Avatar for schrope

>>if (nights<='30') && (nights!='0') Badly formed. You need more parentheses. And a single character can not hold more than one numeric digit, so probably need to test against integers instead of charcters. [icode]if ((nights<=30) && (nights!=0))[/icode]

Member Avatar for txwooley
0
310
Member Avatar for MasterGberry

You can't decompile a DLL or *.exe, the most you can hope for is to get its assembly language code. Let's say the name of the original DLL is A.DLL and you want to write B.DLL. All you have to do is have B.DLL call the functions in A.DLL in …

Member Avatar for thekashyap
0
2K
Member Avatar for hazila

std::string.find() does not return an integer -- it returns an unsigned integer. So checking for -1 will not work. It should be checked against std::string::npos. [icode] if( s.find(t1) != string::npos) { } [/icode]

Member Avatar for Ancient Dragon
0
117
Member Avatar for Ancient Dragon

Would you put a link to the Top of the page on the bottom of the page like many web sites do? Its annoying to have to use the scroll bar to scroll back up to the top.

Member Avatar for Ancient Dragon
1
44
Member Avatar for Tamlyn

You failed to include <iostream> and <string> and the [icode]using std::cin;[/icode], [icode]using std:cout;[/icode] and [icode]using std::string;[/icode] statements.

Member Avatar for Tamlyn
0
253
Member Avatar for Sotiria Sotiria

[code] int readVal(struct Telem* tm) { scanf("%d%d%d", &tm->entrytime, &tm->cust_num, &tm->waitime); } [/code]

Member Avatar for Ancient Dragon
0
589
Member Avatar for Ubiad
Member Avatar for austiine04

[URL="http://www.google.com/search?source=ig&hl=en&rlz=1G1GGLQ_ENUS397&q=c%2B%2B+pdf+library&aq=1&aqi=g10&aql=&oq=c%2B%2B+pdf"]links[/URL]

Member Avatar for jackmaverick1
0
160
Member Avatar for harinath_2007

The only way to run Turbo C on Windows 7 is to install [URL="http://www.dosbox.com/"]DosBox[/URL] and run it from there. MS-Windows no longer supports that old 16-bit code.

Member Avatar for Ancient Dragon
0
238
Member Avatar for ryannans

That doesn't need a computer program. If you enter the numbers from 1-20, then all of them will be in the range 1-50 and none of them will be in the other ranges you mentioned.

Member Avatar for arkoenig
0
229
Member Avatar for blur blur

If you want to prevent someone from entering anything other than numeric digits I would get then to enter a string instead of int, then check the string for digits. [code] char input[255] = {0}; // input buffer char *ptr; printf("Enter a number\n"); fgets(input,sizeof(input),stdin); // get keyboard // now strip …

Member Avatar for thekashyap
0
114
Member Avatar for bsquinn1451

I think you will find all the installed services in the registry HKEY_LOCAL_MACHINE/System/CurrentControlSet/Services

Member Avatar for Ancient Dragon
0
111
Member Avatar for errorlog2

If you already know a little about VB6 and VB.NET then you have probably mastered the basic concepts of variables and loops. You might want to begin learning C and C++, it doesn't matter which one you learn first.

Member Avatar for ntrncx
0
191
Member Avatar for msnasiri

You mean you want to write one, or do you want to find out if there already is one? >>(my windows compiler is visual c++ 6) You should replace it with VC++ 2010 (the Express version is free).

Member Avatar for msnasiri
0
119
Member Avatar for margeaux54

[URL="http://www.daniweb.com/software-development/cpp/threads/354015"]Is this the same problem you had 3 days ago?[/URL]

Member Avatar for margeaux54
0
244
Member Avatar for stevanity

You can use Task Manager to kill the process. Ctrl+Alt+Del will bring up the task manager.

Member Avatar for GDICommander
0
121
Member Avatar for subith86

[code] int* a = new int[4]; // allocate memory for 4 integers a[0] = GetParentVar1(); a[1] = GetParentVar2(); a[2] = GetParentVar3(); a[3] = GetParentVar4(); return a; [/code]

Member Avatar for subith86
0
176
Member Avatar for cdn88

>>avg = ass_average(int num_students, int j); When you call a function you do not put the variable types as part of the parameters. That's only for function prototypes. All you have to do it put the variable names as the parameters, like this avg = ass_average(num_students, j);

Member Avatar for Ancient Dragon
0
224
Member Avatar for Wakesta

vc++ 2010 express or Code::Blocks. Both are good C and C++ compilers with good debuggers. I prefer VC++, but for portability between MS-Windows and *nix you might want to do with Code::Blocks.

Member Avatar for Ancient Dragon
0
247
Member Avatar for makibao

I have no idea what a "student information portal" is, but from your description I would start out by coding the structure and unions. The instructions you were given most likely tell you what they should contain. As for next and previous page, write yourself a little console program that …

Member Avatar for Ancient Dragon
0
138
Member Avatar for cwarn23

The earth will end in fire. Everyone now knows that our Sun will exhaust all energy and go super nova some day, and when that happens the Earth and all other planets will burn to a crisp.

Member Avatar for GrimJack
2
358
Member Avatar for iamcreasy

>>Well, then what is the point of being NULL? Why set it to zero? In c++ NULL is just a macro (see [URL="http://en.wikipedia.org/wiki/C_preprocessor"]this link[/URL] if you don't know what a macro is) that is defined to be 0. Normally NULL is used to initialize pointers to a known address so …

Member Avatar for template<>
0
19K
Member Avatar for DJSAN10

[QUOTE=DJSAN10;1504204]m a bit confused...how can it b written in C coz again u will need a C compiler to compile it.. also if it is written in assembly..then how can the code run on different machines..i mean,assembly language would be different for different architectures,won't it..??[/QUOTE] printf() is not a built-in …

Member Avatar for DJSAN10
0
161
Member Avatar for plang007

Also tell us the purpose of the program, what its supposed to do. AFAIK the program is supposed to count the number of cats that fall from the sky when "its raining cats and dogs".

Member Avatar for Arbus
0
234

The End.