Search Results

Showing results 1 to 40 of 359
Search took 0.03 seconds.
Search: Posts Made By: jencas
Forum: C++ 27 Days Ago
Replies: 3
Solved: file.close
Views: 191
Posted By jencas
Maybe a file2.clear() would be helpful because upon completion of the first loop the eof bit remains set.
Forum: C++ Sep 23rd, 2009
Replies: 2
Views: 162
Posted By jencas
It seems that the compiler you are using, does not know "#pragma comment". Because it is only a comment, just remove these statements from the source code.
Forum: C++ Sep 23rd, 2009
Replies: 8
Views: 238
Posted By jencas
Or maybe you have a const method and you try to decrement a member variable in this method.
Forum: C++ Sep 21st, 2009
Replies: 10
Views: 385
Posted By jencas
No, he is using managed C++.NET and the .NET String!!!
Forum: C++ Sep 7th, 2009
Replies: 2
Views: 214
Posted By jencas
And use a std::map<std::string, int> to count the occurences of the words in the file:
- if you cannot find the word in the map, then create a new map entry for that word with the int set to 1
- if...
Forum: C++ Sep 4th, 2009
Replies: 3
Views: 275
Posted By jencas
Maybe this works for normal years, but not for leap years.
Forum: C++ Sep 4th, 2009
Replies: 4
Views: 293
Posted By jencas
Do you have RichEdit Controls in your dialog? If yes, did you add a call to AfxInitRichEdit() to CYourApp::InitInstance()?
Forum: C++ Sep 2nd, 2009
Replies: 3
Views: 314
Posted By jencas
This is Windows code, not Linux.
Forum: C++ Aug 31st, 2009
Replies: 2
Views: 162
Posted By jencas
maybeb you should start with something like:


std::string createString(int i)
{
// create the string of "level i"
}

