Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Prozesse anzeigen

Empfohlene Antworten

Veröffentlicht

Hy Leute,

ich hab gerade ein Problem und zwar möchte ich mir alle laufenden Prozesse mit dem Namen anzeigen, komm nicht drauf, wie mach ich das? :D

was für prozesse? unter linux? oder wie oder wo oder was?

also unter Linux versuch's mal mit ps, ps -A, etc...

was für prozesse? unter linux? oder wie oder wo oder was?

also unter Linux versuch's mal mit ps, ps -A, etc...

looool sach mal hast du dich verlaufen? :D

Basic is Microsoft, man kann daher IMHO keine Linux Prozesse auslesen ;)

:rolleyes: rofl aaalso Prozesse unter WinXp :eek:

äähm... jap!

ok! 1:0 für dich ;)

um von meiner Unfähigkeit abzulenken schiebe ich das ganze mal auf den Zeitpunkt des Posts und die Tatsache das ich diesen VOR meinem morgentlichen Pott Kaffee geschrieben habe! *räusper* *indieeckeverkriechundschäm*

was für prozesse? unter linux? oder wie oder wo oder was?

also unter Linux versuch's mal mit ps, ps -A, etc...

Sorry for OT:

liegt wohl am namen.....

:)

Um zurück aufs thema zu kommen, hat keiner denn irgendeine idee?

looool sach mal hast du dich verlaufen? :D

Basic is Microsoft, man kann daher IMHO keine Linux Prozesse auslesen ;)

Basic==Microsoft?

Ich glaub es tickt nicht richtig, seit wann hat Microsoft Basic für sich patentiert?

Es gibt haufenweise Basic Interpreter für Linux, sogar VisualBasic für Linux.

ciao!

Basic==Microsoft?

Ich glaub es tickt nicht richtig, seit wann hat Microsoft Basic für sich patentiert?

Es gibt haufenweise Basic Interpreter für Linux, sogar VisualBasic für Linux.

ciao!

klasse... klar kann man die verlangte RuntimeEnvironment emulieren... aber standartmäßig kann Linux das net

zum thema: schau dir das hier http://www.planet-source-code.com/vb/scripts/ShowCode.asp?txtCodeId=56606&lngWId=1 mal an... da sollte das coding dass du willst enthalten sein

Hab da was...

+ function um speziell prozess zu killen..



Option Explicit


Private Declare Function GetDesktopWindow Lib "user32" () _

        As Long


Private Declare Function GetWindow Lib "user32" (ByVal hWnd _

        As Long, ByVal wCmd As Long) As Long


Private Declare Function GetWindowLong Lib "user32" Alias _

        "GetWindowLongA" (ByVal hWnd As Long, ByVal wIndx As _

        Long) As Long


Private Declare Function GetWindowTextLength Lib "user32" _

        Alias "GetWindowTextLengthA" (ByVal hWnd As Long) _

        As Long


Private Declare Function GetWindowText Lib "user32" Alias _

        "GetWindowTextA" (ByVal hWnd As Long, ByVal lpString _

        As String, ByVal cch As Long) As Long


Private Declare Function GetParent Lib "user32" (ByVal hWnd _

        As Long) As Long


Private Declare Function GetWindowThreadProcessId Lib "user32" _

        (ByVal hWnd As Long, lpdwProcessId As Long) As Long


Private Declare Function CloseHandle Lib "kernel32" (ByVal _

        hObject As Long) As Long


Private Declare Function OpenProcess Lib "kernel32" (ByVal _

        dwDesiredAccess As Long, ByVal bInheritHandle As Long, _

        ByVal dwProcessId As Long) As Long


Private Declare Function TerminateProcess Lib "kernel32" (ByVal _

        hProcess As Long, ByVal uExitCode As Long) As Long


Const GW_HWNDFIRST = 0

Const GW_HWNDLAST = 1

Const GW_HWNDNEXT = 2

Const GW_HWNDPREV = 3

Const GW_OWNER = 4

Const GW_CHILD = 5

Const GW_MAX = 5


Const GWL_STYLE = (-16)


Const WS_VISIBLE = &H10000000

Const WS_BORDER = &H800000


Const PROCESS_TERMINATE = &H1



Public Function KillApp(strAppTitle As String) As Integer



    Dim Result, Task As Long

    Dim intKillApp As Integer

    Dim bKillApp As Boolean


    intKillApp = 0


    Do


        Result = EnumWindows(strAppTitle)


        If Result <> 0 Then


            Task = OpenProcess(PROCESS_TERMINATE, 0&, Result)

            Result = TerminateProcess(Task, 1&)

            Result = CloseHandle(Task)

            intKillApp = intKillApp + 1

            bKillApp = True


        Else


            KillApp = intKillApp + 1

            bKillApp = False


        End If


    Loop Until bKillApp = False


