Skip to content

C / C++ / MFC

C, Visual C++ and MFC discussions

This category can be followed from the open social web via the handle c-c-mfc@forum.codeproject.com

111.5k Topics 465.7k Posts
  • To arrange n numbers in descending order ?

    json question
    6
    0 Votes
    6 Posts
    1 Views
    CPalliniC
    #include #define N 50 int main() { int num[N], i=0, count =0; printf("Enter 0 to exit entering integers.\n\nEnter your integers:\n"); do { if( scanf("%d", &num[i]) != 1) break; ++i; count++; } while ( i As an alternative, tou might use qsort: #include #include #define N 50 int comp(const void * a, const void *b) { return *(int *)b - *(int*)a; } int main() { int num[N], i=0, count =0; printf("Enter 0 to exit entering integers.\n\nEnter your integers:\n"); do { if( scanf("%d", &num[i]) != 1) break; ++i; count++; } while ( i
  • To find biggest of n numbers ?

    question
    12
    0 Votes
    12 Posts
    0 Views
    J
    Print i,j and the array values of each before and after that line.
  • While loop not working on C.

    data-structures
    18
    0 Votes
    18 Posts
    6 Views
    D
    See here. "One man's wage rise is another man's price increase." - Harold Wilson "Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons "You can easily judge the character of a man by how he treats those who can do nothing for him." - James D. Miles
  • while error ?

    question c++ game-dev help
    4
    0 Votes
    4 Posts
    0 Views
    M
    To make it working, change as following: #include #include using namespace std ; int main() { string in = " "; while ( in != "" ) { cout << "What is your name ? \n" ; cout << "[ Pres enter to end this .]\n" ; getline(cin, in ); cout << "Hello " << in << " .\n" ; } cout << "n\n\n\[ GAME OVER ]\n" ; cin.get() ; return 0; }
  • VST programing

    tutorial question
    2
    0 Votes
    2 Posts
    0 Views
    L
    VST - Google Search[^]
  • Genetic Prorgaming

    c++ graphics game-dev data-structures help
    2
    0 Votes
    2 Posts
    0 Views
    D
    See here for the answers to all of your questions. Yes, I know you did not actually ask any questions, but if you did, the link would still be considered valuable. "One man's wage rise is another man's price increase." - Harold Wilson "Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons "You can easily judge the character of a man by how he treats those who can do nothing for him." - James D. Miles
  • 0 Votes
    1 Posts
    0 Views
    No one has replied
  • Problem with array in c.

    data-structures debugging help
    1
    0 Votes
    1 Posts
    0 Views
    No one has replied
  • CPP Syntax

    question c++ tutorial lounge
    4
    0 Votes
    4 Posts
    1 Views
    B
    Well, The issue is very similar to that example. I note the curly braces and the absence of a terminating semi colon. What is the reasoning behind the syntax. Does that syntax intentionally leave out the terminating semi colon, or, is that an oversight? Going to try that! Thanks and Regards :) Bram van Kampen
  • CTreeObject class

    data-structures performance question
    3
    0 Votes
    3 Posts
    0 Views
    _
    Thank you, I have solved the problem after your idea.
  • fatal error LNK1168: cannot open x.dll for writing

    com help question announcement
    4
    0 Votes
    4 Posts
    2 Views
    H
    Happened to me as well. Attached the shell extension dll to SearchFilterHost.exe for debugging purpose, after the debugging finished I need to rebuild the dll but encountered the problem abovementioned. Solution is to stop SearchFilterHost.exe in task manager afterwards.
  • CImage processing

    question
    2
    0 Votes
    2 Posts
    0 Views
    L
    I don't actually know the answer for certain. However, it would seem logical that CImage will display the image in whatever orientation is specified in the image properties.
  • Comparing Files for Differences

    14
    0 Votes
    14 Posts
    0 Views
    L
    Take file A and split into paragraphs. Search file B for each paragraph appending them to file C when not found. Swap files A & B then repeat. You could do this in a single command line in bash I reckon.
  • Select Process image

    linux question visual-studio help workspace
    1
    0 Votes
    1 Posts
    0 Views
    No one has replied
  • Syntax error

    help linux tutorial
    12
    0 Votes
    12 Posts
    0 Views
    V
    Call me dense - but I see this as OS error / verification error and I did my best to find what parameters are expected in the control. At one point Eclipse did confirm the "file" selected. Unfortunately this TCF is pretty much dead as far as any support from the original vendor. Please consider this matter closed.
  • send notification to srvice

    c++ question
    2
    0 Votes
    2 Posts
    1 Views
    CPalliniC
    This Code Project article looks promising: Interaction between services and applications at user level in Windows Vista[^].
  • Help with no default constructor message

    help
    19
    0 Votes
    19 Posts
    0 Views
    F
    Thanks upon entry to the constructer the "this" pointer is valid Thanks
  • To create drag and drop graphics builder

    graphics tutorial
    4
    0 Votes
    4 Posts
    1 Views
    L
    I don't know, you would need to search the CodeProject Articles[^], or use Google for a wider search.
  • 0 Votes
    1 Posts
    0 Views
    No one has replied
  • 0 Votes
    4 Posts
    0 Views
    enhzflepE
    Dropping the exact error text into google didn't help you like it helped me? The very first result was the following: [C Run-Time Error R6034](https://msdn.microsoft.com/en-us/library/ms235560(v=vs.90).aspx)