资源简介
用JAVA编写的备忘录, 可以记录下你每天做的事情,可以查看你以前做的事情,很有帮助
代码片段和文件信息
import java.awt.*;
import java.awt.event.*;
import java.awt.Color;
import javax.swing.*;
import javax.swing.event.*;
import javax.swing.border.*;
import java.util.*;
import java.util.Calendar;
import java.io.*;
import java.io.IOException;
public class calendar extends Jframe
implements ActionListenerMouseListener
{
int yearmonthday;
int yearafterquerymonthafterquery;
int startday;
String SwitchMonth;
String key;
int changeyearmessage;
int changemonthmessage;
int priormonthprioryear;
boolean ischange=falseischange_priornext=false;
private JPanel LeftPaneRightPane;
private JLabel YearLabel;
private JLabel MonthLabel;
private JComboBox MonthCombobox;
private JTextField ShowDays[]=new JTextField[42];
private JTextField YearText;
private JLabel Ask;
private JLabel ShowDate;
private JLabel Blank;
private JLabel show;
private JLabel TopBartitle[]=new JLabel[7];
private JButton ToToday;
private JButton Query;
private String week[]={“星期日““星期一““星期二““星期三““星期四““星期五““星期六“};
private JLabel NorthMonthDayYear;
private JTextArea CenterText;
private JButton SouthSaveSouthDelete;
private JButton PriorMonth;
private JButton NextMonth;
public calendar(int yearint monthint day)
{
settitle(“备忘录“);
//the layout about left of Jpane
RightPane=new JPanel();
JPanel rightCenter=new JPanel();
JPanel rightNorth=new JPanel();
RightPane.setLayout(new BorderLayout());
RightPane.add(rightNorthBorderLayout.NORTH);
RightPane.add(rightCenterBorderLayout.CENTER);
RightPane.add(ToToday=new JButton(“Go to today“)BorderLayout.SOUTH);
ToToday.setBackground(Color.cyan);
ToToday.addActionListener(this);
RightPane.validate();
rightNorth.setLayout(new GridLayout(310-2));
rightNorth.add(Ask=new JLabel(“请输入你要查询的日子“));
JPanel North=new JPanel(new FlowLayout(080));
rightNorth.add(North);
North.add(YearLabel=new JLabel(“年:“));
North.add(YearText=new JTextField(4));
YearText.setBackground(Color.getHSBColor(302050));
YearText.setForeground(Color.blue);
YearText.setFont(new Font(“TimesRoman“Font.BOLD17));
YearText.addActionListener(this);
YearText.setFocusable(true);
North.add(Blank=new JLabel(“月:“));
North.add(MonthCombobox=new JComboBox());
//add month to monthcombobox
for(int i=1;i<=12;i++)
{
MonthCombobox.addItem(new Integer(i));
}
//Switch the month
MonthCombobox.setForeground(Color.blue);
MonthCombobox.setFont(new Font(“TimesRoman“Font.BOLD12));
North.add(Query=new JButton(“查询“));
Query.setForeground(Color.blue);
Query.addActionListener(this);
JPanel North2=new JPanel(new FlowLayout());
rightNorth.add(North2);
North2.add(PriorMonth=new
- 上一篇:成组链接法Java版
- 下一篇:Android下雪特效
相关资源
- java串口通信全套完整代码-导入eclip
- jsonarray所必需的6个jar包.rar
- 三角网构TIN生成算法,Java语言实现
- java代码编写将excel数据导入到mysql数据
- Java写的cmm词法分析器源代码及javacc学
- JAVA JSP公司财务管理系统 源代码 论文
- JSP+MYSQL旅行社管理信息系统
- 推荐算法的JAVA实现
- 基于Java的酒店管理系统源码(毕业设
- java-图片识别 图片比较
- android毕业设计
- java23种设计模式+23个实例demo
- java Socket发送/接受报文
- JAVA828436
- java界面美化 提供多套皮肤直接使用
- 在线聊天系统(java代码)
- 基于Java的图书管理系统807185
- java中实现将页面数据导入Excel中
- java 企业销售管理系统
- java做的聊天系统(包括正规课程设计
- Java编写的qq聊天室
- 商店商品管理系统 JAVA写的 有界面
- JAVA开发聊天室程序
- 在linux系统下用java执行系统命令实例
- java期末考试试题两套(答案) 选择(
- JAVA3D编程示例(建模、交互)
- Java 文件加密传输
- java做的房产管理系统
- 基于jsp的bbs论坛 非常详细
- [免费]java实现有障碍物的贪吃蛇游戏
评论
共有 条评论