Herzlich Willkommen, lieber Gast!
  Sie befinden sich hier:

  Forum » C / C++ (WinAPI, Konsole) » Dringende hilfe

Forum | Hilfe | Team | Links | Impressum | > Suche < | Mitglieder | Registrieren | Einloggen
  Quicklinks: MSDN-Online || STL || clib Reference Grundlagen || Literatur || E-Books || Zubehör || > F.A.Q. < || Downloads   

Autor Thread - Seiten: [ 1 ] > 2 < [ 3 ] [ 4 ]
010
22.04.2006, 20:00 Uhr
xXx
Devil


1) arg... naja... wenn es denn dann sein muss wobei ich dir eher mal Microsoft Visual
C++ 2005 Express ans Herz legen würde--- dazu nen Tutorial:
www.germangamedev.de/index.php?site=article&id=28

Dann gehst de da auf neu->projekt und erstellst eine win32 anwendung (NICHT Konsolen-).

Da kannst du dann deinen Code von oben einfügen.

2) Ein Button wird von Windows als nichts anders als ein Fenster angesehen, allerdings ist dieses "Fenster"
deinem Anwendungsfenster untergeordnet.

Also kannst du einen Button auch ganz einfach mit CreateWindow erstellen. Auf www.win-api.de findest
du dazu auch ein Tutorial
 
Profil || Private Message || Suche Download || Zitatantwort || Editieren || Löschen || IP
011
22.04.2006, 22:02 Uhr
jeller



Danke für den tipp mit Microsoft Visual C++ 2005 ich habe jetzt ein fenster erstellt aber weiß nicht wo ich die funktion der knöpfe ein fügen muss .

hier der jetztie code:

C++:
#pragma once


namespace erstellsourcecode {

    using namespace System;
    using namespace System::ComponentModel;
    using namespace System::Collections;
    using namespace System::Windows::Forms;
    using namespace System::Data;
    using namespace System::Drawing;

    /// <summary>
    /// Summary for Form1
    ///
    /// WARNING: If you change the name of this class, you will need to change the
    ///          'Resource File Name' property for the managed resource compiler tool
    ///          associated with all .resx files this class depends on.  Otherwise,
    ///          the designers will not be able to interact properly with localized
    ///          resources associated with this form.
    /// </summary>
    public ref class Form1 : public System::Windows::Forms::Form
    {
    public:
        Form1(void)
        {
            InitializeComponent();
            //
            //TODO: Add the constructor code here
            //
        }

    protected:
        /// <summary>
        /// Clean up any resources being used.
        /// </summary>
        ~Form1()
        {
            if (components)
            {
                delete components;
            }
        }
    private: System::Windows::Forms::Button^  button1;
    private: System::Windows::Forms::Button^  button2;
    private: System::Windows::Forms::Button^  button3;
    private: System::Windows::Forms::Button^  button4;
    private: System::Windows::Forms::PictureBox^  pictureBox1;
    private: System::Windows::Forms::RichTextBox^  richTextBox1;
    private: System::Windows::Forms::RichTextBox^  richTextBox2;



    protected:

    private:
        /// <summary>
        /// Required designer variable.
        /// </summary>
        System::ComponentModel::Container ^components;

#pragma region Windows Form Designer generated code
        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        void InitializeComponent(void)
        {
            System::ComponentModel::ComponentResourceManager^  resources = (gcnew System::ComponentModel::ComponentResourceManager(Form1::typeid));
            this->button1 = (gcnew System::Windows::Forms::Button());
            this->button2 = (gcnew System::Windows::Forms::Button());
            this->button3 = (gcnew System::Windows::Forms::Button());
            this->button4 = (gcnew System::Windows::Forms::Button());
            this->pictureBox1 = (gcnew System::Windows::Forms::PictureBox());
            this->richTextBox1 = (gcnew System::Windows::Forms::RichTextBox());
            this->richTextBox2 = (gcnew System::Windows::Forms::RichTextBox());
            (cli::safe_cast<System::ComponentModel::ISupportInitialize^  >(this->pictureBox1))->BeginInit();
            this->SuspendLayout();
            //
            // button1
            //
            this->button1->Location = System::Drawing::Point(24, 38);
            this->button1->Name = L"button1";
            this->button1->Size = System::Drawing::Size(147, 23);
            this->button1->TabIndex = 0;
            this->button1->Text = L"HalloWelt1.5";
            this->button1->UseVisualStyleBackColor = true;
            this->button1->Click += gcnew System::EventHandler(this, &Form1::button1_Click);
            //
            // button2
            //
            this->button2->Location = System::Drawing::Point(24, 67);
            this->button2->Name = L"button2";
            this->button2->Size = System::Drawing::Size(147, 23);
            this->button2->TabIndex = 1;
            this->button2->Text = L"Shutdown1.0";
            this->button2->UseVisualStyleBackColor = true;
            //
            // button3
            //
            this->button3->Location = System::Drawing::Point(24, 96);
            this->button3->Name = L"button3";
            this->button3->Size = System::Drawing::Size(147, 23);
            this->button3->TabIndex = 2;
            this->button3->Text = L"If-Block1.0";
            this->button3->UseVisualStyleBackColor = true;
            //
            // button4
            //
            this->button4->Location = System::Drawing::Point(24, 125);
            this->button4->Name = L"button4";
            this->button4->Size = System::Drawing::Size(147, 23);
            this->button4->TabIndex = 3;
            this->button4->Text = L"fopen1.0";
            this->button4->UseVisualStyleBackColor = true;
            //
            // pictureBox1
            //
            this->pictureBox1->Image = (cli::safe_cast<System::Drawing::Image^  >(resources->GetObject(L"pictureBox1.Image")));
            this->pictureBox1->Location = System::Drawing::Point(329, 142);
            this->pictureBox1->Name = L"pictureBox1";
            this->pictureBox1->Size = System::Drawing::Size(114, 116);
            this->pictureBox1->TabIndex = 4;
            this->pictureBox1->TabStop = false;
            //
            // richTextBox1
            //
            this->richTextBox1->Location = System::Drawing::Point(208, 28);
            this->richTextBox1->Name = L"richTextBox1";
            this->richTextBox1->Size = System::Drawing::Size(214, 85);
            this->richTextBox1->TabIndex = 5;
            this->richTextBox1->Text = L"Hier können sie alle meine source codes meiner seite erstellen";
            //
            // richTextBox2
            //
            this->richTextBox2->Font = (gcnew System::Drawing::Font(L"Franklin Gothic Medium", 9, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point,
                static_cast<System::Byte>(0)));
            this->richTextBox2->Location = System::Drawing::Point(24, 177);
            this->richTextBox2->Name = L"richTextBox2";
            this->richTextBox2->Size = System::Drawing::Size(254, 77);
            this->richTextBox2->TabIndex = 6;
            this->richTextBox2->Text = L"Name : AllsourceCodes 2.0 German Version \nAuthor : jeller\nDate : Sa 22 "
                L"Apr 21:49:50\n";
            this->richTextBox2->TextChanged += gcnew System::EventHandler(this, &Form1::richTextBox2_TextChanged);
            //
            // Form1
            //
            this->AutoScaleDimensions = System::Drawing::SizeF(10, 15);
            this->AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
            this->BackColor = System::Drawing::SystemColors::Control;
            this->ClientSize = System::Drawing::Size(455, 266);
            this->Controls->Add(this->richTextBox2);
            this->Controls->Add(this->richTextBox1);
            this->Controls->Add(this->pictureBox1);
            this->Controls->Add(this->button4);
            this->Controls->Add(this->button3);
            this->Controls->Add(this->button2);
            this->Controls->Add(this->button1);
            this->Font = (gcnew System::Drawing::Font(L"Lucida Console", 11.25F, static_cast<System::Drawing::FontStyle>((System::Drawing::FontStyle::Bold | System::Drawing::FontStyle::Italic)),
                System::Drawing::GraphicsUnit::Point, static_cast<System::Byte>(0)));
            this->ForeColor = System::Drawing::SystemColors::InfoText;
            this->Margin = System::Windows::Forms::Padding(5, 3, 5, 3);
            this->Name = L"Form1";
            this->Text = L"All SourceCodes 2.0(GER)";
            (cli::safe_cast<System::ComponentModel::ISupportInitialize^  >(this->pictureBox1))->EndInit();
            this->ResumeLayout(false);

        }
#pragma endregion
    private: System::Void button1_Click(System::Object^  sender, System::EventArgs^  e) {
             }
    private: System::Void richTextBox2_TextChanged(System::Object^  sender, System::EventArgs^  e) {
             }
};
}




