hi,
ich habe Windows Mobile 5.0 und VS 2008.
Ich weis dass es in VC++ eine Möglichkeit gibt, eine Dialogbox zu erstellen, ist auch einfach.
Wie mache ich das unter VB für Windows Mobile.
Druckbare Version
hi,
ich habe Windows Mobile 5.0 und VS 2008.
Ich weis dass es in VC++ eine Möglichkeit gibt, eine Dialogbox zu erstellen, ist auch einfach.
Wie mache ich das unter VB für Windows Mobile.
Falls Du einfach Text anzeigen willst, dann MessageBox.Show(...).
nee nee :-)
Ich brauche ca. 10 Knöpfe und Edit Controll.
Dann Rechtsklick auf das VisualStudio Projetkt und 'Add - Windows Form...' wählen.
thx, habs hinbekommen.
in Windows Form 2 habe ich ein Textfeld, mit dem Namen notepad
in Windows Form 1 habe ich einen Kopf mit dem inhalt:
notepad.text = "test"
Leider kennt Windows Form 1 nicht notepad ?!
in form2 eine property erstellen
und dann dort aufrufen wo die form2 gebraucht wird, z.B.Code:public string Notepad { get { return notepad.Text; } }
Code:using (Form2 form2 = new Form2)
{
form2.Show();
string notepad = form2.Notepad;
}
thx,
ok, wo bringe ich das dann meine Zeichenkette "test test" rein?
Ich verstehe nicht warum du ein --> ; <-- verwendest?
Ich progge in VB für PcoketPC.
ist c#
convert vb to csharp
Was meinst Du mit test test?
ok, ich schneide einen string zusammen in Form1 z.b.:
"blabla" + "123" + "das muss ins Form2"
Das Ergebnis MUSS ins Textfeld von Form2. Sie heist notepad.text
in form2 eine property erstellen
und dann dort aufrufen wo die form2 gebraucht wird, z.B.Code:public string Notepad { set { notepad.Text = value; } }
Code:using (Form2 form2 = new Form2)
{
form2.Notepad = "...";
form2.Show();
}
sorry wegen der späten Antwort.
Er untersteicht mir string -> public string Notepad { set { notepad.Text = value; } }
Dann unterschreicht er mit form2 -> using (Form2 form2 = new Form2)
Gibt es keine Möglichkeit, eine Variable so anzulegen, dass ich sie über form1 und form2 angreifen kann?
habe mal meinen Vorschlag mit
convert csharp to vb konvertiert:
in form2
in form1Code:Public WriteOnly Property Notepad() As String
Set
notepad.Text = value
End Set
End Property
Falls das nicht geht, dann erstellst Du eine Methode namens SetNotepadText().Code:Using form2 As New Form2()
form2.Notepad = "..."
form2.Show()
End Using
ok,thx
Anderer Weg :-)
Mein Knopf von Form2:Zitat:
Public Class Form1
Dim gehtzurform2 as String
....jetzt kommt der Rest vom code...
Der Knopf übernimmt die Variable von der testbox von Form1 :-)Zitat:
Dim x = Form1.textboxergebnis.Text
notepad.Text = CStr(x)
Aber ich will die Variable gehtzurform2 gerne.
Wie mache ich das?