摘要: asp.net 服务器获取真实IP /// <summary> /// 穿过代理服务器获取真实IP /// </summary> /// <returns></returns> public string AcceptTrueIP() { string user_IP = null; if (HttpContext.Current.Request.ServerVariables["HTTP_VIA"] != null) { user_IP = HttpContext.Current.Request.ServerVariable 阅读全文
posted @ 2011-03-04 15:59 杨歪歪→YY 阅读(1093) 评论(0) 推荐(0) 编辑
摘要: 第一步: 新创建一Win窗口项目,并添加Web引用飞信WebService,引用地址:http://io.139icq.com/fWebSer.asmx?WSDL,重命名引用为:FetionObj第二步: 添加以下相关控件到主窗口1、加TextBox控件用于显示收到的相关信息 命名:showtxt,设此控件Multiline=true,使能显示多行,并拖大些。2、加TextBox控件用于输入登录号... 阅读全文
posted @ 2010-07-12 13:35 杨歪歪→YY 阅读(680) 评论(0) 推荐(0) 编辑
摘要: 后台:using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;namespace SPAT{ deleg... 阅读全文
posted @ 2010-07-12 13:26 杨歪歪→YY 阅读(2060) 评论(0) 推荐(0) 编辑
摘要: using System;using System.Collections.Generic;using System.Text;using System.IO.Ports;namespace EAD.POS{ class SerialPortOutput { /// <summary> /// 总计 /// </summary> /// <param name="va... 阅读全文
posted @ 2010-07-12 11:56 杨歪歪→YY 阅读(1976) 评论(0) 推荐(0) 编辑
摘要: 昨天在公司写东西,用到了ComboBox控件,vs 2005的winform窗体中如果有个ComboBox里面也有Item在,可是你会发现,在你选择了其中的某个Item后在这个选项的最后仍然可以输入东西进去。个人感觉这个很不好,但是ComboBox又没有给出只读的属性。那么在这个ComboBox的KeyPress事件下,你可以加入以下代码: //锁定键盘只有TAB键\上下键\回车键可用 priva... 阅读全文
posted @ 2010-06-02 09:47 杨歪歪→YY 阅读(462) 评论(0) 推荐(0) 编辑
摘要: 1.怎样定制VC#DataGrid列标题?  DataGridTableStyle dgts = new DataGridTableStyle();   dgts.MappingName = "myTable"; //myTable为要载入数据的DataTable   DataGridTextBoxColumn dgcs = new DataGridTextBoxColumn();   dgcs.... 阅读全文
posted @ 2010-05-29 14:22 杨歪歪→YY 阅读(281) 评论(0) 推荐(0) 编辑
摘要: using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace DAL.TOOLDAL{ public class ConvertPY { public string GetPYString(string str) { string tempStr = ""; foreach (... 阅读全文
posted @ 2010-05-20 15:10 杨歪歪→YY 阅读(809) 评论(0) 推荐(1) 编辑
摘要: using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace DAL.TOOLDAL{ public class ConvertChIAmount { public string ConvertSum(string str) { if (!IsPositveDecimal(st... 阅读全文
posted @ 2010-05-20 13:57 杨歪歪→YY 阅读(1032) 评论(0) 推荐(1) 编辑
摘要: using System;using System.Text;using System.Globalization;using System.Security.Cryptography;using System.Windows.Forms;using System.IO;namespace DAL.TOOLDAL{ public class EncAndDec { const string KEY... 阅读全文
posted @ 2010-05-20 13:55 杨歪歪→YY 阅读(881) 评论(0) 推荐(3) 编辑
摘要: ESC/P2模式 一般操作 初始化打印机 ESC @ 控制装纸/退纸 ESC EM n 删除最后一个字符 DEL 取消一行 CAN 送纸 选择1/8英寸的行间距 ESC 0 选择1/6英寸的行间距 ESC 2 选择n/180英寸的行间距 ESC 3 选择n/360英寸的行间距 ESC + 选择n/60英寸的行间距 ESC A 换行 LF 换页 FF 执行垂直定位 VT 执行n/180英寸的换行 E... 阅读全文
posted @ 2010-05-18 09:26 杨歪歪→YY 阅读(2172) 评论(1) 推荐(0) 编辑