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

Search:

Type: Posts; User: andersod2

Page 1 of 6 1 2 3 4

Search: Search took 0.05 seconds.

  1. Replies
    2
    Views
    734

    Re: number pattern

    So it looks like you just need a counting sequence, but also need to enter a newline after so many numbers are printed. The first line has 4 numbers and on down to 1...so you could accomplish this...
  2. Thread: Array help

    by andersod2
    Replies
    7
    Views
    928

    Re: Array help

    In your inner loop (when you are comparing the guess) you are looping from 0 - MAX_GUESSES -- but you only want to loop through the guesses that exist (i.e. you have only filled out guesses from 0 -...
  3. Replies
    4
    Views
    1,434

    Re: multiple defined symbols with .lib files

    Awesome - thanks for the tip. And now wouldn't you know, surprise surprise, there are no other nefarious .objs in my .lib -- just the one that belongs there. The only other thing I can think of is...
  4. Replies
    4
    Views
    1,434

    Re: multiple defined symbols with .lib files

    Thanks for your response SMA, and you're correct - the thing I forgot to mention was that the linker options I'm using appear to *not* be linking in any libs. I've had this problem before (using VS...
  5. Replies
    4
    Views
    1,434

    multiple defined symbols with .lib files

    I have a .lib project I created which uses some stdio functions among other things. Basically it needs fopen() and a few other common c++ libraries. This usually works fine with non-MFC projects,...
  6. Replies
    1
    Views
    1,246

    difference between a portlet and a servlet

    Would it be safe to say that a portlet is just a servlet that only gives a fragment response, rather than the fully addressable HTTP response? I did find a page that describes the difference...
  7. Replies
    15
    Views
    2,619

    Re: any xml and database support in booost?

    Finally got the sample working -- am super happy with this library and don't plan to use anything else for simple xml / json any more. I modified the supplied sample code on the boost site to...
  8. Replies
    15
    Views
    2,619

    Re: any xml and database support in booost?

    Awesome, thank you! I had tried the string/ptree pair with put_child but add_child? How did you know to do that? Every time I look for samples of boost outside of the main website (which is often...
  9. Replies
    15
    Views
    2,619

    Re: any xml and database support in booost?

    Ok, this is exactly what I wanted. If only I could find something as simple for databases and I'd be in happy land.

    I compiled the sample program - unfortunately the part where they iterate the...
  10. Replies
    15
    Views
    2,619

    Re: any xml and database support in booost?

    Wow, ok I'm glad I asked if boost has this. I like what I see so far.
  11. Replies
    15
    Views
    2,619

    Re: any xml and database support in booost?

    superbonzo, do you know if a property_tree allows you to set/get attributes on a tag, as in:

    <root_tag attribute="first attribute">

    </root_tag>

    ??
  12. Replies
    15
    Views
    2,619

    Re: any xml and database support in booost?

    Ok, thanks a lot all -- I will check these out. I looked at libxml2, but it was a bit much for the simple stuff I'm doing - same goes for TinyXML. I liked CodeSynthesis better than these, but am...
  13. Replies
    15
    Views
    2,619

    any xml and database support in booost?

    Does anyone know of any support for XML parsing as well as DB interfacing in boost? If not, does anyone know any good/well-accepted libraries for doing these things in C++? I've looked a little bit...
  14. Replies
    0
    Views
    1,543

    need xml -> json converter in java

    Does anyone know of a good XML to JSON parser for Java? The one we are using now has an issue that I'm hoping is resolvable with a better parser. Basically, the issue is the parser doesn't know...
  15. Replies
    13
    Views
    15,009

    Re: volatile functions?

    Well it's a great starting example of how volatile would be necessary as a function return (thanks Regel). I would agree that such a scenario could be designed better, but if I were in charge of...
  16. Replies
    13
    Views
    15,009

    Re: volatile functions?

    forgive my dense-ness, but I still don't understand how a return value of volatile fits into the basic scenario I described above for volatile data. In other words, if I have a return value from a...
  17. Replies
    13
    Views
    15,009

    Re: volatile functions?

    Ok, that is making a bit more sense, thanks --

    laserlight try putting the volatile at the beginning -- that works for me on VS2008, and cygwin gcc. Still not sure what that means.
  18. Replies
    13
    Views
    15,009

    Re: volatile functions?

    So it's a qualifier for a class member function? Then why do compilers let you declare regular static C-style functions as volatile? Actually, now that I think about it, I still don't even...
  19. Replies
    13
    Views
    15,009

    volatile functions?

    I will probably ask this again in a year, but what is the purpose of using volatile in the case of volatile functions? With data it makes sense as I envision the compiler putting variables into...
  20. Replies
    6
    Views
    728

    Re: Why does this work?

    Yes I believe the fact that it doesn't use "this" is correct -- more specifically, because it does not use *any* other class members (which would require using "this"). Basically thec->showthis() is...
  21. Re: what is the advantage of using base class pointer to point to derived class's ob

    I think one simple answer to your question (of which there are many) might be to add about 100 more derivations of Shape. (Most of the time you can't get the real value from C++ until you get into...
  22. Re: How to make a negative or positive number = -1 or +1

    yeah I guess you could implement getSign() by just doing an AND operation on the sign bit of wheelVelocity. (Possibly works the same for signed ints as well).
  23. Replies
    7
    Views
    5,318

    Re: How to create an async function in C++?

    It sounds almost as if the conditional wait/signal is more along the lines of barrier synchronization rather than just guarding a critical section. Or as in the case of reader/writers trying to...
  24. Re: How to make a negative or positive number = -1 or +1

    No I agree your solution is probably the best -- I was counting that as a "conditionals" solution since it uses the compare -- so maybe a more specific definition of conditional would have...
  25. Re: Is there a way to get an uncaught excpetion's type?

    Although I'm sure a lot of people would agree with you on that, I wouldn't. If you read certain seminal works on C++ they will tell you it's not good to use the constructor and destructor as logical...
Results 1 to 25 of 134
Page 1 of 6 1 2 3 4





Click Here to Expand Forum to Full Width

Featured