<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.dotnetzone.gr:443/cs/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>WinForms</title><link>https://www.dotnetzone.gr:443/cs/forums/12/ShowForum.aspx</link><description>Θέματα για rich client / windows εφαρμογές, σε οποιαδήποτε γλώσσα (VB.NET, C#, managed C++, κ.α.)</description><dc:language>el</dc:language><generator>CommunityServer 2.1 SP3 (Build: 20423.1)</generator><item><title>Απ: Κλήση εξωτερικής εφαρμογής ως διαφορετικός user (.NET 1.1, API call)</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/7755.aspx</link><pubDate>Sat, 10 Dec 2005 06:41:09 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:7755</guid><dc:creator>Panagiotis Kefalidis</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/7755.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=12&amp;PostID=7755</wfw:commentRss><description>Έχει πολλές λόξες το .net όταν καλείς API.
&lt;br&gt;Πχ σε περιπτώσεις που βλέπεις ότι πρέπει να δώσεις απλά int για parameter στο call, διαπιστώνεις τελικά ότι έπρεπε να δώσεις UInt16 σαν parameter και όχι Int (ενώ φυσικά δεν αναφέρετε ΠΟΥΘΕΝΑ, αλλα θα έπρεπε να το φανταστείς καθώς το API ή και το structure είναι compatible με Win95.(Ο νοών νοήτο (βλέπε SYSTEMTIME stucture)) :D
&lt;br&gt;Πάντως θα ήθελα να σας κάνω add στο msn μου κι εγω(u, gcapnias κλπ)..Αν θέλετε στείλτε μου μαιλ στο pkef@-(nospam)-datafire-(nospam)-.gr με τα δικά σας μαιλ..
&lt;br&gt;Ciaoz</description></item><item><title>Απ: Κλήση εξωτερικής εφαρμογής ως διαφορετικός user (.NET 1.1, API call)</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/7750.aspx</link><pubDate>Sat, 10 Dec 2005 03:09:50 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:7750</guid><dc:creator>cap</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/7750.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=12&amp;PostID=7750</wfw:commentRss><description>Λοιπόν, τελικά πολύ αργά σήμερα έμαθα οτι το θέμα των NT4 είναι νεφελώδες. Ητοι αυτή τη στιγμή μου αρκεί ο κώδικας που έκανα ήδη post και ο οποίος δουλεύει. Ευχαριστώ πάντως τον pkefal (καθώς και τους gcapnias, pkanavos που τους έπρηξα στο MSN) για τα καθοδηγητικά τους σχόλια, θα κλείσω αυτό το θέμα εδώ και θα ...επανέλθω μόλις με ...αναγκάσουν :) :) :)&lt;br&gt;&lt;br&gt;Σχετικά τώρα με τη LogonUser, ταλαιπωρήθηκα λίγο. Εβγαζε errors η κλήση μου, δεν καταλάβαινα γιατί...(1412 ΕRROR_CONTROL_ID_NOT_FOUND στη συγκεκριμένη περίπτωση, που το έπαιρνα με το lastDLLError αφού είχε σκάσει unhandled exception). Ομως, θα πρότεινα να μην σας ταλαιπωρήσω άλλο με αυτό αφού προς το παρόν μπαίνει στο "ψυγείο". Και πάλι ευχαριστώ θερμά!&lt;br&gt;</description></item><item><title>Απ: Κλήση εξωτερικής εφαρμογής ως διαφορετικός user (.NET 1.1, API call)</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/7742.aspx</link><pubDate>Fri, 09 Dec 2005 22:45:54 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:7742</guid><dc:creator>Panagiotis Kefalidis</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/7742.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=12&amp;PostID=7742</wfw:commentRss><description>Οτι θές ποστ.. δηλώνω κατι παραπάνω απο σχετικός, οπότε.. :D</description></item><item><title>Απ: Κλήση εξωτερικής εφαρμογής ως διαφορετικός user (.NET 1.1, API call)</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/7741.aspx</link><pubDate>Fri, 09 Dec 2005 22:44:36 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:7741</guid><dc:creator>cap</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/7741.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=12&amp;PostID=7741</wfw:commentRss><description>Θα το κοιτάξω οπως μου το λές. Η υλοποιηση της μπορεί να είναι εύκολη, εγώ όμως δηλώνω ημι-ασχετος απο api calls, οπότε...:)&lt;br&gt;</description></item><item><title>Απ: Κλήση εξωτερικής εφαρμογής ως διαφορετικός user (.NET 1.1, API call)</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/7740.aspx</link><pubDate>Fri, 09 Dec 2005 22:36:45 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:7740</guid><dc:creator>Panagiotis Kefalidis</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/7740.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=12&amp;PostID=7740</wfw:commentRss><description>Γιατί δεν καλείς την LogonUser όπως λέει το SDK για να πάρεις Token και να το τρέξεις έτσι?&lt;br&gt;Εγώ πάντως έτσι το κάνω..&lt;br&gt;Ρώτησα και ένα φίλο μου που γράφει το InstallAware (τον installer αν τον ξέρετε) και μου είπε ακρίβως το ίδιο πράγμα..Παίρνεις τοκεν και καλείς την CreateProcessAsUser..&lt;br&gt;Επίσης διαφώτισε με λίγο γιατι δεν είναι εύκολη η υλοιποίησή της..Μάλλον μου ξεφεύγει κάτι..</description></item><item><title>Κλήση εξωτερικής εφαρμογής ως διαφορετικός user (.NET 1.1, API call)</title><link>https://www.dotnetzone.gr:443/cs/forums/thread/7734.aspx</link><pubDate>Fri, 09 Dec 2005 20:09:36 GMT</pubDate><guid isPermaLink="false">2622095e-976c-431a-859e-16783ec7ecd7:7734</guid><dc:creator>cap</dc:creator><slash:comments>0</slash:comments><comments>https://www.dotnetzone.gr:443/cs/forums/thread/7734.aspx</comments><wfw:commentRss>https://www.dotnetzone.gr:443/cs/forums/commentrss.aspx?SectionID=12&amp;PostID=7734</wfw:commentRss><description>&lt;P&gt;Εχω το εξής θέμα:&lt;/P&gt;
&lt;P&gt;Χρειάζεται να καλέσω μια εφαρμογή (για την ακρίβεια, ΙΕ με ένα συγκεκριμένο URL) ως ένας συγκεκριμένος χρήστης (και όχι προφανώς αυτός που τρέχει την αρχική εφαρμογή) μέσα από μια άλλη εφαρμογή.&lt;/P&gt;
&lt;P&gt;Χρησιμοποιώ .NET 1.1 οπότε η System.Diagnostics.Process.CreateProcess δεν με καλύπτει μια και δεν μπορεί να δεχθεί user credentials (σε αντίθεση με το .NET 2.0).&lt;/P&gt;
&lt;P&gt;Αρα η μόνη λύση στην οποία μπορούσα να καταφύγω ήταν API Call. Δεν έχω μεγάλη γνώση από αυτόν τον τομέα, με πολύ κόπο κατάφερα να βρω κώδικα σε C# τον οποίο άλλαξα σε VB.NET και ενσωματωσα σε μια δική μου κλάση και δουλεύει. Χρησιμοποιεί το advapi32.dll και συγκεκριμένα την CreateProcessWithLogonW(). Θα σας παραθέσω τον κώδικα παρακάτω μια και είναι χρήσιμος άν κάποιος άλλος συνάδελφος θέλει να κάνει το ίδιο πράγμα. &lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Το πρόβλημα&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Η CreateProcessWithLogonW δουλεύει μόνο σε Win2000/2003. Ο πελάτης (δυστυχώς) έχει και παλιότερα συστήματα όπως NT 4.0 Workstation. Αυτό είναι κάτι που δεν μπορώ να αλλάξω. &lt;/P&gt;
&lt;P&gt;Ψάχνοντας, βρήκα οτι η CreateProcessAsUser() γενικά παίζει και σε αυτά τα συστήματα. Δυστυχώς, λόγω του οτι λειτουργεί με tokens και όχι με actual username/password/domain, δεν είναι τόσο απλή η υλοποίησή της και στο Web όλος ο κόσμος τσακώνεται για το πως θα λειτουργήσει σωστά...&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Το ζητούμενο&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Χρειάζομαι ολοκληρωμένο κώδικα ο οποίος θα λειτουργεί ΚΑΙ σε NT 4.0 Workstation και ο οποίος θα σηκώνει μια εξωτερική εφαρμογή ως χρήστης της επιλογής μου. Δεν με ενοχλεί να περνάει το password ή οχι, ως θέμα security, σε αυτό το σημείο. Ξερω οτι είναι αρκετά "βαρύ" το θέμα, οπότε απλα εύχομαι κάποιος φίλος να έχει ήδη "περάσει" αυτή τη φουρτούνα και να έχει κάτι να προτείνει.&lt;/P&gt;
&lt;P&gt;Παρακάτω παραθέτω τον κώδικα που χρησιμοποιεί την CreateProcessWithLogonW και ο οποίος δούλεψε μια χαρά σε Windows 2003 server (αλλα φυσικά όχι σε ΝΤ):&lt;/P&gt;
&lt;P&gt;&lt;span style="color: Black;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Imports&lt;/span&gt; System&lt;br /&gt;&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Imports&lt;/span&gt; System.Drawing&lt;br /&gt;&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Imports&lt;/span&gt; System.Collections&lt;br /&gt;&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Imports&lt;/span&gt; System.ComponentModel&lt;br /&gt;&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Imports&lt;/span&gt; System.Windows.Forms&lt;br /&gt;&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Imports&lt;/span&gt; System.Data&lt;br /&gt;&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Imports&lt;/span&gt; System.Runtime.InteropServices&lt;br /&gt;&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Imports&lt;/span&gt; System.IO&lt;br /&gt;&lt;br /&gt;&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Class&lt;/span&gt; clsSpawnProcess&lt;br /&gt;&lt;br /&gt;    &amp;lt;Flags()&amp;gt; _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Enum&lt;/span&gt; LogonFlags&lt;br /&gt;        LOGON_WITH_PROFILE &lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;=&lt;/span&gt; &amp;amp;H1&lt;br /&gt;        LOGON_NETCREDENTIALS_ONLY &lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;=&lt;/span&gt; &amp;amp;H2&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;End&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Enum&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;    &amp;lt;Flags()&amp;gt; _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Enum&lt;/span&gt; CreationFlags&lt;br /&gt;&lt;br /&gt;        CREATE_SUSPENDED &lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;=&lt;/span&gt; &amp;amp;H4&lt;br /&gt;        CREATE_NEW_CONSOLE &lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;=&lt;/span&gt; &amp;amp;H10&lt;br /&gt;        CREATE_NEW_PROCESS_GROUP &lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;=&lt;/span&gt; &amp;amp;H200&lt;br /&gt;        CREATE_UNICODE_ENVIRONMENT &lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;=&lt;/span&gt; &amp;amp;H400&lt;br /&gt;        CREATE_SEPARATE_WOW_VDM &lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;=&lt;/span&gt; &amp;amp;H800&lt;br /&gt;        CREATE_DEFAULT_ERROR_MODE &lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;=&lt;/span&gt; &amp;amp;H4000000&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;End&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Enum&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;    &amp;lt;StructLayout(LayoutKind.Sequential)&amp;gt; _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Structure&lt;/span&gt; ProcessInfo&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; hProcess &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; IntPtr&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; hThread &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; IntPtr&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; dwProcessId &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; UInt32&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; dwThreadId &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; UInt32&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;End&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Structure&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;    &amp;lt;StructLayout(LayoutKind.Sequential, CharSet:=CharSet.&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Unicode&lt;/span&gt;)&amp;gt; _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Structure&lt;/span&gt; StartupInfo&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; cb &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; Int32&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; reserved1 &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt;&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; desktop &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt;&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; title &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt;&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; dwX &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; UInt32&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; dwY &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; UInt32&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; dwXSize &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; UInt32&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; dwYSize &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; UInt32&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; dwXCountChars &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; UInt32&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; dwYCountChars &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; UInt32&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; dwFillAttribute &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; UInt32&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; dwFlags &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; UInt32&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; wShowWindow &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Short&lt;/span&gt;&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; reserved2 &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Short&lt;/span&gt;&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; reserved3 &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Integer&lt;/span&gt;&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; hStdInput &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; IntPtr&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; hStdOutput &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; IntPtr&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; hStdError &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; IntPtr&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;End&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Structure&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;    &amp;lt;DllImport(&lt;span style="color: #666666;background-color: #e4e4e4;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;"advapi32.dll"&lt;/span&gt;, CharSet:=CharSet.&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Unicode&lt;/span&gt;, ExactSpelling:=&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;True&lt;/span&gt;, SetLastError:=&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;True&lt;/span&gt;)&amp;gt; _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Shared&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Function&lt;/span&gt; CreateProcessWithLogonW( _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; principal &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt;, _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; authority &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt;, _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; password &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt;, _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; logonFlags &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; LogonFlags, _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; appName &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt;, _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; cmdLine &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt;, _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; creationFlags &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; CreationFlags, _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; environmentBlock &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; IntPtr, _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; currentDirectory &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt;, _&lt;br /&gt;     &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByRef&lt;/span&gt; startupInfo &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; StartupInfo, _&lt;br /&gt;     &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByRef&lt;/span&gt; processInfo &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; ProcessInfo) &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Boolean&lt;/span&gt;&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;End&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Function&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;    &amp;lt;DllImport(&lt;span style="color: #666666;background-color: #e4e4e4;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;"kernel32.dll"&lt;/span&gt;)&amp;gt; _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Shared&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Function&lt;/span&gt; CloseHandle(&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; h &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; IntPtr) &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Boolean&lt;/span&gt;&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;End&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Function&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Public&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Shared&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Function&lt;/span&gt; CreateProcess( _&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; username &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt; _&lt;br /&gt;    , &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; domain &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt; _&lt;br /&gt;    , &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; password &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt; _&lt;br /&gt;    , &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; applicationPath &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt; _&lt;br /&gt;    , &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;ByVal&lt;/span&gt; commandLineArgs &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;String&lt;/span&gt;)&lt;br /&gt;&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Dim&lt;/span&gt; si &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; StartupInfo &lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;=&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;New&lt;/span&gt; StartupInfo&lt;br /&gt;        si.cb &lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;=&lt;/span&gt; Marshal.SizeOf(&lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;GetType&lt;/span&gt;(StartupInfo))&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Dim&lt;/span&gt; pi &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;As&lt;/span&gt; ProcessInfo &lt;span style="color: Red;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;=&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;New&lt;/span&gt; ProcessInfo&lt;br /&gt;&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;If&lt;/span&gt; (CreateProcessWithLogonW(username, domain, password, _&lt;br /&gt;         LogonFlags.LOGON_WITH_PROFILE, _&lt;br /&gt;         applicationPath, commandLineArgs, _&lt;br /&gt;         0, IntPtr.Zero, &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Nothing&lt;/span&gt;, _&lt;br /&gt;         si, pi)) &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Then&lt;/span&gt;&lt;br /&gt;            CloseHandle(pi.hProcess)&lt;br /&gt;            CloseHandle(pi.hThread)&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Else&lt;/span&gt;&lt;br /&gt;            &lt;span style="color: Green;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;'TODO: throw exception here or something&lt;/span&gt;&lt;br /&gt;            Console.WriteLine(&lt;span style="color: #666666;background-color: #e4e4e4;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;"Error code: {0}"&lt;/span&gt;, Marshal.GetLastWin32Error())&lt;br /&gt;        &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;End&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;If&lt;/span&gt;&lt;br /&gt;    &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;End&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Function&lt;/span&gt;&lt;br /&gt;&lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;End&lt;/span&gt; &lt;span style="color: Blue;background-color: Transparent;font-family: Lucida Console;font-size: 11px;font-weight: normal;"&gt;Class&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Τα φώτα σας!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description></item></channel></rss>