for (int i = 1; i <= 5; ++i)
{
Forum: C++ Aug 31st, 2009
Replies: 5
Views: 161
Posted By jencas
WinMain() -> http://msdn.microsoft.com/en-us/library/ms633559%28VS.85%29.aspx

p.s. and please.... you have 101 posts and should be able to give your request a meaningful title!
Forum: C++ Aug 31st, 2009
Replies: 2
Views: 157
Posted By jencas
I personally prefer this one:
http://www.amazon.com/Programming-Principles-Practice-Using-C/dp/0321543726/ref=sr_1_1?ie=UTF8&s=books&qid=1251713747&sr=1-1
Forum: C++ Aug 31st, 2009
Replies: 3
Views: 270
Posted By jencas
You could possibly handle the WM_KILLFOCUS (or EN_KILLFOCUS or whatever) event of editbox1.
Forum: C++ Aug 28th, 2009
Replies: 2
Views: 250
Posted By jencas
What is the second list in

typedef std::list<list*> List;


or do you mean


typedef std::list<std::list*> List;
Forum: C++ Aug 27th, 2009
Replies: 2
Views: 333
Posted By jencas
... and perform the outer loop in reverse direction to avoid problems with overlooking the next element after erasing or index going out of bounds when erasing the last element
Forum: C++ Aug 25th, 2009
Replies: 8
Views: 251
Posted By jencas
Usually std::map is implemented using a rb-tree (red-black-tree) and not a B-tree (Bayer-tree)
Forum: C++ Aug 25th, 2009
Replies: 4
Views: 271
Posted By jencas
Move this


int sum1 = numX - numZ;
int sum2 = numX - numY + numZ;
int sum3 = numX + numY;

int sum4 = numX + numY + numZ;
int sum5 = numX;
int sum6 = numX - numY...
Forum: C++ Aug 21st, 2009
Replies: 6
Views: 594
Posted By jencas
Then mark this thread as solved, please
Forum: C++ Aug 21st, 2009
Replies: 5
Views: 199
Posted By jencas
Show what you've done so far.



I don't think so.
Forum: C++ Aug 21st, 2009
Replies: 6
Views: 594
Posted By jencas
If the COM1 port is in use by an other process, this resource is locked by the OS and subsequent tries to open the COM1 port will fail.
Forum: C++ Aug 20th, 2009
Replies: 2
Views: 437
Posted By jencas
Hamming Code C++ (http://tinyurl.com/nkkzao)
Forum: C++ Aug 20th, 2009
Replies: 1
Views: 186
Posted By jencas
I just took a short glance at your code. The second call to SortHeap works on an already sorted array, so maybe it's better to sum up the return values of the first call


int main()
{
int i,...
Forum: C++ Jul 23rd, 2009
Replies: 13
Solved: dayOfYear
Views: 499
Posted By jencas
This code works (cut 'n paste it and try it on www.codepad.org):


#include <iostream>

using namespace std;

int dayNumber(int year, int month, int day)
{
int...
Forum: C++ Jul 23rd, 2009
Replies: 7
Views: 622
Posted By jencas
Can't believe that you have searched.... google("change background color CTabCtrl") gives many hits, i.e.

http://www.codeguru.com/forum/archive/index.php/t-141641.html
Forum: C++ Jul 23rd, 2009
Replies: 7
Views: 622
Posted By jencas
You can find many examples on www.codproject.com and www.codeguru.com. Just search!!!
Forum: C++ Jul 23rd, 2009
Replies: 2
Views: 226
Posted By jencas
UL-Speed = (amount of data)/(time to send that amount of data), so if you need 5 secs to send 1000 KB you have a speed of 200 KB/s.
Forum: C++ Jul 22nd, 2009
Replies: 4
Views: 270
Posted By jencas
Did you try to debug step by step?
Forum: C++ Jul 21st, 2009
Replies: 4
Views: 334
Posted By jencas
Translation for beginners ;)

search Google for: CTreeCtrl background image
select the second topic found (@codeguru.com)
Forum: C++ Jul 21st, 2009
Replies: 2
Views: 224
Posted By jencas
Probably because C# puts declaration and definition into the same file and they use the same code base for C++/CLI
Forum: C++ Jul 21st, 2009
Replies: 4
Views: 228
Posted By jencas
...or a Snake like game
Forum: C++ Jul 21st, 2009
Replies: 4
Views: 334
Posted By jencas
int main()
{
HTMLPage& page = google("CTreeCtrl background image");
page.select2nd(topic);
}
Forum: C++ Jul 21st, 2009
Replies: 3
Views: 171
Posted By jencas
Do you mean std::list?
Forum: C++ Jul 21st, 2009
Replies: 6
Views: 459
Posted By jencas
fout.close();


surely should be outside the while loop
Forum: C++ Jul 21st, 2009
Replies: 3
Views: 336
Posted By jencas
COrder() {::memset(this,0,sizeof(*this));}


I really hope that you know what you are doing here....
Forum: C++ Jul 21st, 2009
Replies: 6
Views: 459
Posted By jencas
while (true)
{
if (!fin.good()) break;

string lineFromFile;
getline(fin, lineFromFile);
cout << lineFromFile << endl;
} // while
Forum: C++ Jul 21st, 2009
Replies: 6
Views: 459
Posted By jencas
Any error messages from the compiler? I only get a warning, which can be eliminated by changing


for (int i = 0; i < s.length(); i++) // for each char in the string...


to


for...
Forum: C++ Jul 20th, 2009
Replies: 7
Solved: Newbie here :D
Views: 285
Posted By jencas
... and not to forget: http://www.daniweb.com/forums/thread78223.html
Forum: C++ Jul 20th, 2009
Replies: 2
Views: 206
Posted By jencas
You are calling askText() in the ctor of StoryWordManager as well as in the main() program.
Forum: C++ Jul 17th, 2009
Replies: 4
Views: 150
Posted By jencas
You declared an array with 9 elements, but generate_array() and print_array() operate on 10-element-arrays

You have three options:
1. pass the size of the array as an additional parameter to...
Forum: C++ Jul 16th, 2009
Replies: 4
Views: 290
Posted By jencas
strcpy() is for copying null-terminated C-strings, but you have only a single char(acter).
Forum: C++ Jul 16th, 2009
Replies: 2
Views: 317
Posted By jencas
Use std::vector instead of an array.
Showing results 1 to 40 of 359

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC