Visual C++(CLR) How to add an item to a listbox from a different form
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3

Thread: Visual C++(CLR) How to add an item to a listbox from a different form

  1. #1
    Join Date
    Jun 2017
    Posts
    1

    Exclamation Visual C++(CLR) How to add an item to a listbox from a different form

    So I am creating a windows app using windows forms in Visual C++, and I created this button in the main form (starting form) to open up a form called form 2. So to open this form I used form2's header to declare it and open it. From there form2 will load processes in a listbox and then u select a process you want from the list then click a button to add that selected item to another listbox in the starting form. But I have no idea on how to do it no matter what I do wether its forward declarations in other headers its just not working

    PLEASE SOMEONE HELP

    Thanks

  2. #2
    2kaud's Avatar
    2kaud is offline Super Moderator Power Poster
    Join Date
    Dec 2012
    Location
    England
    Posts
    5,450

    Re: Visual C++(CLR) How to add an item to a listbox from a different form

    It would be helpful if you could post the code.
    All advice is offered in good faith only. You are ultimately responsible for the effects of your programs and the integrity of the machines they run on. Anything I post, code snippets, advice, etc is licensed as Public Domain https://creativecommons.org/publicdomain/zero/1.0/

    C, C++ Compiler: Microsoft VS2017.2

  3. #3
    Join Date
    Jun 2010
    Location
    Germany
    Posts
    2,661

    Re: Visual C++(CLR) How to add an item to a listbox from a different form

    Your description is pretty vague and yes, it would be helpful to see your code. But you mention forward declarations, which may be a hint into the direction of a mutual inclusion problem. Regarding this, see, for instance, http://forums.codeguru.com/showthrea...is-not-working
    I was thrown out of college for cheating on the metaphysics exam; I looked into the soul of the boy sitting next to me.

    This is a snakeskin jacket! And for me it's a symbol of my individuality, and my belief... in personal freedom.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This a Codeguru.com survey!


On-Demand Webinars (sponsored)