Balkendiagramm darstellen ?



  • Dann erstell sie doch zur Laufzeit !

    MSDN:

    CProgressCtrl::Create
    BOOL Create( DWORD dwStyle, const RECT& rect, CWnd* pParentWnd, UINT nID );

    Return Value

    TRUE if the CProgressCtrl object is successfully created; otherwise FALSE.

    Parameters

    dwStyle

    Specifies the progress bar control’s style. Apply any combination of window styles, in addition to the following progress bar control styles, to the control:

    PBS_VERTICAL Displays progress information vertically, top to bottom. Without this flag, the progress bar control displays horizontally, left to right.

    PBS_SMOOTH Displays gradual, smooth filling in the progress bar control. Without this flag, the control will fill with blocks.
    rect

    Specifies the progress bar control’s size and position. It can be either a CRect object or aRECT structure. Because the control must be a child window, the specified coordinates are relative to the client area of the pParentWnd.

    pParentWnd

    Specifies the progress bar control’s parent window, usually a CDialog. It must not be NULL.

    nID

    Specifies the progress bar control’s ID.

    Remarks

    You construct a CProgressCtrl object in two steps. First call the constructor, which creates the CProgressCtrl object; then call Create, which creates the progress bar control.

    Example

    CProgressCtrl myCtrl;

    // Create a smooth child progress control.
    myCtrl.Create(WS_CHILD|WS_VISIBLE|PBS_SMOOTH, CRect(10,10,200,30),
    pParentWnd, 1);

    CProgressCtrl Overview | Class Members | Hierarchy Chart

    See Also CProgressCtrl::CProgressCtrl

    --------------------------------------------------------------------------------
    Send feedback to MSDN.Look here for MSDN Online resources.



  • mmhhh.....

    irgend wie klappt das nicht....

    CProgressCtrl pBar[100];
    	pBar[1].Create(WS_CHILD|WS_VISIBLE|PBS_SMOOTH, CRect(10,10,30,100), this, 1); 
    	pBar[2].Create(WS_CHILD|WS_VISIBLE|PBS_SMOOTH, CRect(40,10,60,100), this, 1);
    

    Gruß
    andy_mann



  • Hallo,
    kann mir jemand Helfen ??

    ich bekomme mehrere CProgressCtrl nicht zum Darstellen.

    Gruß
    andy_mann



  • Mal was anderes,

    wo muß ich die Dinger eigentlich Generieren ??

    Habe ein CFormView, auf dem es dargestellt werden soll.

    Momentan versuche ich es in OnInitialUpdate zu generieren..

    Gruß
    andy_mann



  • Irgendwie ist das ganze Ding Kääässseee...

    ich muß einen CProzessCtrl 2* initialisieren ??
    Im Konstruktor und OnCreate ??

    habe deshalb eine Funktion generiert, die mir die ProzessCtrl Kette generiern soll.

    Mit einem Array Funktioniert es...
    aber mit einem Vector nicht:

    void CEqualizerDialog::CreateProzessCtrl()
    {
    	// PBS_VERTICAL | PBS_SMOOTH | WS_BORDER
    	for(int i=0;i<10;i++)
    	{
    		pBar.Create(WS_CHILD|WS_VISIBLE|PBS_VERTICAL|PBS_SMOOTH | WS_BORDER, CRect(10,10,20,100), this, i);
    
    		m_vProzessListe.push_back(pBar);
    	}
    }
    

    Noch blöder ist es, dass ich Die Kette noch mit OnSize an das Fenster anpassen muß, dabei gibt es bei create schon eine größen Angabe.

    Kann mir jemand Helfen ??

    Gruß
    andy_mann



  • STOP.

    Was willst du da mit einem CProzessCtrl.
    Willst du dir 30 solche Dingens erstellen wenn du ein Monat darstellst.
    Wenn du ein View hast dann zeichne dort einfach.
    Wenn du einen Dialog hast
    http://www.codeproject.com/miscctrl/#Charting+Controls

    das ganze nennt sich Chart.
    Es gibt auch von MS ein Control.



  • Hallo Unix-Tom,

    ich brauche eine Live Darstellung von mehreren Daten.
    Diese stellen einen Stand dar, der variren kann.

    Deswegen brauche ich einen ProzessCtrl.
    Geht das nicht mit dem ??

    Es kann sich um über 100 solcher Dinger handeln...

    Gruß
    andy_mann



  • Und?
    Warum soll das mit einen Chart nicht gehen. Schau dir mal Emule an. Da sind die Daten auch Live. Glaubst du die machen das mit einem Progress



  • Also Chart sagt mir jetzt gar nichts.

    Gibt es dazu auch ein Steuerelement ??

    Gruß
    andy_mann



  • Hab dir doch einen Link gegeben.


Anmelden zum Antworten