Search Results - CodeGuru Forums
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

Search:

Type: Posts; User: jnmacd

Page 1 of 8 1 2 3 4

Search: Search took 0.02 seconds.

  1. Re: Code not being generated for a constructor call

    I think this is it right?...
    http://www.parashift.com/c++-faq-lite/ctors.html#faq-10.2
  2. Re: Help with C++ const char * with class member functions!

    Let me guess, it goes into an infinite loop.
    Use your debugger and step through the code.
    In fact, just step through the code in your head and determine what is going to happen.
  3. Re: Error with string as a constructor parameter?

    I can't see the link, but your compiler does not know what 'string' is.


    #include <string>

    #ifndef MAIN_H

    class MyClass
    {
    public:
  4. Replies
    14
    Views
    1,273

    Re: dynamic memory noob

    this -> name = new char[strlen(nm)] ;

    This does not allocate enough memory for


    strcpy(this->name , nm);


    Use std::string.
  5. Replies
    4
    Views
    629

    Re: Accept errors

    You should read the documentation of accept()
    It it fails, it will set the errno variable to show why it failed.
    http://www.linuxhowtos.org/manpages/2/accept.htm
  6. Replies
    9
    Views
    642

    Re: Problem running hashtable

    How about you allocate memory for 'table' in readfile()?
    Why do you even make this a pointer?



    hashtable * table;
    table->add(x);
  7. Replies
    7
    Views
    915

    Re: "Reading" from proprietary software

    Where is the current software located? On a PC? Microcontroller?

    How is the data being transmitted to the motors? RS232?
    I'm confused
  8. Replies
    2
    Views
    1,145

    SetCommState Problem

    I am using Qt with the mingw compiler.

    I'm having a problem with the SetCommState function from the Windows API.
    It seems like any time I run SetCommState, it will get itself into an infinite...
  9. Replies
    3
    Views
    959

    Re: passing IP Address as a parameter

    So when you run it through your debugger, what value gets passed?
  10. Replies
    2
    Views
    353

    Re: pointers and functions

    You declare tempNode as a pointer and to access it you use ->
    However, you are


    tempNode=tempNode.getLeftNode();

    getLeftNode() does not return a pointer according to your Node specification,...
  11. Replies
    13
    Views
    1,155

    Re: Variables overwriting each other in memory

    You are not understanding arrays. You are still not accessing within the boundaries.
  12. Replies
    13
    Views
    947

    Re: Program Idea Questions

    Qt has it's own IDE and compiler.... works great.
    I used Visual Studios for years, it only took a few days of using Qt to fall in love with it.
    I highly recommend it!
  13. Re: How do I fill variable amount of structs with a loop?

    The big problem here is that you are using char's instead of strings.
    If you want to have a function return a string value, your life will become infinitely times better if you use std::string....
  14. Replies
    13
    Views
    6,689

    Re: Circle and Radius Problem

    You currently have xPoint and yPoint set to private inside pointType. They need to be 'protected' so that circleType can inherit it.
  15. Replies
    1
    Views
    1,029

    Re: WinPcap Timestamp

    What's this have to do with C++??
  16. Replies
    13
    Views
    6,689

    Re: Circle and Radius Problem

    First order of business, get your pointType functions correct.
    What do you expect setPoint and getPoint to do?
    You currently have them both defined as accepting nothing and returning nothing.
    ...
  17. Re: What is the difference between these object instantiation methods?

    http://www.parashift.com/c++-faq-lite/ctors.html#faq-10.2
  18. Thread: Classes help

    by jnmacd
    Replies
    16
    Views
    968

    Re: Classes help

    you say you want denominator greater than zero, but in your code you ask for just the opposite.

    you need to do something like


    int denom = 0;
    while (denom <= 0)
    {
    cout << "Enter denom:...
  19. Replies
    12
    Views
    2,131

    Re: Is char s[3] = "abc" legal?

    char s[3];
    memcpy(s, "ABC", 3);


    This is asking for trouble unless you know what you are doing...
  20. Replies
    7
    Views
    509

    Re: just looking for c++ advice

    Well your code is impossible to read with all the insane formatting going on.
    I see that you have a large switch statement for month input.
    You need break statements after each case, otherwise when...
  21. Replies
    4
    Views
    458

    Re: Help with Summations in Program

    You need to wrap your cout and cin statements in {}
    Your current code is actually...



    for (x = 1; x < nRes; x = x + r_i)
    cout << "Next resistance? >";

    cin >> r_i;
  22. Thread: Menu problems

    by jnmacd
    Replies
    2
    Views
    376

    Re: Menu problems

    It will also go into an infinite loop if someone actually types 'Options'
    Same problem with the other while loops
  23. Replies
    2
    Views
    357

    Re: Have a Question!!

    No idea where to start?
    Surely you can start with


    int main()
    {
    return 0;
    }
  24. Replies
    4
    Views
    2,640

    Re: How include dll's in exe file?

    http://doc.trolltech.com/4.1/deployment-windows.html
  25. Replies
    6
    Views
    1,339

    Re: Char Array problem

    Did you forget the semicolon?
    You never told us what error message you were getting
Results 1 to 25 of 200
Page 1 of 8 1 2 3 4


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center