Thread: copying to clipboard

  1. #16
    Registered User
    Join Date
    Jul 2004
    Posts
    67
    that's my problem dev-c++ and other free compilers are the same as piece's of crap when installed on my computer. they just don't work or i get errors all of the time.

    with my DM compiler i can get by usually with common errors that are not difficult to fix.

    is the dev-c++ update thingy working yet? i use to have it for a few months waiting for the update server go be up and back online but it never was so i just unistalled it.

  2. #17
    Sweet
    Join Date
    Aug 2002
    Location
    Tucson, Arizona
    Posts
    1,820
    Dev is awesome your probably getting outdated header warnings as for the updating just download the latest version from their site. It has always worked great for me.
    Woop?

  3. #18
    Registered User moi's Avatar
    Join Date
    Jul 2002
    Posts
    946
    Do not fear if you like digital mars though... I googled a bit and apparently DM is decently well behaved; so I'd say get acquainted with the standards and start coding by them!
    hello, internet!

  4. #19
    Registered User
    Join Date
    Jul 2004
    Posts
    67
    i'll check out dev-c++ again this weekend.


    for now i have another question. how would i go about passing an int array or an int into the SetClipboardText() called here..

    Code:
    SetClipboardText(szName,strlen(szName));
    i want to be able to do something like this

    Code:
    SetClipboardText(myarray[x],myarray[x]);
    in a for loop where x is the variable used to count through the loop.

  5. #20
    Registered User
    Join Date
    Sep 2004
    Location
    California
    Posts
    3,268
    Well the function I gave only works for text. I guess you could convert the integer to a string, and put it on the clipboard.

  6. #21
    Registered User
    Join Date
    Jul 2004
    Posts
    67
    i tried that but got ugly results. maybe i don't know how to do it correctly.

  7. #22
    Registered User
    Join Date
    Sep 2004
    Location
    California
    Posts
    3,268
    what do you mean by ugly results? What exactly are you trying to do?

  8. #23
    Registered User
    Join Date
    Jul 2004
    Posts
    67
    Code:
    char num[100] = "";
    ...
    ...
    for (int z = 0; z < 10; z++)
    {
    num = myarray[z];
    SetClipboardText(num,strlen(num));
    }

    something like that since i can't pass integers into that function.

  9. #24
    Registered User
    Join Date
    Sep 2004
    Location
    California
    Posts
    3,268
    no, each time you write something to the clipboard, it overwrites what was already there.

    Maybe create one large text string which consists of all the integers of the array separated by a newline character.

  10. #25
    Registered User
    Join Date
    Jul 2004
    Posts
    67
    that's not the problem. not compiling is the problem.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Clipboard hijack
    By stevesmithx in forum A Brief History of Cprogramming.com
    Replies: 16
    Last Post: 11-08-2008, 06:04 AM
  2. Copying a Directory to the Clipboard
    By Buiden in forum C++ Programming
    Replies: 0
    Last Post: 07-15-2005, 12:21 PM
  3. Clipboard and Custom Types
    By McClamm in forum C# Programming
    Replies: 1
    Last Post: 09-16-2004, 04:43 PM
  4. Clipboard Modifier
    By Korhedron in forum Windows Programming
    Replies: 2
    Last Post: 01-03-2004, 02:32 PM
  5. OLE Clipboard :: Win32 API vs. MFC
    By kuphryn in forum Windows Programming
    Replies: 3
    Last Post: 08-11-2002, 05:57 PM