mfg
jeller
 
Profil || Private Message || Suche Download || Zitatantwort || Editieren || Löschen || IP
012
22.04.2006, 22:20 Uhr
xXx
Devil


och was machst du! Das ist jetzt eine C# Anwendung.
 
Profil || Private Message || Suche Download || Zitatantwort || Editieren || Löschen || IP
013
22.04.2006, 22:37 Uhr
jeller



 
Profil || Private Message || Suche Download || Zitatantwort || Editieren || Löschen || IP
014
22.04.2006, 22:41 Uhr
jeller



wie gesagt ich bin noch nicht so lane dabei ^^sry
 
Profil || Private Message || Suche Download || Zitatantwort || Editieren || Löschen || IP
015
22.04.2006, 22:48 Uhr
jeller



aber ich hab ein visual c++ project geöffnet und der hatt mir das meiste vor gegeben
 
Profil || Private Message || Suche Download || Zitatantwort || Editieren || Löschen || IP
016
23.04.2006, 08:46 Uhr
jeller



eigentlich alles ^^
 
Profil || Private Message || Suche Download || Zitatantwort || Editieren || Löschen || IP
017
23.04.2006, 09:04 Uhr
Karldin Shinowa
Professional Noob



Zitat von jeller:
wie gesagt ich bin noch nicht so lane dabei ^^sry

wie lange genau?
--
Ich will die Welt verbessern, doch Gott gibt mir nicht den Code.
 
Profil || Private Message || Suche Download || Zitatantwort || Editieren || Löschen || IP
018
23.04.2006, 09:20 Uhr
jeller



so vllt halbes jahr oder anfang des jahres
 
Profil || Private Message || Suche Download || Zitatantwort || Editieren || Löschen || IP
019
23.04.2006, 09:59 Uhr
jeller



aber halt nicht alt zu lange
 
Profil || Private Message || Suche Download || Zitatantwort || Editieren || Löschen || IP
Seiten: [ 1 ] > 2 < [ 3 ] [ 4 ]     [ C / C++ (WinAPI, Konsole) ]  


ThWBoard 2.73 FloSoft-Edition
© by Paul Baecher & Felix Gonschorek (www.thwboard.de)

Anpassungen des Forums
© by Flo-Soft (www.flo-soft.de)

Sie sind Besucher: