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

Search:

Type: Posts; User: Hacker2

Page 1 of 6 1 2 3 4

Search: Search took 0.04 seconds.

  1. Replies
    4
    Views
    674

    Re: Resource classes - help getting started

    When I started writing for win32, I wondered: should I stay with just win32api, or just I use Microsoft Foundation Classes?

    I went with MFC, and it was a good idea.
    Much complexity in building a...
  2. Re: How to determine floppy type (3.5" or other)?

    /*
    To get the disk type is pretty tricky.
    There are different methods for NT and win9x
    and there are several different functions to call.
    But here is the complete example.

    in your code, put...
  3. Thread: Adding a Menu

    by Hacker2
    Replies
    1
    Views
    680

    Re: Adding a Menu

    No you do not need to use a resource.
    It is just easier to do it that way.
    For example, Visual Studio has a resource editor
    which makes building menus very simple.

    But if you want to do it by...
  4. How to drop multiple files from different folders?

    Hello All,
    if I have a drive\path\filename.ext,
    I know how to do drag & drop by getting the itemidlist of the file


    LPSHELLFOLDER pFolder;
    ::SHGetDesktopFolder(&pFolder);

    //widepath is the...
  5. Replies
    2
    Views
    828

    Re: ZOrder Problem with ToolBar WIN32

    I am sorry to say, but it is hard to understand your English.

    Usually, a childwindow is behind the toolbar,
    and the childwindow is behind the menu too.

    This is because the toolbar is created...
  6. Replies
    18
    Views
    1,833

    Re: Paint Like Program Help

    programmers often acquire flat spots
    from slapping themselves on the forehead
    when they spot a bug :)
  7. Replies
    2
    Views
    1,025

    Re: CEdit scrollbar capture

    First off, that thing in the center of the scroll bar that you grab
    with the mouse is called the "Thumb".

    This is important to know, because there is an SB_THUMBTRACK
    parameter that is used...
  8. Replies
    18
    Views
    1,833

    Re: Paint Like Program Help

    Hello Mrafcho001
    BitBlt is the function you use to transfer the image
    from the memory dc to the screen dc.

    This article will explain memory dc's for you...
  9. Re: Printing Problem: Something to do with bitmaps?

    In theory, printing is simple, and is just like drawing on the screen:
    1) You receive a device context for printing.
    2) You figure out the dimensions of that context, and draw in it.

    But in...
  10. Thread: Clipboard

    by Hacker2
    Replies
    11
    Views
    1,436

    Re: Clipboard

    What you get depends on how you get it.

    GetClipboardData(CF_TEXT)
    returns ascii text only. No fonts, no colors.

    Other text attributes of text could be pasted,
    ony if those attributes were...
  11. Replies
    4
    Views
    1,274

    Re: combine buffers

    You need to provide much more information.

    BYTE Buf (512 Bytes)

    is not a valid c++ line

    and on the same topic, neither is
    LPBYTE BUF1 (10MB)

    what exactly are your declarations?
  12. Replies
    4
    Views
    3,427

    Re: MFC ? error? Include File: AFXWIN.H ??

    I think you need to say
    #include <AfxWin.h>

    instead of just
    include <AfxWin.h>
  13. Replies
    6
    Views
    959

    Re: Char Array acts weird.

    One of the difficult things with compilers,
    is that sometimes the error message have nothing
    whatsoever to do with the actual problem.

    The problem is in

    char boardX[queens][queens];

    when...
  14. Re: Does anyone help us (we are badly needing you)

    Please give us the email address of your teacher.
    We will send the answer there.

    -Or-

    You could figure out how to do the work yourself,
    which is the purpose of taking the course.

    Suppose...
  15. Replies
    2
    Views
    644

    Re: Please Help me write this code

    Codeguru does not exist to do your homework for you.
    You must learn to do your homework yourself.

    You need to learn to program on your own.

    One of the most basic things a programmer does,
    is...
  16. Replies
    13
    Views
    1,728

    Re: VS halts while debugging vc program

    "Hey my program doesn't work, what's wrong?"
    is impossible to answer.
    We need much much more information.

    Please attach zip file of your program.
    Do NOT include .ncb files
    Do NOT include .obj...
  17. Replies
    8
    Views
    1,775

    Re: "Doorbell" button

    I think LbtnDn and LbtnUp is the only way.
    But there is a problem with lbtnDn:
    1) Click the button control
    2) Keep the mouse button held down.
    3) Move the mouse cursor away from the button...
  18. Replies
    3
    Views
    718

    Re: Please Help me write this code

    There are many things to learn as a programmer.

    One of the most basic is,
    to take a flowchart and turn it into code.

    If you do not know how to do this,
    then you must learn how, on your own,...
  19. Replies
    3
    Views
    807

    Re: collecting file names

    jmcilhinney is right. I put up an example oft C code.
    I didn't notice the VBNet topic heading : 0
  20. Replies
    3
    Views
    807

    Re: collecting file names

    CStringArray FileNameArray;
    HANDLE hFileFind=NULL; //handle of file found by FindFile function
    WIN32_FIND_DATA FileFindData;
    int ReturnCode;

    hFileFind=FindFirstFile("C:\\MyDirectory\\*.*,...
  21. Thread: Clipboard

    by Hacker2
    Replies
    11
    Views
    1,436

    Re: Clipboard

    There was an error in my code for getting the text.
    You need to close the clipboard before exiting.
    So the correct code is


    int ReturnCode;

    ReturnCode = IsClipboardFormatAvailable(CF_TEXT);...
  22. Replies
    12
    Views
    1,664

    Re: Selected item in the tree control

    Hello pskumaran
    The tree control only selects an item when you left-click it.
    if you want to select an item by right-click, you must add this yourself.

    In MFC, it is like this:
    in .h file
    ...
  23. Replies
    7
    Views
    764

    Re: Need 0.013487 but I have 1.3487e-02

    You could remove the trailing zeros manually:


    char temp[100];
    sprintf(temp, "%f",matrizo[i][j]);

    int k = strlen(temp);

    if(k > 0) k--; //avoid zero-length string problems
  24. Thread: Classes

    by Hacker2
    Replies
    4
    Views
    895

    Re: Classes

    The first answer is easy:

    1) Declare parentclass last
    2) Before declaring childclass, tell it that there is a parentclass



    class parentclass;

    class childclass
  25. Replies
    7
    Views
    8,705

    Re: Loading a .rtf into a richtextbox on load

    Hello Destination,

    I know you are frustrated and did not find mcilhinney's first answer useful,
    but once, when I answered a question and the guy responded like that,
    I did not give him further...
Results 1 to 25 of 146
Page 1 of 6 1 2 3 4





Click Here to Expand Forum to Full Width

Featured