End Function



Private Function EnumWindows(strAppTitle As String) As Long




    Dim hWnd As Long

    Dim lngTest As Long


    'Auch der Desktop ist ein Fenster

    'hWnd = GetDesktopWindow


    'Einstieg

    hWnd = GetWindow(frmOraXl.hWnd, GW_HWNDFIRST)


    'Alle vorhandenen Fenster abklappern

    Do


        lngTest = GetWindowInfo(hWnd, strAppTitle)


        If lngTest <> 0 Then


            EnumWindows = lngTest 'GetWindowInfo(hWnd, strAppTitle)

            Exit Function


        End If


        hWnd = GetWindow(hWnd, GW_HWNDNEXT)


    Loop Until hWnd = 0


    EnumWindows = hWnd


End Function



Private Function GetWindowInfo(hWnd As Long, strAppTitle As String) As Long



    Dim Parent, Task, Result, x, Style As Long

    Dim Title As String


    'Darstellung des Fensters

    Style = GetWindowLong(hWnd, GWL_STYLE)

    Style = Style And (WS_VISIBLE Or WS_BORDER)


    'Title des Fenster auslesen

    Result = GetWindowTextLength(hWnd) + 1

    Title = Space$(Result)

    Result = GetWindowText(hWnd, Title, Result)

    Title = Left$(Title, Len(Title) - 1)


        'Elternfenster ermitteln

        Parent = hWnd


        Do


            Parent = GetParent(Parent)


        Loop Until Parent = 0


        'Task Id ermitteln

        Result = GetWindowThreadProcessId(hWnd, Task)


        If Right(strAppTitle, Len(strAppTitle) - InStrRev(strAppTitle, " ")) = Title Then


            GetWindowInfo = Task


        ElseIf strAppTitle = Title Then


            GetWindowInfo = Task


        End If



End Function


müßtest es dir noch ein "bissele" anpassen.. :rolleyes:

HEY JUNGS IHR SEID SPITZE!!

Also das funzt nun hab das von dem Procviewer rausgenommen, war eigentlich gaaanz easy, mein chef wird sich freuen..... :bimei

klasse... klar kann man die verlangte RuntimeEnvironment emulieren... aber standartmäßig kann Linux das net

Wieso sollte man eine Runtime Environment emulieren?

Es gab Basic schon beim C64, danach bei DOS, Linux und auch Windows.

Da ist nichts mit emulieren, nur interpretieren ;)

Guck dich mal hier um:

http://freshmeat.net/search/?q=Basic&section=projects&Go.x=0&Go.y=0

Und noch ein bissle was informatives:

http://de.wikipedia.org/wiki/Basic

Wieso sollte man eine Runtime Environment emulieren?

Es gab Basic schon beim C64, danach bei DOS, Linux und auch Windows.

Da ist nichts mit emulieren, nur interpretieren ;)

oh ähm entschuldige wenn ich mich falsch ausgedrückt hatte... meinte natürlich auch Visual Basic http://de.wikipedia.org/wiki/Visual_Basic

(das coding oben ist übrigens auch VB ;) )

na huch da steht ja was von Plattformabhängig?! sowas... :P *just joking* ;)

Ja, VB ist von MS und nur für die Windowsplattform ... hast du in deinem Beitrag aber nie erwähnt und der OP hat auch nicht gezielt nach VB gefragt ^^

btw. gibt es auch VB für Linux, einmal in der Form wie unter Windows bis VB6, einmal im Rahmen von Mono als VB.NET, wobei letzteres erst für Version 1.2 geplant ist und bei der VB6 für Linux Umsetzung weiss ich auch nicht, wieweit die Programmierung fortgeschritten ist.

Ja, VB ist von MS und nur für die Windowsplattform ... hast du in deinem Beitrag aber nie erwähnt und der OP hat auch nicht gezielt nach VB gefragt ^^

btw. gibt es auch VB für Linux, einmal in der Form wie unter Windows bis VB6, einmal im Rahmen von Mono als VB.NET, wobei letzteres erst für Version 1.2 geplant ist und bei der VB6 für Linux Umsetzung weiss ich auch nicht, wieweit die Programmierung fortgeschritten ist.

ja gut, kleines missverständnis eben... :D

na dann können wir ja mit dem OT hier aufhören ;)

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.