· Imports System.Diagnostics
Namespace vbCity
Public Module modFunctions
Public Sub ExecuteApplication(pstrApplicationName As String)
Dim udtProcess As Process = New Process
udtProcess.Start(pstrApplicationName)
End Sub
End Module
End Namespace
· using System;
using System.DirectoryServices; namespace ActiveDirectory
{ /// <summary>
/// Summary description for Class1.
/// </summary> class Class1
{
static void Main (string[] args)
{
//Note : microsoft is the name of my domain for t...
· Viewer.vb剩余代码
Private Sub lstItem_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles lstItem.SelectedIndexChanged
If lstItem.Items.Count > 0 Then
Select Case cmbOption.Text
Case API.CMB_TYPES
...
· 在项目中添加新项---类(CTypes.vb)
代码如下
Namespace API
Public Class CTypes
Implements IStore
Dim TypeList As SortedList
Dim TypeListCSharp As SortedList
Sub New()
TypeList = New SortedList()
TypeListCSharp = New S...
· public class FolderDialog : FolderNameEditor
{
FolderNameEditor.FolderBrowser fDialog = new System.Windows.Forms.Design.FolderNameEditor.FolderBrowser();
public FolderDialog()
{
}
public DialogResult DisplayDialog()
{
...
· public class Win32Hook
{ [DllImport("kernel32")]
public static extern int GetCurrentThreadId(); [DllImport( "user32",
CharSet=CharSet.Auto,CallingConvention=CallingConvention.StdCall)]
public static extern int SetWindowsHookEx(
Hook...
· 想要调用系统屏幕保护,主要是发送一个WM_SYSCOMMAND消息即可。 Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hwnd As Int32, ByVal wMsg As Int32, ByVal wParam As Int32, ByVal lParam As Int32) As Int32
Private Const HWND_B...
· 拥有xp风格的界面 Windows XP发布时,我们中许多人都为她华丽漂亮的界面折服和兴奋。然而,.NET1.0发布时,我们中又有许多人,包括我自己,对它不支持XP风格感到大失所望。可事实是,在Windows XP(只限于WindowsXP)里.NET支持XP风格,只是还要您做一点小工作。这篇文章主要参考了http://www.cod...