Trending Up...

Trending Up...

Simple Winsock select-modal server

void AppMain(int argc, TCHAR* argv[], TCHAR* envp[]){    int PortNo = 12345;    SOCKET ListenSock;    int Ret = 0;    WSAData wsa;    if ((Ret = WSAS...

2008-03-26 11:22:00

阅读数 503

评论数 0

MFC Ocx: Using ActiveX Controls in Nondialog Windows

Using ActiveX Controls in Nondialog WindowsMFC and ClassWizard make it wonderfully easy to use ActiveX controls in dialogs, but what about nondialog ...

2008-03-15 12:58:00

阅读数 986

评论数 0

Return multiple dataset

             // (1)            OleDbDataAdapter da = new OleDbDataAdapter(                "select * from jobs;select * from employee", //in...

2008-03-15 11:40:00

阅读数 482

评论数 0

SQL Server 2005 error handling

Extract from : SQL Server Error Handling Workbenchhttp://www.simple-talk.com/sql/t-sql-programming/sql-server-error-handling-workbench/--Catch Error:...

2008-03-11 09:48:00

阅读数 550

评论数 0

Improve performance using hash keys

use CheckSum function to turn a string key to a hash key(integer), this will improve performance

2008-03-11 09:40:00

阅读数 410

评论数 0

Compare 2 string with case sensitive

Select * from test where convert(varbinary, column1) = convert(varbinary, ABCD)  

2008-03-11 09:35:00

阅读数 483

评论数 0

CSharp download (html, binary file)

download html : WebRequest/WebResponsedownload bin file: WebClient

2008-03-11 09:33:00

阅读数 613

评论数 0

How to use SubVersion (Import/Checkout)

how to use SVN1)select a native window folder "Import" to SVN, but the native folder is not linked to SVN2)remove the natie folderIn SVN Ex...

2008-03-11 09:31:00

阅读数 489

评论数 0

MFC how to handle ocx event

Insert ActiveX control in a dialog resource, and  add event  handler with wizard, then copy the macro/event codeto your project.ON_EVENT/ DataExchang...

2008-03-11 09:30:00

阅读数 475

评论数 0

Add remove window services

Install/Uninstall .Net wizarded window service : InstallUtil.exegeneral Add/Delete: sc.exe

2008-03-11 09:23:00

阅读数 477

评论数 0

CSharp restart program

start a new instance of the program and close the old one Process.Start(Application.ExecutablePath,Process.GetCurrentProcess().Id.ToString());this.Cl...

2008-03-11 09:22:00

阅读数 459

评论数 0

MFC Macro

DECLARE_DYNAMIC/IMPLEMENT_DYNAMIC: use CObject::IsKindOf DECLARE_EVENTSINK_MAP/BEGIN_EVENTSINK_MAP/END_EVENTSINK_MAP: OLE container event sink (accep...

2008-03-11 09:18:00

阅读数 571

评论数 0

MFC handle user defined message

----------------------------------1)#define WM_MYMESSAGE1 WM_USER + 1000----------------------------------2)protected:    afx_msg LRESULT OnMyMessage...

2008-03-08 23:37:00

阅读数 654

评论数 0

Right click to open cmd.exe

1) open window explorer2) Tools -> Folder Options.3) File type tab4) Choose Folder file type5) Click Advanced6) Click New7) In "Action" ...

2008-03-02 12:09:00

阅读数 533

评论数 0

SQL read MS access(*.mdb)

select CustID, CustName from openrowset(Microsoft.Jet.OLEDB.4.0, C:/trade.mdb;Admin;, Customer)

2008-03-02 11:56:00

阅读数 464

评论数 0

SQL tree data struct(7): find the minimal cost route

-- find the minimal cost routecreate table flights(departure char(20), destination char(20), cost int)insert flights select Chicago, New York, 10 uni...

2008-03-02 11:54:00

阅读数 643

评论数 0

SQL tree data struct(5): AdjList2NestedSet

/*The organizational chart would look like this as a directed graph:            Albert (1,12)            /        /          /            /    Bert (...

2008-03-02 11:52:00

阅读数 736

评论数 0

SQL tree data struct(6): NestedSet2AdjList

declare @personnel table(emp varchar(30), lft int, rgt int)insert @personnelselect Albert, 1, 12union all select Bert, 2, 3 union all select Chuck, 4...

2008-03-02 11:52:00

阅读数 842

评论数 0

SQL tree data struct(4): AdjList2MatPath (for printing tree struct)

if object_id(proc_print_tree) is not null    drop procedure proc_print_treegocreate procedure proc_print_tree @raw_data_sql nvarchar(1000), @debug bi...

2008-03-02 11:51:00

阅读数 741

评论数 0

SQL tree data struct(3): nested set (1,12) include (2,3) & (4, 11) ...

-- Credit to JOE CELKO-- http://archives.postgresql.org/pgsql-sql/2001-11/msg00004.php--  CREATE TABLE Personnel --  (emp CHAR(10) NOT NULL PRIMARY K...

2008-03-02 11:49:00

阅读数 704

评论数 0

提示
确定要删除当前文章?
取消 删除
关闭
关闭