Systemroot herausfinden

  • VB.NET

Es gibt 7 Antworten in diesem Thema. Der letzte Beitrag () ist von Ninoxo.

    VB.NET-Quellcode

    1. Dim TestArray() As String = Split(System.Environment.SystemDirectory, ":")
    2. Label1.Text = TestArray(0) + ":\"


    Dieser Code splittet den Systempfad bei den Doppelpunkten und liest den ersten Part - also den
    Laufwerkbuchstaben in dem das Systemverzeichnis liegt - aus. Dann wird der Doppelpunkt samt Slash
    wieder beigefügt und das ganze in einem Label - Label1 - angezeigt.
    "Life isn't about winning the race. Life is about finishing the race and how many people we can help finish the race." ~Marc Mero

    Nun bin ich also auch soweit: Keine VB-Fragen per PM! Es gibt hier ein Forum, verdammt!

    Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von „Ninoxo“ ()

    Habe mich im obigen Thread verbessert.
    "Life isn't about winning the race. Life is about finishing the race and how many people we can help finish the race." ~Marc Mero

    Nun bin ich also auch soweit: Keine VB-Fragen per PM! Es gibt hier ein Forum, verdammt!
    kein problem, immer gern ;)
    "Life isn't about winning the race. Life is about finishing the race and how many people we can help finish the race." ~Marc Mero

    Nun bin ich also auch soweit: Keine VB-Fragen per PM! Es gibt hier ein Forum, verdammt!