Search:

Type: Posts; User: ineedmunchies

Page 1 of 2 1 2

Search: Search took 0.01 seconds.

  1. Replies
    2
    Views
    2,572

    Hey thanks for the reply, I got this working ok. ...

    Hey thanks for the reply, I got this working ok.

    I used the struct declarations, then the extern declarations inside the header. Outside of the header i gave the actual definition of the struct...
  2. Replies
    2
    Views
    2,572

    Multiple Definition Error

    Ok so i'm trying to put together a simple graphics program, following the nehe gamedev tutorials. I'm currently trying to load in some tga graphics files to memory.

    I have a header file that is...
  3. Replies
    3
    Views
    2,098

    It will be for the user to solve. Stacks appear...

    It will be for the user to solve. Stacks appear to be exactly what I'm looking for. Thanks for the help :)
  4. Replies
    3
    Views
    2,098

    Towers Of Hanoi

    I'm looking to create a version of the url=http://en.wikipedia.org/wiki/Tower_of_Hanoi]towers of hanoi[/url] problem using C++. If your unfamiliar with the game, it involves moving hoops from one peg...
  5. Replies
    5
    Views
    7,027

    Ah very good idea, I think I'm doing exactly...

    Ah very good idea, I think I'm doing exactly that.

    Ha yip I was indeed, very silly little mistake. Thank you.

    Hmmm now to find if I can allign centrally in the middle of the rectangle!

    Hmmm...
  6. Replies
    5
    Views
    7,027

    Thank you novacain, I've tried as you have said...

    Thank you novacain, I've tried as you have said but I still cannot get it to work properly.

    It does not clear the rectangle that the text is being displayed in.


    case WM_COMMAND:
    ...
  7. Replies
    5
    Views
    7,027

    InvalidateRect() + DrawText()

    Ok, so i've been trying to have a rectangle that fills with new text each time a button is pressed. I've got it all working except for it deleting the previous text before writing any new text, so I...
  8. Replies
    3
    Views
    12,778

    How are variables stored in memory.

    Ok so i'm just trying to clear up how different variables are stored in memory/on the stack.

    Say there is a program with global variables, a function that has varibale declared within it, and a...
  9. Replies
    6
    Views
    1,700

    Ok so I've just discovered the DrawText function,...

    Ok so I've just discovered the DrawText function, I'm going to play around with that some to see if I can get it to work with the window I want :) Sorry for the silly questions, I've had to jump in...
  10. Replies
    6
    Views
    1,700

    Ok yes that does help a lot. I'm very tired today...

    Ok yes that does help a lot. I'm very tired today and struggling to get this done, thats why I came to ask for help.

    Is messagebox not a pop up window? What I am looking to do is have a window...
  11. Replies
    6
    Views
    1,700

    Getting a button to perform a function

    Ok so I've created a windows program, it has a main window and two child windows, one of which is a button. What I want to do is for the button to run a function, and then display the results of that...
  12. Replies
    29
    Views
    11,234

    Hey thanks guys, got it working :) "A Healthy...

    Hey thanks guys, got it working :)

    "A Healthy Suit
    A healthy suit kept in accordance with the amused elbow
    Deceivingly the suit left
    The elbow threw in place of a ugliest jam"

    Ha not the...
  13. Replies
    29
    Views
    11,234

    Ok so yet another issue, I'm trying to create a...

    Ok so yet another issue, I'm trying to create a function that will create a different vector for each file I read from.


    void vectorize (fstream in_file, vector<string> out_vector)
    {while...
  14. Replies
    29
    Views
    11,234

    Ha sorry, i just realised that and edited it as...

    Ha sorry, i just realised that and edited it as you were posting there. Thank you guys.
  15. Replies
    29
    Views
    11,234

    Ah well spotted thank you. So instead of j

    Ah well spotted thank you. So instead of
    j<i you would suggest

    EDIT::
    j<strVector.size
  16. Replies
    29
    Views
    11,234

    int j=0; for (j; j

    int j=0;
    for (j; j<i+1; j++){
    cout << strVector[j];
    cout << "\n";

    Oopps sorry bit rusty.

    It runs now, and prints them to screen but still throws up error. Saying that the exe has...
  17. Replies
    29
    Views
    11,234

    Ok thank you, I will try that. It works great...

    Ok thank you, I will try that. It works great thank you. Now i am trying to print out the strings read from the file.


    #include <iostream>
    #include <vector>
    #include <string>
    #include...
  18. Replies
    29
    Views
    11,234

    Ok so I tried working with istream iterator, and...

    Ok so I tried working with istream iterator, and I just don't get it, so I've gone back to using loops that I understand instead.


    #include <iostream>
    #include <vector>
    #include <string>...
  19. Replies
    29
    Views
    11,234

    Ok so I'm trying this, and I want to read from...

    Ok so I'm trying this, and I want to read from the file I have open, but surely std::ifstream is not enough? I need to give the filename somehow?


    std::ifstream myfile;
    myfile.open...
  20. Replies
    29
    Views
    11,234

    So your argument is in favour of using the scope...

    So your argument is in favour of using the scope operator?

    Does std::vector mean that vector is a component of class std, which is included in the preprocessor directives? And this would be the...
  21. Replies
    29
    Views
    11,234

    Ha well when I said phrases I was actually...

    Ha well when I said phrases I was actually talking about prepositions. And other things that need more than one word sometimes.

    The format I've been given is:
    A <adjective1> <noun1> <verb1>...
  22. Replies
    29
    Views
    11,234

    Well it will need to access 12 random...

    Well it will need to access 12 random words/phrases from 5 different lists. Would it be safe to have 5 different vectors (I'm assuming thats what is meant by that code, I'm very new to C++ I've just...
  23. Replies
    29
    Views
    11,234

    Random Poem Generator

    Ok, so as an assignment I have been asked to create a random poem generator.
    I have been provided with the format for the poem to take so thats not an issue, what I need to work out, is how to...
  24. Replies
    9
    Views
    4,092

    Hmm well I have it running now and working with...

    Hmm well I have it running now and working with this code:


    BYTE image[imagesize1];
    fread(image, 1, imagesize1, fileA);
    for(i=0; i<imagesize1; i++)
    {
    image[i]=~image[i];
    }...
  25. Replies
    9
    Views
    4,092

    What about pixel, i had been defining that as...

    What about pixel, i had been defining that as char because it was one byte long, but it could be defined as BYTE couldn't it? I just remembered that its in one of the header files. I had been using...
Results 1 to 25 of 40
Page 1 of 2 1 2