Autor Beitrag
Raven280438
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 99



BeitragVerfasst: Fr 15.10.10 17:29 
Hi,

es geht um folgendes Codeschnippsel: create.msdn.com/en-U...le/winforms_series_1


Da wird ein eigener Control (von Control abgeleitet) benutzt. Wie bekomm ich es hin, dass der Control im Designer von Visual Studio zu sehn ist?


Gruß


Moderiert von user profile iconKha: Topic aus WinForms verschoben am Sa 16.10.2010 um 14:50
Ralf Jansen
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 4708
Erhaltene Danke: 991


VS2010 Pro, VS2012 Pro, VS2013 Pro, VS2015 Pro, Delphi 7 Pro
BeitragVerfasst: Fr 15.10.10 17:39 
Wenn dieses Control in einem Projekt der gerade offenen Solution steckt und kompilierbar ist taucht es von selbst da auf. Wenn nicht das Contextmenu auf der Toolbox öffnen, den 'Choose Items' (bzw. das deutschsprachige Äquivalent) Menüpunkt anwählen und die Assembly auswählen in der das Control steckt.
Raven280438 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 99



BeitragVerfasst: Fr 15.10.10 19:13 
Hi,

sry für mein Nachfragen, ich bin Anfänger ;)

Ich hab das Control in aktuellen Projekt als .cs Datei drin. In der Toolbox wird es aber nicht angezeigt. Was muss ich bei "Choose Items" auswählen?


Gruß
Christoph1972
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 690
Erhaltene Danke: 16


VS2015 Pro / C# & VB.Net
BeitragVerfasst: Fr 15.10.10 20:04 
Zitat:
Was muss ich bei "Choose Items" auswählen


dein Assembly

_________________
Gruß
Christoph
Raven280438 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 99



BeitragVerfasst: Fr 15.10.10 20:09 
Hi,

wie kann ich das Assembly erstellen? Wie gesagt, ich hab nur ne .cs Datei ;)


Sry wie gesagt, bin Anfänger ;)
Christoph1972
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 690
Erhaltene Danke: 16


VS2015 Pro / C# & VB.Net
BeitragVerfasst: Fr 15.10.10 22:38 
Das ist die Anwendung, die du erstellst.

_________________
Gruß
Christoph
Kha
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 3803
Erhaltene Danke: 176

Arch Linux
Python, C, C++ (vim)
BeitragVerfasst: Sa 16.10.10 14:50 
Wie Ralf Jansen schon sagte, da musst du überhaupt nichts auswählen, sondern ein Control im aktuellen Projekt sollte automatisch auftauchen. Du hast das Projekt mit F6 kompiliert bzw. einmal gestartet und die Klasse ist öffentlich und von Control abgeleitet?

_________________
>λ=
Raven280438 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 99



BeitragVerfasst: Sa 16.10.10 14:56 
Es ist immernoch nichts in der Toolbox zusehn.

ausblenden C#-Quelltext
1:
2:
3:
public class texturControl : GraphicsDeviceControl { 
[...] 
}


und GraphicsDeviceControl ist von Control abgeleitet.
Ralf Jansen
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 4708
Erhaltene Danke: 991


VS2010 Pro, VS2012 Pro, VS2013 Pro, VS2015 Pro, Delphi 7 Pro
BeitragVerfasst: Sa 16.10.10 15:24 
Welche Visual Studio Version verwendest du?
Das automatische hinzufügen zur Toolbox ist abschaltbar. Sieh mal unter Tool/Options/Windows Forms Designer/AutoToolboxPopulate ob du es eventuell abgeschaltet hast.
Raven280438 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 99



BeitragVerfasst: Sa 16.10.10 16:28 
Hi,

ich benutze Visual Studio 2008.

Die Option stand wirklich auf false, ich hab sie angeschalten, aber der Control ist trotzdem nicht in der Toolbox. (trotz neustart usw.)
Christoph1972
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 690
Erhaltene Danke: 16


VS2015 Pro / C# & VB.Net
BeitragVerfasst: Sa 16.10.10 16:40 
dann über das Kontextmenü der Toolbox Element auswählen. Manchmal spinnt das irgendwie mit den Controls, nicht nur bei dir, die Problemstellung taucht in allen .Net Foren auf.

_________________
Gruß
Christoph
Raven280438 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 99



BeitragVerfasst: Sa 16.10.10 17:06 
Hi,

was muss ich dann da auswählen? Wenn ich die Exe meines Programms auswähle bekomm ich die Meldung, dass da keine Komponenten für die Toolbox drin sind.
Raven280438 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 99



BeitragVerfasst: Sa 16.10.10 17:46 
Hi,

jetzt wird es aus irgend einem Grund das custum Control in der Toolbox angezeigt.

Fragt mich nicht warum ;)


Ich danke Allen, die mir hier weitergeholfen haben


Gruß
Christoph1972
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 690
Erhaltene Danke: 16


VS2015 Pro / C# & VB.Net
BeitragVerfasst: Sa 16.10.10 21:52 
Sagte ich doch. das wird dir früher oder später wieder begegnen, das gehört mit dazu :wink:

_________________
Gruß
Christoph