摘要: Freme 类中 // CMainFrame construction/destruction CMainFrame::CMainFrame() { // TODO: add member initialization code here } CMainFrame::~CMainFrame() { 阅读全文
posted @ 2016-02-25 16:25 風行 阅读(1048) 评论(0) 推荐(0)
摘要: //在Frame类中,增加一个成员数组,HICON m_icon[3] //在Freame中添加,目的是对数组里的每个元素进行赋值 //setclasslong()是为了让初始的情况下,不显示MFC默认的ICON //定义定时器,然后Frame类中,添加WM_TIMER消息映射。 m_Icon[0] 阅读全文
posted @ 2016-02-25 16:25 風行 阅读(213) 评论(0) 推荐(0)
摘要: // TestDlg.cpp : implementation file // #include "stdafx.h" #include "Dlg.h" #include "TestDlg.h" #ifdef _DEBUG #define new DEBUG_NEW #undef THIS_FILE 阅读全文
posted @ 2016-02-25 16:24 風行 阅读(355) 评论(0) 推荐(0)
摘要: /*=================CWebWorld.h 头文件=======================*/ #include "wininet.h" class CWebWorld { public: void SetErrorMessage(CString s); CString Ge 阅读全文
posted @ 2016-02-25 16:23 風行 阅读(289) 评论(0) 推荐(0)
摘要: CFileDialog dlg(true); dlg.m_ofn.lpstrInitialDir = "f:\新建文件夹"; CFileDialog dlg(true,NULL,NULL,OFN_HIDEREADONLY| OFN_OVERWRITEPROMPT,"文本文件(*.txt)|*.txt 阅读全文
posted @ 2016-02-25 16:23 風行 阅读(515) 评论(0) 推荐(0)
摘要: #include "stdafx.h" #include "TestText.h" #include "TestTextDoc.h" #include "TestTextView.h" #ifdef _DEBUG #define new DEBUG_NEW #undef THIS_FILE stat 阅读全文
posted @ 2016-02-25 16:23 風行 阅读(1086) 评论(0) 推荐(0)
摘要: /****************************************************************************** * File Name : DataFile.h * * Description : The CDataFile class is used 阅读全文
posted @ 2016-02-25 16:22 風行 阅读(220) 评论(0) 推荐(0)
摘要: CFileFind tempFile; BOOL bIsFound; //查找文件夹中是否有*.Raw文件 bIsFound = tempFile.FindFile(Dir + _T("\*.raw")); //如果有,则开始遍历 while (bIsFound) { bIsFound = temp 阅读全文
posted @ 2016-02-25 16:20 風行 阅读(444) 评论(0) 推荐(0)
摘要: #define ROW 3072 #define COL 3072 void CQweqweqweDlg::OnCancel() { int i=0,j=0; //取平局后的二位数组 BYTE *rawAvg=new BYTE[COL*ROW*2]; memset(rawAvg,0,sizeof(B 阅读全文
posted @ 2016-02-25 16:20 風行 阅读(251) 评论(0) 推荐(0)
摘要: DWORD Serial; DWORD Length; GetVolumeInformation("D:",NULL, MAX_PATH,&Serial,&Length, NULL,NULL,MAX_PATH); CString StrSerial; StrSerial.Format("%ud",S 阅读全文
posted @ 2016-02-25 16:19 風行 阅读(232) 评论(0) 推荐(0)
摘要: void WriteLog(CString Msg) { CTime tm =CTime::GetCurrentTime(); CString str = tm.Format("%Y-%m-%d-%H-%M-%S"); CString sPage = str + " "+Msg+"r"+"n"; C 阅读全文
posted @ 2016-02-25 16:18 風行 阅读(695) 评论(0) 推荐(0)
摘要: #define _WidthPitch(w) ((w + w + w + 3) & 0xFFFFFFFC) void CTestPanitDlg::OnDaochu() { // TODO: Add your command handler code here CRect rect; GetClie 阅读全文
posted @ 2016-02-25 16:17 風行 阅读(2831) 评论(0) 推荐(0)
摘要: #include "stdio.h" #include "conio.h" void splitname(const char *szfullfilename, char *szpathname, char *szfilename, char *szextname); int main(void) 阅读全文
posted @ 2016-02-25 16:17 風行 阅读(778) 评论(0) 推荐(0)
摘要: BOOL BMP24to8(char *szSourceFile,char *szTargetFile) { HANDLE hSourceFile=INVALID_HANDLE_VALUE,hTargetFile=INVALID_HANDLE_VALUE; DWORD dwSourceSize=0, 阅读全文
posted @ 2016-02-25 16:16 風行 阅读(651) 评论(0) 推荐(1)
摘要: void CThreadDlg::OnOne() { // TODO: Add your control notification handler code here for (int i =1; i<=300000;i++) { for (int j =1 ; j<=300000;j++) { f 阅读全文
posted @ 2016-02-25 16:16 風行 阅读(135) 评论(0) 推荐(0)
摘要: HHOOK hook = NULL; HHOOK hook1 = NULL; LRESULT CALLBACK MouseProc//屏蔽键盘上的鼠标操作 ( int nCode, // hook code WPARAM wParam, // message identifier LPARAM lP 阅读全文
posted @ 2016-02-25 16:14 風行 阅读(530) 评论(0) 推荐(0)
摘要: void CColorDlgDlg::OnButton1() { COLORREF MyColor=RGB(0,0,0);//定义一个RGB颜色 CColorDialog Dlg(0,CC_FULLOPEN,this);//定义一个颜色对话框对象 if(IDOK==Dlg.DoModal())//如 阅读全文
posted @ 2016-02-25 16:13 風行 阅读(275) 评论(0) 推荐(0)
摘要: DLL中:cpp #define DLL_API _declspec(dllexport) #include "dll.h" #include "windows.h" #include "stdio.h" int add (int x, int y ) { return x+y ; } int su 阅读全文
posted @ 2016-02-25 16:13 風行 阅读(211) 评论(0) 推荐(0)
摘要: //写入文件 void CFDlg::OnButton1() { CFile file; file.Open("f:\test1.txt",CFile::modeCreate|CFile::modeReadWrite); file.Write("vcshare.net",strlen("vcshar 阅读全文
posted @ 2016-02-25 16:12 風行 阅读(340) 评论(0) 推荐(0)
摘要: void CActiveXCtrl::OnDraw( CDC* pdc, const CRect& rcBounds, const CRect& rcInvalid) { CBrush bursh(TranslateColor(GetBackColor())); pdc->FillRect(rcBo 阅读全文
posted @ 2016-02-25 16:12 風行 阅读(160) 评论(0) 推荐(0)
摘要: 首先,在stdafx.h文件中,导入ado15.dll,添加代码: #import "ado/msado15.dll"no_namespace rename("EOF","adoEOF") no_namespace 表示没有命名空间 rename ("EOF","adoEOF")表示将记录集结束标记 阅读全文
posted @ 2016-02-25 16:11 風行 阅读(413) 评论(0) 推荐(0)
摘要: BOOL CTestMouseDlg::OnMouseWheel(UINT nFlags, short zDelta, CPoint pt) { if(nFlags&MK_CONTROL) { if (zDelta>0) { m_ListCtrl.InsertItem(0,"滑轮向上操作"); } 阅读全文
posted @ 2016-02-25 16:11 風行 阅读(451) 评论(0) 推荐(0)
摘要: #include "stdafx.h" #include "Menu.h" #include "MainFrm.h" #ifdef _DEBUG #define new DEBUG_NEW #undef THIS_FILE static char THIS_FILE[] = __FILE__; #e 阅读全文
posted @ 2016-02-25 16:10 風行 阅读(891) 评论(0) 推荐(0)
摘要: void CMfcView::OnLButtonDown(UINT nFlags, CPoint point) { // TODO: Add your message handler code here and/or call default m_old = point; m_bool = true 阅读全文
posted @ 2016-02-25 16:09 風行 阅读(213) 评论(0) 推荐(0)
摘要: m_ImageList.Create(32,32,ILC_COLOR24|ILC_MASK,1,1); m_ImageList.Add(AfxGetApp()->LoadIcon(IDI_KAITAI)); m_ImageList.Add(AfxGetApp()->LoadIcon(IDI_CANT 阅读全文
posted @ 2016-02-25 16:09 風行 阅读(876) 评论(0) 推荐(0)
摘要: 1.下载(GDI+ for VC6.0 SDK)GDIPlus文件将其中的Includes和Lib中的文件拷到vc目录下的Includes和Lib文件夹中.下载地址:http://www.codeguru.com/code/legacy/gdi/GDIPlus.zip 2.在你将要使用GDI+的工程 阅读全文
posted @ 2016-02-25 16:08 風行 阅读(226) 评论(0) 推荐(0)
摘要: //将16进制的一个字符转换为十进制的数 unsigned char CConvNumsDlg::BtoH(char ch) { //0-9 if (ch >= '0' && ch <= '9') return (ch - '0'); //9-15 if (ch >= 'A' && ch <= 'F 阅读全文
posted @ 2016-02-25 16:08 風行 阅读(1979) 评论(0) 推荐(0)
摘要: CPoint CPaintFFRDlg::Inter(int x0,int y0,int x1,int x2,int y1,int y2,int x3,int y3,int x,int y) { bool lim1 = false,lim2 = false;//是否垂直X轴 double k1,b1 阅读全文
posted @ 2016-02-25 16:07 風行 阅读(1234) 评论(0) 推荐(0)
摘要: 工作列表( Work List )(二)1 、目的 书接前文:http://blog.csdn.net/pachleng/archive/2010/08/10/5800513.aspx,自定义患者信息,影像设备通过 DICOM 标准中的 Work List 获取登记的患者信息,并能对影像设备与“工作 阅读全文
posted @ 2016-02-25 16:07 風行 阅读(1960) 评论(0) 推荐(0)
摘要: #include "stdafx.h" #include "windows.h" #include "malloc.h" #include //十进制数转换成二进制数字 void fun_1(int n) { if(n<2) cout<<n; if(n>=2) { fun_1(n/2); cout< 阅读全文
posted @ 2016-02-25 16:07 風行 阅读(259) 评论(0) 推荐(0)
摘要: 1 、目的 在工作站上登记患者,影像设备通过 DICOM 标准中的 Work List 获取登记的患者信息。 2 、实验平台 Windows XP Professional SP2 ,其他 Windows 系统笔者未验证,希望验证过的朋友添加进来。 3 、前置条件 在您的电脑上新建文件夹如下 C:/ 阅读全文
posted @ 2016-02-25 16:06 風行 阅读(1006) 评论(0) 推荐(0)
摘要: 第一章 与影像设备互连 PACS(Picture Archiving and Communication System) ,译为医学影像归档与通讯系统,关于该名词更多详细的解释,请参考网络。 一、接收影像 1 、目的:接收影像设备发送的影像,并显示。 2 、实验平台: Windows XP Prof 阅读全文
posted @ 2016-02-25 16:05 風行 阅读(756) 评论(0) 推荐(0)
摘要: 打印影像(胶片)1 、目的:将 DICOM 影像提交至相机(干式胶片打印机),并打印。 2 、实验平台: Windows XP Professional SP2 ,其他 Windows 系统笔者未验证,希望验证过的朋友添加进来。 3 、前置条件 在您的电脑上新建文件夹如下 C:/PACS ,用于存放 阅读全文
posted @ 2016-02-25 16:03 風行 阅读(2453) 评论(0) 推荐(0)
摘要: //--------------方式1 CString SetSoftDlg::GetCurrentPath() { char lpExePathName[255]; char lpExePath[255]; char lpExeName[255]; char ExeDrive[10]; char 阅读全文
posted @ 2016-02-25 16:02 風行 阅读(8987) 评论(0) 推荐(0)
摘要: void isplit(const string& src, const string& separator, vector& dest) { string str = src; string substring; string::size_type start = 0, index; do { i 阅读全文
posted @ 2016-02-25 16:02 風行 阅读(290) 评论(0) 推荐(0)
摘要: -- ================================================ -- Template generated from Template Explorer using: -- Create Procedure (New Menu).SQL -- -- Use t 阅读全文
posted @ 2016-02-25 16:00 風行 阅读(4663) 评论(0) 推荐(0)
摘要: FILE * fp = fopen("C:\Nero.rar","rb"); if (fp == NULL) { return; } if (!fseek(fp,128,SEEK_SET)) //直接跳过文件导言 { char DICOM[5]; fread(DICOM,1,4,fp); DICOM 阅读全文
posted @ 2016-02-25 16:00 風行 阅读(618) 评论(0) 推荐(0)
摘要: //->->H #ifndef Unit_GlobalH #define Unit_GlobalH //-------------------------------------------------------------------------------------------------- 阅读全文
posted @ 2016-02-25 15:59 風行 阅读(371) 评论(0) 推荐(0)
摘要: HINSTANCE Hdl; int __stdcall (*ShowPage)();//定义函数原型 AnsiString disExeFile = ExtractFileDir(Application->ExeName)+"\ProjectDLL.dll"; Hdl = ::LoadLibrar 阅读全文
posted @ 2016-02-25 15:59 風行 阅读(697) 评论(0) 推荐(0)
摘要: if(!sQuery.IsEmpty()) { SQL+="where InsCode='"+sQuery+"'"; } if(!sProvider.IsEmpty()) { if(SQL.Pos("where")!=0) { SQL+=" and Provider='"+sProvider+"'" 阅读全文
posted @ 2016-02-25 15:58 風行 阅读(177) 评论(0) 推荐(0)
摘要: #include "SvcMgr.hpp" bool StartSQLServer() { SC_HANDLE hManager,hService; TServiceStatus ServiceStatus; bool RetVal; hManager=OpenSCManager(NULL,NULL 阅读全文
posted @ 2016-02-25 15:58 風行 阅读(292) 评论(0) 推荐(0)
摘要: void PrintAsScreen( TCanvas *CanvasSource,TPrinter *Prntr, TRect RectSource,TRect RectTarget) {//所见即所得打印方式 Prntr->BeginDoc(); int OriginalMapMode = Ge 阅读全文
posted @ 2016-02-25 15:57 風行 阅读(729) 评论(0) 推荐(0)
摘要: bool __fastcall TForm1::RunCmd( AnsiString cmd,TStringList *stringlist ) { TMemoryStream *memstream=new TMemoryStream(); AnsiString rn="\r\n"; PROCESS 阅读全文
posted @ 2016-02-25 15:56 風行 阅读(555) 评论(0) 推荐(0)
摘要: //---------------------DM H文件------------------------------------------------------ #ifndef UnitDataModuleH #define UnitDataModuleH //---------------- 阅读全文
posted @ 2016-02-25 15:55 風行 阅读(335) 评论(0) 推荐(0)
摘要: private: // User declarations void __fastcall RichNewProc1(TMessage& Message); void __fastcall RichNewProc2(TMessage& Message); __fastcall TForm1::TFo 阅读全文
posted @ 2016-02-25 15:54 風行 阅读(276) 评论(0) 推荐(0)
摘要: #define APPLE 1 #define ORANGE 2 class XFruit { public : virtual void ShowName() = 0; } ; //派生出子类商品 class Apple : public XFruit { public : void ShowNa 阅读全文
posted @ 2016-02-25 15:54 風行 阅读(213) 评论(0) 推荐(0)
摘要: #include <Registry.hpp> void __fastcall AutoRun(bool pRun) { /**//****************************************************** ** 函数名: AutoRun ** 输入: 是否设置自动 阅读全文
posted @ 2016-02-25 15:53 風行 阅读(424) 评论(0) 推荐(0)
摘要: #include <registry.hpp> //--------------------------------------------------------------------------- void __fastcall TForm1::Button1Click(TObject *Se 阅读全文
posted @ 2016-02-25 15:52 風行 阅读(684) 评论(0) 推荐(0)
摘要: void __fastcall TForm1::Button1Click(TObject *Sender) { TStringList *FileList = new TStringList(); SearchDir("c:\WINNT", FileList); Memo1->Lines->Assi 阅读全文
posted @ 2016-02-25 15:52 風行 阅读(562) 评论(0) 推荐(0)
摘要: // // MODULE: Ado.h // // AUTHOR: Carlos Antollini // // Date: 6/28/2001 // // Version 1.2 // #ifndef _ADO_H_ #define _ADO_H_ #if _MSC_VER >= 1000 #pr 阅读全文
posted @ 2016-02-25 15:51 風行 阅读(1432) 评论(0) 推荐(0)
摘要: DECLARE @DateTimeVaue VARCHAR(30) SET @DateTimeVaue = '20130402140837' -- 2013/04/02 14:08:37 --使用字串函數先將字串轉成日期格式字串再轉成DateTime (20130402140837 => 20130 阅读全文
posted @ 2016-02-25 15:49 風行 阅读(170) 评论(0) 推荐(0)
摘要: #import "c:test.dll" using namespace test; HRESULT ComInit() { HRESULT hr = S_OK; if FAILED(CoInitialize(NULL)) { CoUninitialize(); hr = E_UNEXPECTED; 阅读全文
posted @ 2016-02-25 15:49 風行 阅读(349) 评论(0) 推荐(0)
摘要: BOOL CDcmAssit::MultibmpConvertToDCM(const char * filename , const char * outputfilename ) { OFCondition status; DcmFileFormat fileformat; DcmDataset* 阅读全文
posted @ 2016-02-25 15:48 風行 阅读(840) 评论(0) 推荐(0)
摘要: 同样编译DCMTK之后会在相对应的APP文件夹下产生dcmpsprt.exe以及dcmprscu.exe这两个程序 使用命令: D:/>dcmpsprt -v -c dcmpstat.cfg –printer PRINTER image.dcm 会在database目录下生成三个文件 然后在使用命令 阅读全文
posted @ 2016-02-25 15:47 風行 阅读(345) 评论(0) 推荐(0)