05 2013 档案

摘要:首先在VS2010中创建一个cocos2dx项目,确保其能正常编译运行然后在HelloWorld头文件中申明重载虚方法:添加引用【#include "cocos2d.h"】和【USING_NS_CC;】,并在public中添加下列申明:virtual void registerWithTouchDispatcher();//注册触屏事件监听 virtual bool ccTouchBegan(CCTouch *pTouch, CCEvent *pEvent);// 必须实现virtual void ccTouchMoved(CCTouch *pTouch, CCEvent 阅读全文
posted @ 2013-05-30 09:37 BicycleBoy 阅读(1653) 评论(0) 推荐(0)
摘要:首先编辑cocos2dx目录下的[X:\cocos2dx\template\msvc\CCAppWiz.win32\Scripts\1033\]“default.js”文件,将Compiler settings的文件引用路径都换成绝对路径如下:// Compiler settingsvar CLTool = config.Tools('VCCLCompilerTool');// Additional Inlcude Directoriesvar strAddIncludeDir = '.;..\\Classes';strAddIncludeDir +=' 阅读全文
posted @ 2013-05-29 11:54 BicycleBoy 阅读(2358) 评论(0) 推荐(0)
摘要:1、下载安装JAVA,Eclipse,CDT解压后将features和plugins拷到Eclipse对应目录中既可2、下载安装CYGwin,并将安装目录加入系统变量X:\cygwin\bin,在命令行中执行make -v检测CYGwin安装是否成功 并修改Cygwin的[cygwin安装目录]\home\[你的用户名]\.bash_profile文件,添加如下代码: # fi NDK_ROOT=/cygdrive/<你的盘符>/<android ndk 目录> export NDK_ROOT3、下载NDK解压到任意目录4、下载Cocos2dx并解压,并修改cocos2 阅读全文
posted @ 2013-05-24 13:11 BicycleBoy 阅读(711) 评论(0) 推荐(0)
摘要:首先去官网下载AndroidStudio安装包然后就是进行安装,安装过程中只需要一路狂点NEXT就行了,64位下安装会出错“Java SE Development Kit (JDK) not foundError:Failed to find java version for 'C:\windows\system32\java.exe': [2] 系统找不到指定的文件”安装程序被迫终止,不过别急按下面的方式既可解决:1、建立JAVA_HOME变量值指向你的JAVA安装根目录2、找到Path变量,如果没有新建一个好了,添加变量值“%JAVA_HOME%\jre\bin;%JAVA 阅读全文
posted @ 2013-05-23 17:39 BicycleBoy 阅读(353) 评论(0) 推荐(0)
摘要:1.Check the UbuntuOS version:cat /etc/issue2.How to install deb software:sudo dpkg -i your-package.deb3.How to install Language Support[Example English]:The following command will list language packs that can be installed:apt-cache search language-packThe packs can be install by entering (for Englis 阅读全文
posted @ 2013-05-19 13:49 BicycleBoy 阅读(183) 评论(0) 推荐(0)
摘要:数据据库结构:id subjectname parentidC#实现代码:StringBuilder html = new StringBuilder(); protected void Page_Load(object sender, EventArgs e) { DataTable dt = getTable("SELECT [Id],[subjectname],[ParentId] FROM [FileTree]"); if (dt.Rows.Count >0) { ... 阅读全文
posted @ 2013-05-19 13:48 BicycleBoy 阅读(1422) 评论(0) 推荐(0)
摘要:Microsoft Visual C++ 6.0 SP6 简体中文版 Microsoft Visual C++,简称 MSVC、VC++或VC,是微软公司 Visual Studio 系列中的C++开发工具,具有集成开发环境,具有编辑C语言,C++ 以及C++/CLI等编程语言的能力。 VC++整合了便利的除错工具,特别是整合了 Windows API、DirectX API 和 Microsoft .NET 框架(6.0 没有)。目前最新的版本是Microsoft Visual C++ 2008,Visual C++ 6.0 是其经典版本。Visual C++以拥有“语法高亮”,Intel. 阅读全文
posted @ 2013-05-19 13:30 BicycleBoy 阅读(1028) 评论(0) 推荐(0)
摘要:AeroWindow--JQuery插件 AeroWindow是个Win7样式的弹出窗口,jQuery插件,效果很酷!而且还像windows的窗口一样可最大,最小化,随意拖动。可以一个页面中创建多个弹出窗,被选中的弹出窗会加亮显示,在同一网页中可以有多个弹出窗口,也可以通过双击窗口实现最大化,跟windows像极了。如果想要做一个类似操作系统的页面,用这个插件是完全可以实现的。兼容多种主流浏览器。 最基础的调用方法:view sourceprint?$('#YourContainerDiv').AeroWindow((WindowTitle:'hello world&# 阅读全文
posted @ 2013-05-19 13:27 BicycleBoy 阅读(1437) 评论(0) 推荐(0)
摘要:后台代码 private void fillit() { string message = Session["sqlmessage"].ToString(); searchT.Visible = false; fillrepeater(message); } private void fillrepeater(string sqlstring) { BLL.Plan_Work bpw = new BLL.Plan_Work(); DataTable ds = bpw.GetList(sqlstring).Table... 阅读全文
posted @ 2013-05-19 13:20 BicycleBoy 阅读(209) 评论(0) 推荐(0)
摘要:为objectdatasource指定数据源前端代码<asp:ObjectDataSource ID="datasource" TypeName="PageTest.PersonInfo"SelectMethod="GetMessage" runat="server"> </asp:ObjectDataSource><asp:ListView ID="ListView1" runat="server" DataSourceID="dat 阅读全文
posted @ 2013-05-19 13:12 BicycleBoy 阅读(173) 评论(0) 推荐(0)
摘要:JS 实现简单的页面局部打印function preview(oper){if (oper < 10){bdhtml=window.document.body.innerHTML;//获取当前页的html代码sprnstr="<!--startprint"+oper+"-->";//设置打印开始区域eprnstr="<!--endprint"+oper+"-->";//设置打印结束区域prnhtml=bdhtml.substring(bdhtml.indexOf(sprnstr)+18 阅读全文
posted @ 2013-05-19 13:12 BicycleBoy 阅读(199) 评论(0) 推荐(0)
摘要:SON页<html><head> <title>计划选择</title> <script src="Scripts/jquery-1.4.1.js" type="text/javascript"></script> <script type="text/javascript"> $.post("gervalue.ashx", { "action": "getpagedata", "p 阅读全文
posted @ 2013-05-19 12:58 BicycleBoy 阅读(1000) 评论(0) 推荐(0)
摘要:一般处理程序页using System;using System.Collections.Generic;using System.Linq;using System.Web;using System.Data;using PublicTool;namespace OA.Module.WorkReport{ /// <summary> /// pageData 的摘要说明 /// </summary> public class pageData : IHttpHandler { public void ProcessRequest(HttpContext context 阅读全文
posted @ 2013-05-19 12:57 BicycleBoy 阅读(220) 评论(0) 推荐(0)
摘要:<html xmlns="http://www.w3.org/1999/xhtml"><head> <title></title> <script src="../Scripts/jquery-1.4.1.js" type="text/javascript"></script> <script src="../Scripts/Datepicker/WdatePicker.js" type="text/javascript&quo 阅读全文
posted @ 2013-05-19 12:55 BicycleBoy 阅读(395) 评论(0) 推荐(0)
摘要:页面前端JSfunction filldate(type, page, status) {//类型,页号,状态 $.post("showdata.ashx", { "par": type + ',' + page + "," + status }, function (data, status) { if (data != "") { var data1 = data.split(";"); $("#showdata").empty(); $("#s 阅读全文
posted @ 2013-05-19 12:53 BicycleBoy 阅读(490) 评论(0) 推荐(0)
摘要:SqlParameter[] sp = new SqlParameter[] {new SqlParameter("@id", SqlDbType.Int),new SqlParameter("@age", SqlDbType.Int) };//实例化一个SqlParameter对像 sp[0].Value = 1;//为SqlParameter对像赋值 sp[1].Direction = ParameterDirection.Output;//将对像中指定参数设置为输出变量public SqlParameter[] pulicMethod(string 阅读全文
posted @ 2013-05-19 12:50 BicycleBoy 阅读(444) 评论(0) 推荐(0)
摘要:前端代码:数据库表结构如下:id pname parent记得引用jquery和SelectPermission外部JS文件<style type="text/css"> #showhide { width: 100%; height: 100%; background-color: #FFFFFF; position: absolute; left: 0; top: 0; display: none; } #selectPermission{ width:100%; line-height:25px... 阅读全文
posted @ 2013-05-19 12:48 BicycleBoy 阅读(567) 评论(0) 推荐(0)
摘要:页面代码:NOTE:需要jquery插件(Uploadify)下载地址:uploadify下载<%@ Page Language="C#" CodeBehind="AsynchronousUpload.aspx.cs"Inherits="Example.AsynchronousUpload" %><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/x 阅读全文
posted @ 2013-05-19 12:38 BicycleBoy 阅读(1155) 评论(0) 推荐(0)
摘要:1、删除多余启动项 重装系统后有时会残留下以前版本的系统启动项,而且在系统配置启动项中见不到,但在电脑起动和故障恢复属性中确存在,可以用以下方式彻底删除: (1)在命令提示符模式下输入:【bcdedit】查看当前所有系统启动项 (2)接着输入【bcdedit /delete /?】查看当前系统中存在 阅读全文
posted @ 2013-05-19 12:37 BicycleBoy 阅读(232) 评论(0) 推荐(0)
摘要:<head runat="server"><title></title><script src="script/jquery-1.4.1.js" type="text/javascript"></script><script type="text/javascript">function getCookie(c_name) {if (document.cookie.length > 0) {c_start = document.cooki 阅读全文
posted @ 2013-05-19 12:36 BicycleBoy 阅读(123) 评论(0) 推荐(0)
摘要:private void cookieSerilizse(){//序列化string str = "I'm a test data";IFormatter fm = new BinaryFormatter();//实例化一个二进制序列化对象MemoryStreamms=new MemoryStream();//实例如化一个内存流对象fm.Serialize(ms, str);//进行序列化ms.Seek(0, SeekOrigin.Begin);//指定当前流的位置StreamReader sr = new StreamReader(ms);//实例化流的新实例st 阅读全文
posted @ 2013-05-19 12:35 BicycleBoy 阅读(1158) 评论(0) 推荐(0)
摘要:public static string IPAddress{get{string userIP;// HttpRequest Request = HttpContext.Current.Request;HttpRequest Request = HttpContext.Current.Request; // ForumContext.Current.Context.Request;// 如果使用代理,获取真实IPif (Request.ServerVariables["HTTP_X_FORWARDED_FOR"] != "")userIP = Requ 阅读全文
posted @ 2013-05-19 12:33 BicycleBoy 阅读(384) 评论(0) 推荐(0)
摘要://对字符串进行SHA1摘要public string EncryptToSHA1(string str){ SHA1CryptoServiceProvider sha1 = new SHA1CryptoServiceProvider(); byte[] ... 阅读全文
posted @ 2013-05-19 12:33 BicycleBoy 阅读(402) 评论(0) 推荐(0)
摘要:$("a").mouseenter(function () {var setx = this.offsetLeft;var sety = this.offsetTop;//alert(setx + "," + sety);$("#showd").css({'top': sety + 20 + 'px','left': setx + 50 + 'px','position': 'absolute','background': 阅读全文
posted @ 2013-05-19 12:31 BicycleBoy 阅读(252) 评论(0) 推荐(0)
摘要:public Bitmap CutBitmap(Bitmap b, int left, int top, int Width, int Height)//对图片进行裁剪{Bitmap bm = b;Graphics g = Graphics.FromImage(bm);g.DrawImage(b, new Rectangle(0, 0, bm.Width, bm.Height), new Rectangle(left, top, Width, Height), GraphicsUnit.Pixel);g.Dispose();Bitmap bmp=ResizeBitmap(bm, 150, 15 阅读全文
posted @ 2013-05-19 12:30 BicycleBoy 阅读(738) 评论(0) 推荐(0)
摘要:<script type="text/javascript">$(function () {var url_arr = GetURLRequest(window.location.href).split('|'); //获取当前页REQUEST集合,并存入数组。alert(url_arr);});function GetURLRequest(Url) {var u, g, StrBack = '', RETURNVALUE = "";if (arguments[arguments.length - 1] == 阅读全文
posted @ 2013-05-19 12:30 BicycleBoy 阅读(248) 评论(0) 推荐(0)
摘要:显示进入目标中的所有页面:将conf文件夹内的server.xml中〈init-param〉节点下的〈param-value〉false〈/param-value>下的false改为true既可;添加新的虚拟目录:在conf文件夹内的web.xml中的前面加上既可. 阅读全文
posted @ 2013-05-19 12:29 BicycleBoy 阅读(126) 评论(0) 推荐(0)
摘要:启动oracle服务:net start OracleService[数据库名]启动oracle监听器:lsnrctl status查看运行状态lsnrctl stop停止监听lsnrctl start启动监听连接到指定数据库:conn [用户名]/[密码]@[数据库名];conn [用户名]/[密码] as sysdba 以管理员身份连接数据库为数据库添加新用户:先以数据库管理员的身份连接到指定数据库:conn [用户名]/[密码]@[数据库名] as sysdba;查看用户默认表空间:select username,default_tablespace from dba_users;创建用 阅读全文
posted @ 2013-05-19 12:27 BicycleBoy 阅读(395) 评论(0) 推荐(0)
摘要:数据导出:1.将数据库TEST完全导出,用户名system密码manager导出到D:\daochu.dmp中exp [用户名]/[口令]@[SID] file=d:\daochu.dmp full=y2.将数据库中system用户与sys用户的表导出exp [用户名]/[口令]@[SID] file=d:\daochu.dmp owner=(system,sys)3.将数据库中的表inner_notify、notify_staff_relat导出exp [用户名]/[口令]@[SID] file= d:\data\newsmgnt.dmp tables=(inner_notify,notif 阅读全文
posted @ 2013-05-19 12:19 BicycleBoy 阅读(151) 评论(0) 推荐(0)
摘要:1.下载dex2jarhttp://code.google.com/p/dex2jar/downloads/list以及jadhttp://www.cr173.com/soft/22741.html2.解压*.apk包找到里面的classes.dex3.在cmd下进入dex2jar目录找到dex2jar.bat所在路径,然后输入“dex2jar.bat XXX”,XXX指的是你要反编译的apk中的classes.dex完整路径4.再用解压缩工具将上面得到的classes.dex.dex2jar.jar解压,最后再用jad反编译,命令格式:jad -o -r -d[输出目录] -sjava [c 阅读全文
posted @ 2013-05-19 12:18 BicycleBoy 阅读(154) 评论(0) 推荐(0)
摘要:去除本地WIFI流量,只统计2G/3G流量数据存储:package com.android.oa.PublicTool;//获取网络数据public class HttpData {public static String userId = "";public static String checkCode = "";public static boolean isNetwork = false;public static String GetData(Context context, String httpUrl) { getTotalBytes(co 阅读全文
posted @ 2013-05-19 12:17 BicycleBoy 阅读(619) 评论(0) 推荐(0)
摘要:生成sql脚本在MSSQL中执行报错解决办法:对生成sql脚本的模板进修改:1.去掉蓝色部分的两条变量声明语名(Table和Column一样)2.将下图红色部分dbo改成当前数据库所有者名即可,记得带单引号['dbo']生成WORD文档:第一步,点击Report-->Report Temlates 制作模板第二步,点New图标新建生成模板在左边Aavailable区域中选择你想要在WORD文档中展示的东东,这里我们选择List of Tables,和表属性List of Table Columns[数据表格信息]在右边视图中,右键菜单中点击Selection选择你想要在数 阅读全文
posted @ 2013-05-19 12:16 BicycleBoy 阅读(341) 评论(0) 推荐(0)
摘要:function Len(str) {var i, sum;sum = 0;for (i = 0; i = 0) && (str.charCodeAt(i) <= 255))//如果是中文一个字为两个字节sum = sum + 1;elsesum = sum + 2;}return sum;} 阅读全文
posted @ 2013-05-19 12:08 BicycleBoy 阅读(215) 评论(0) 推荐(0)
摘要:报如下错误:ORA-00119: invalid specification for system parameter LOCAL_LISTENERORA-00132: syntax error or unresolved network name 'LISTENER_ORCL'解决方案:修改tnsnames.ora文件,添加下面的语句LISTENER_ORCL =(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))然后在SQLPLUS里面startup搞定了 阅读全文
posted @ 2013-05-17 16:41 BicycleBoy 阅读(155) 评论(0) 推荐(0)
摘要:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Text;using System.Windows.Forms;using WIA;using System.IO;using System.Net;using System.Threading;using System.Drawing.Imaging;using System.Text.RegularExpressions;namespace 阅读全文
posted @ 2013-05-17 16:39 BicycleBoy 阅读(374) 评论(0) 推荐(0)
摘要:name--->comment:Option ExplicitValidationMode = TrueInteractiveMode = im_BatchDim mdl 'the current model'get the current active modelSet mdl = ActiveModelIf (mdl Is Nothing) ThenMsgBox "There is no current Model"ElseIf Not mdl.IsKindOf(PdPDM.cls_Model) ThenMsgBox "The curre 阅读全文
posted @ 2013-05-17 16:25 BicycleBoy 阅读(310) 评论(0) 推荐(0)
摘要:asp.net开发中,经常遇到“从客户端检测到有潜在危险的Request.Form 值”错误提示,很多人给出的解决方案是:1、web.config文档<system.web>后面加入这一句: <pages validaterequest="false"/>示例:< ?xml version="1.0" encoding="gb2312" ?>< configuration>< system.web>< pages validaterequest="false& 阅读全文
posted @ 2013-05-17 16:23 BicycleBoy 阅读(1731) 评论(0) 推荐(0)
摘要:<asp:TextBoxiv="l_10_n"id="txtOutfitAmount" runat="server" Width="200px"></asp:TextBox>JS代码:$(function () {$("input[iv]").blur(function () {var typevalue = $(this).attr("iv");var tvs = typevalue.split("_");if (tvs[0] = 阅读全文
posted @ 2013-05-17 16:19 BicycleBoy 阅读(296) 评论(0) 推荐(0)
摘要:1、 定义游标:declare cursor_name cursorFor select 语句;2、 打开游标:open cursor_name3、 循环访问游标中的每一行数据:Fetch next from cursor_name into @参数列表4、 游标的状态:@@fetch_status,用于判断游标fetch的状态,当为0时正常,不为一时异常5、关闭并释放资源例:declare@whcIdnchar(5),@whcint;declarewhc_cursorcursorforselectCustomerID,EmployeeIDfromdbo.Ordersopenwhc_curso 阅读全文
posted @ 2013-05-17 16:17 BicycleBoy 阅读(172) 评论(0) 推荐(0)
摘要:CREATE PROCEDURE p25 (OUT return_val INT)BEGINDECLARE a,b INT;DECLARE cur_1 CURSOR FOR SELECT s1 FROM t;DECLARE CONTINUE HANDLER FOR NOT FOUNDSET b = 1;OPEN cur_1;REPEATFETCH cur_1 INTO a;UNTIL b = 1END REPEAT;CLOSE cur_1;SET return_val = a;END; 阅读全文
posted @ 2013-05-17 16:15 BicycleBoy 阅读(182) 评论(0) 推荐(0)
摘要:1.首先去官网下载安装包,下载地址:http://www.ibm.com/developerworks/cn/downloads/im/udbexp/,到了最终下载页只下载db2_v101_win_expc这个安装包就行了2.将安装包减压进行安装,记下安装过程的用户名和密码,以及数据库名称,安装结束时会有一个提示,执行提示里的文件,最后安装安成后会提示第一步创建概要文件,单击左边按钮创建即可。3.配置节点和数据库目录--注册节点catalog tcpip node [节点名] remote [IP] server 50000;--注册数据库catalog database [数据库名] at. 阅读全文
posted @ 2013-05-17 16:13 BicycleBoy 阅读(2285) 评论(0) 推荐(0)
摘要:db2创建存储过程有两种方式,一种是在数据库管理工具中创建,二是在命令行下创建在数据库管理工具data studio中创建存储过程:一、首先去DB2官网下载以下安装包:版本号:DB2 v10.1.0.872DB2 Express-Cdb2_v101_win_expc.exe(425MB)Data Studio Administration Clientibm_data_studio_standalone_win_V311.zip(336MB)下载地址:点击前往DB2下载地址下载解压安装完成后,连接到DB2数据库,如果在连接过程中用户名和密码都确定是正确的,却无法连接数据库,将主机中的参数loc 阅读全文
posted @ 2013-05-17 16:12 BicycleBoy 阅读(3802) 评论(0) 推荐(0)
摘要:读取:XmlDocument xmlDoc = new XmlDocument();xmlDoc.Load(@ConfigurationManager.AppSettings["SitePath"] + "iwms.config");XmlNodeList ndlist = xmlDoc.getElementsByTagName_r("mssql");string temp = string.Empty;foreach (XmlNode xl in ndlist){temp = "server=" + xl.Chi 阅读全文
posted @ 2013-05-17 16:08 BicycleBoy 阅读(284) 评论(0) 推荐(0)
摘要:mysql 1045 access denied for user 解决方法命令行中修改密码:mysql -u rootmysql> use mysql;mysql> UPDATE user SET Password = PASSWORD('newpass') WHERE user = 'root'... 阅读全文
posted @ 2013-05-17 16:06 BicycleBoy 阅读(218) 评论(0) 推荐(0)
摘要:private static void GetFirstPageInfo(string pagedata) { MatchCollection mc = Regex.Matches(pagedata, @everyArray[1]);//(.*?) if (mc.Count > 0) { sonpagecount = mc.Count; threads = new Thread[sonpagecount]; string[] pagestr = new string[8]; for (int i... 阅读全文
posted @ 2013-05-17 16:05 BicycleBoy 阅读(1261) 评论(0) 推荐(0)
摘要:Java代码publicclassImportThreadextendsThread{privatestaticListrunningThreads=newArrayList();publicImportThread(){}@Overridepublicvoidrun(){regist(this);//线程开始时注册System.out.println(Thread.currentThread().getName()+"开始...");//打印开始标记//做一些事情......unRegist(this);//线程结束时取消注册System.out.println(Thre 阅读全文
posted @ 2013-05-17 15:56 BicycleBoy 阅读(820) 评论(0) 推荐(0)
摘要:创建存储过程:CREATEPROCEDURE '存储过程名'(_field varchar(400),_table varchar(50),_whe varchar(200),_begin int,_amount int)BEGINdeclare sSqlvarchar(4000);set sSql=concat('select ',_field,' from ',_table,' where ',_whe,' limit ',_begin,',',_amount);set @qstr=sSql;p 阅读全文
posted @ 2013-05-17 15:50 BicycleBoy 阅读(276) 评论(0) 推荐(0)
摘要:首先到官网下载软件包官方下载地址:http://www.mongodb.org/downloads接着配置Mongo服务端:打开一个新的命令窗口输入如下命令:>d:>cd mongoDB\bin>mongod --dbpath d:mongoDB\data[集合路径]如果没有出现错误提示,服务器就算启动成功了MongoDB基本使用成功启动MongoDB后,再打开一个命令行窗口输入mongo,就可以进行数据库的一些操作。输入help可以看到基本操作命令:show dbs:显示数据库列表show collections:显示当前数据库中的集合(类似关系数据库中的表)show us 阅读全文
posted @ 2013-05-17 15:48 BicycleBoy 阅读(156) 评论(0) 推荐(0)