access弹窗提示代码(access查询弹窗)
admin 发布:2022-12-19 22:26 169
今天给各位分享时钟代码的知识,其中也会对动态时钟代码进行解释,如果能碰巧解决你现在面临的问题,别忘了关注本站,现在开始吧!
本文目录一览:
- 1、vb 时钟代码
- 2、c语言时钟代码
- 3、FLASH时钟代码
- 4、要个简单一点的小时钟代码~
vb 时钟代码
修改并测试成功!!!!!!!!
Private Sub Form_Load()
Form1.AutoRedraw = True
Form1.Height = 8000
Form1.Width = 8000
Form1.Scale (-100, -100)-(100, 100)
Line1.X1 = 0: Line1.Y1 = 0
Line2.X2 = 0: Line2.Y1 = 0‘......Line2.X1 = 0: Line2.Y1 = 0
Line3.X1 = 0: Line3.Y1 = 0
Line1.BorderColor = RGB(0, 0, 0)
Line1.BorderWidth = 3
Line2.BorderColor = RGB(0, 0, 255)
Line2.BorderWidth = 2
Line3.BorderColor = RGB(255, 0, 0)
Line3.BorderWidth = 1
Shape1.Top = -95
Shape1.Left = -95
Shape1.Width = 190
Shape1.Height = 190
Shape1.BorderStyle = 3
Shape1.BorderWidth = 3
Shape1.BorderColor = RGB(0, 0, 255)
Timer1.Interval = 1000
End Sub
Private Sub Timer1_Timer()
sx = Sin((180 - 6 * Second(Time)) * 3.14159 / 180) * 65
sy = Cos((180 - 6 * Second(Time)) * 3.14159 / 180) * 65
Line3.X2 = sx
Line3.Y2 = sy
mx = Sin((180 - 6 * Minute(Time)) * 3.14159 / 180) * 65
my = Cos((180 - 6 * Minute(Time)) * 3.14159 / 180) * 65
Line2.X2 = mx
Line2.Y2 = my
hx = Sin((180 - (30 * Hour(Time) + 30 * Minute(Time) / 60)) * 3.14159 / 180) * 40
hy = Cos((180 - (30 * Hour(Time) + 30 * Minute(Time) / 60)) * 3.14159 / 180) * 40
Line1.X2 = hx
Line1.Y2 = hy
Form1.CurrentX = -2
Form1.CurrentY = 80
Form1.Print "6"
Form1.CurrentX = -2
Form1.CurrentY = -80
Form1.Print "12"
Form1.CurrentX = 75
Form1.CurrentY = -8
Form1.Print "3"
Form1.CurrentX = -80
Form1.CurrentY = -8
Form1.Print "9"
End Sub
Scale用于标示对象的坐标系统,其中前一组数字表示Picture1的左上角的坐标值,后一组数字表示Picture1的右下角的坐标值。因此如果你将左上角的坐标和右下角的坐标值设置为同一个坐标,则VB会认为你设置有误,会报“除数为零”的错误。
..........张志晨..............
c语言时钟代码
#includegraphics.h /* 引入graphic.h */
#includemath.h /* 引入math.h */
#includedos.h /* 引入dos.h */
#define pi 3.1415926 /*定义pi=3.14159*/
#define X(a,b,c) x=a*cos(b*c*pi/180-pi/2)+300;
#define Y(a,b,c) y=a*sin(b*c*pi/180-pi/2)+240;
#define d(a,b,c) X(a,b,c);Y(a,b,c);line(300,240,x,y) /*定义……*/
void init() /*初始化程序*/
{int i,l,x1,x2,y1,y2; /*定义……*/
setbkcolor(1); /*设置颜色*/
circle(300,240,200); /*作园*/
circle(300,240,205);
circle(300,240,5);
for(i=0;i60;i++) /*循环(算时间)*/
{if(i%5==0) l=15;
else l=5;
x1=200*cos(i*6*pi/180)+300;
y1=200*sin(i*6*pi/180)+240;
x2=(200-l)*cos(i*6*pi/180)+300;
y2=(200-l)*sin(i*6*pi/180)+240;
line(x1,y1,x2,y2);
}
}
main()
{
int x,y;
int gd=VGA,gm=2;
unsigned char h,m,s; /*定义*/
struct time t[1];
initgraph(gd,gm,"d:\\tc");
init();
setwritemode(1);
gettime(t);
h=t[0].ti_hour;
m=t[0].ti_min;
s=t[0].ti_sec; /*定义时分秒*/
setcolor(7); /*设置颜色*/
d(150,h,30);
setcolor(14);
d(170,m,6);
setcolor(4);
d(190,s,6);
while(!kbhit()) /*获取键盘相应*/
{while(t[0].ti_sec==s)
gettime(t); /*C语言中得到时间的函数*/
sound(400); /*计算时间……*/
delay(70);
sound(200);
delay(30);
nosound();
setcolor(4);
d(190,s,6);
s=t[0].ti_sec;
d(190,s,6);
if (t[0].ti_min!=m)
{
setcolor(14);
d(170,m,6);
m=t[0].ti_min;
d(170,m,6);
}
if (t[0].ti_hour!=h)
{ setcolor(7);
d(150,h,30);
h=t[0].ti_hour;
d(150,h,30);
sound(1000);
delay(240);
nosound();
delay(140);
sound(2000);
delay(240);
nosound();
}
}
getch(); /*设置空格后退出*/
closegraph();
}
具体的。。就是套用用几个函数算时间。。
不要对这种很长的东西害怕,其实大部分都是在画这个钟~
加油哦~
FLASH时钟代码
(
粉色FLASH可爱时钟
女生专用
MIni款)
(
简洁数字FLASH时钟版
黑白电子表)
(
玩的就是心跳_视觉FLASH时钟代码
黑色款)
空间水晶FLASH时钟代码)
空间黑色FLASH时钟
旋转特效)
(
按住可拖动的QQ空间时钟FLASH代码
个性ING)
要个简单一点的小时钟代码~
这个是文字时钟代码:
script
var dayarray=new Array("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday")
var montharray=new Array("January","February","March","April","May","June","July","August","September","October","November","December")
function getthedate(){
var mydate=new Date()
var year=mydate.getYear()
if (year 1000)
year+=1900
var day=mydate.getDay()
var month=mydate.getMonth()
var daym=mydate.getDate()
if (daym10)
daym="0"+daym
var hours=mydate.getHours()
var minutes=mydate.getMinutes()
var seconds=mydate.getSeconds()
var dn="AM"
if (hours=12)
dn="PM"
if (hours12){
hours=hours-12
}
if (hours==0)
hours=12
if (minutes=9)
minutes="0"+minutes
if (seconds=9)
seconds="0"+seconds
//change font size here
var cdate="smallfont color='000000' face='Arial'b"+dayarray[day]+", "+montharray[month]+" "+daym+", "+year+" "+hours+":"+minutes+":"+seconds+" "+dn
+"/b/font/small"
if (document.all)
document.all.clock.innerHTML=cdate
else
document.write(cdate)
}
if (!document.all)
getthedate()
function goforit(){
if (document.all)
setInterval("getthedate()",1000)
}
/script
body onload="goforit()"
span id="clock"/span
时钟代码的介绍就聊到这里吧,感谢你花时间阅读本站内容,更多关于动态时钟代码、时钟代码的信息别忘了在本站进行查找喔。
版权说明:如非注明,本站文章均为 AH站长 原创,转载请注明出处和附带本文链接;
- 上一篇:关于横幅广告代码的信息
- 下一篇:解交织代码(交织和解交织)
相关推荐
- 05-18seo网站排名查询,seo 网站排名
- 05-18百度seo关键词排名查询,seo关键词优化
- 05-18关键词排名提升查询,关键词排名查询工具有哪些
- 05-17爱站关键词挖掘查询工具,关键词爱站网关键词挖掘工具
- 05-16域名查询ip,域名查询
- 05-16域名网站查询,520113子域名网站查询
- 05-15百度代理公司查询,百度代理公司怎么样
- 05-15百度收录量查询,百度收录查询api
- 05-15站长工具外链查询,站长工具接口
- 05-14百度代理公司查询,百度授权代理查询
取消回复欢迎 你 发表评论:
- 标签列表
- 最近发表
- 友情链接