回复:wincc 的数据库的的在线备份及清空

cloak

  • 帖子

    286
  • 精华

    0
  • 被关注

    0

论坛等级:游侠

注册时间:2003-06-06

普通 普通 如何晋级?

发布于 2003-07-08 09:28:08

0楼

用Dbase III格式#include "apdefap.h"
void OnLButtonDown(char* lpszPictureName,
char* lpszObjectName, char* lpszPropertyName,
UINT nFlags, int x, int y)
{
#pragma code("kernel32.dll");
char *pp,e[40],temp[100];
void GetLocalTime(SYSTEMTIME*lpst);
DWORD Val,Valm,Vald;
char TmpStr[64];

BOOL CopyFileA(LPCTSTR,LPCTSTR,BOOL);
#pragma code()



SYSTEMTIME time;
GetLocalTime(&time);
SetTagDWord("year",time.wYear); //Return-Type :BOOL
SetTagDWord("month",time.wMonth); //Return-Type :BOOL
SetTagDWord("day",time.wDay); //Return-Type :BOOL
SetTagDWord("hour",time.wHour); //Return-Type :BOOL
SetTagDWord("minute",time.wMinute); //Return-Type :BOOL
SetTagDWord("second",time.wSecond); //Return-Type :BOOL



Val = GetTagDWord("year");
Valm= GetTagDWord("month");
Vald = GetTagDWord("day");

sprintf (TmpStr, "%u%u%u%u%u%u",
Val,Valm,Vald,GetTagDWord("hour"),
GetTagDWord("minute"),GetTagDWord("second"));
SetTagChar ("txtyear", TmpStr);
printf("\"%s\"\r\n",TmpStr);


strcpy(temp,"H:\\useful_email\int2str\\PDE\\test\\"); //Return-Type :char*

strcat(temp,GetTagChar ("txtyear"));


strcat(temp,".dbf");
printf("\"%s\"\r\n",temp);

CopyFileA("H:\\useful_email\\int2str\PDE\\test\\test.dbf",temp,FALSE);

}

评论
编辑推荐: 关闭

请填写推广理由:

本版热门话题

SIMATIC WinCC / Panel

共有32771条技术帖

相关推荐

热门标签

相关帖子推荐

guzhang

恭喜,你发布的帖子

评为精华帖!

快扫描右侧二维码晒一晒吧!

再发帖或跟帖交流2条,就能晋升VIP啦!开启更多专属权限!

  • 分享

  • 只看
    楼主

top
X 图片
您收到0封站内信:
×
×
信息提示
很抱歉!您所访问的页面不存在,或网址发生了变化,请稍后再试。