自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(0)
  • 资源 (23)
  • 收藏
  • 关注

空空如也

flex算两线交点

flex算两线交点 ExampleApplication1=new ExampleApplication(); // ExampleApplication1.showMessage( ); graphics.lineStyle(1, Math.random( ) * 0xffffff, 1); graphics.moveTo(Math.random( ) * 400, Math.random( ) * 400); graphics.lineTo(Math.random( ) * 400, Math.random( ) * 400); //Alert.show(intersection( a, b, c, d ).toString() ); // 输出 : (x=80, y=80) } public static function intersection( a:Object, b:Object, c:Object, d:Object ):Point { var pos1 = (b.y-a.y)/(b.x-a.x); var pos2 = (d.y-c.y)/(d.x-c.x); var pi = Number.POSITIVE_INFINITY; var ni = Number.NEGATIVE_INFINITY; if(pos1==pos2){ return null; }

2016-02-24

flex DataGrid 导出Xls

flex DataGrid 导出Xls private function insertRecordInSheet(row:int,sheet:Sheet,record:Object):void { var colCount:int = rebateByItemDG.columnCount; for(var c:int; c < colCount; c++) { var i:int = 0; for each(var field:String in fields){ for each (var value:String in record){ if (record[field].toString() == value) sheet.setCell(row,i,value); } i++; } } }

2016-02-24

flex 画图的例子,很不错

flex 画图的例子,很不错 //画圆角矩形 private function circleRect(cRectX:Number, cRectY:Number, cRectWidth:Number, cRectHeight:Number, cRectDU:Number):void{ cRectBoxID.graphics.clear(); if(radioLineID.selected){ //线性 cRectBoxID.graphics.lineStyle(20, 0xFF0000, 1.0, false, LineScaleMode.VERTICAL, CapsStyle.NONE, JointStyle.MITER, 100); }else if(radioGradientID.selected){ //渐变 //the last parameter can selete three type: SpreadMethod.PAD or SpreadMethod.REFLECT or SpreadMethod.REPEAT. cRectBoxID.graphics.beginGradientFill(GradientType.LINEAR, [0xFF0000, 0x0000FF], [1, 0.1], [0, 255], new Matrix(), SpreadMethod.PAD); rectBoxID.graphics.endFill(); }else if(radioFullID.selected){ //填充 cRectBoxID.graphics.beginFill(0xFF0000, 1.0); } cRectBoxID.graphics.drawRoundRect(cRectX, cRectY, cRectWidth, cRectHeight, cRectDU); }

2016-02-24

flex 动态生成树

flex 动态生成树

2016-02-24

flex 跨域访问文件

flex 跨域访问文件,安全沙相问题,很有用的,放在iis里就行了

2016-02-24

远程屏幕传输(差异截图

远程屏幕传输(差异截图 看看别人在电脑上做什么,很好玩

2010-04-07

EasyGrid,不错的delphi grid

EasyGrid,不错的delphi grid 用了后都知道好用

2010-04-07

delphi自动关机程序,还不错

自动关机程 delphi自动关机程序,还不错

2010-04-07

E都市地图下载,专门下载三维地图,还行吧

E都市地图下载 专门下载三维地图,还行吧

2010-04-07

delphi 7 gif控件

delphi 7 gif控件 unit GIFImage; //////////////////////////////////////////////////////////////////////////////// // // // Project: GIF Graphics Object // // Module: gifimage // // Description: TGraphic implementation of the GIF89a graphics format // // Version: 2.2 // // Release: 5 // // Date: 23-MAY-1999 // // Target: Win32, Delphi 2, 3, 4 & 5, C++ Builder 3 & 4 // // Author(s): anme: Anders Melander, [email protected] // // fila: Filip Larsen // // rps: Reinier Sterkenburg // // Copyright: (c) 1997-99 Anders Melander. // // All rights reserved. // // Formatting: 2 space indent, 8 space tabs, 80 columns. // // // //////////////////////////////////////////////////////////////////////////////// // Changed 2001.07.23 by Finn Tolderlund: // // Changed according to e-mail from "Rolf Frei" // // on 2001.07.23 so that it works in Delphi 6. // // // // Changed 2002.07.07 by Finn Tolderlund: // // Incorporated additional modifications by Alexey Barkovoy ([email protected]) // found in his Delphi 6 GifImage.pas (from 22-Dec-2001). // // Alexey Barkovoy's Delphi 6 gifimage.pas can be downloaded from // // http://clootie.narod.ru/delphi/download_vcl.html // // These changes made showing of animated gif files more stable. The code // // from 2001.07.23 could crash sometimes with an Execption EAccessViolation. // // // // Changed 2002.10.06 by Finn Tolderlund: // // Delphi 7 compatible. // // // // Changed 2003-03-06 by Finn Tolderlund: // // Changes made as a result of postings in borland.public.delphi.graphics // // from 2003-02-28 to 2003-03-05 where white (255,255,255) in a bitmap // // was converted to (254,254,254) in the gif. // // The doCreateOptimizedPaletteFromSingleBitmap function and // // the CreateOptimizedPaletteFromManyBitmaps function is changed so that // // the correct offset 246 is used instead of 245. // // The ReduceColors function is changed according to Anders Melander's post // // so that a colour get converted to the precise colour if that colour is // // present in the palette when using ColorReduction rmQuantize. // // // // Changed 2003-03-09 by Finn Tolderlund: // // Delphi 7 version is now assumed if unknown compiler version is unknown // // for better compatibility with future Delphi versions. // // Hopefully this code is now compatible with future Delphi versions, // // unless Borland makes some changes that breaks existing code. // // // // Changed 2003-08-04 by Finn Tolderlund: // // Changed procedure AddMaskOnly so that it doesn't leak a GDI HBitmap-object // // and it doesn't release the handle of the source bitmap which // // is used to assign to the GIF object as in gif.assign(bm); // // These changes were made as a result of a news post made by Renate Schaaf // // with the subject "TGifImage HBitmap leak on assign?" // // in borland.public.delphi.graphics on Mon 28 Jul 2003 and Sun 03 Aug 2003. // // // // Changed 2004.03.09 by Finn Tolderlund: // // Added a ForceFrame property to the TGIFImage class. // // The ForceFrame property can be used to make TGIFImage display a apecific // // sub frame from an animated gif. // // How to use: Set the Animate property to False and set the ForceFrame // // property to a desired frame number (0-N) // // Normal display: Set the ForceFrame property to -1 and set Animate to True. // // If ForceFrame is negative TGIFImage behaves just as before this change. // // Note that if the sub frame in the gif only contains part of the image // // (i.e. only the changes from previous frames) the result is unpredictable. // // The result is best if each sub frame contains a whole image. // // If the sub frame is transparent the background is not automatically // // restored, you must do so yourself if you want that. // // If you are using a TImage to display the gif you can use // // Image.Parent.Invalidate or Image.Parent.Refresh to restore the background. // // This change was made as a result of a email correspondance with // // Tineke Kosmis (http://www.classe.nl/) which requested such a property. // // // //////////////////////////////////////////////////////////////////////////////// // // // Please read the "Conditions of use" in the release notes. // // // //////////////////////////////////////////////////////////////////////////////// // Known problems: // // * The combination of buffered, tiled and transparent draw will display the // background incorrectly (scaled). // If this is a problem for you, use non-buffered (goDirectDraw) drawing // instead. // // * The combination of non-buffered, transparent and stretched draw is // sometimes distorted with a pattern effect when the image is displayed // smaller than the real size (shrinked). // // * Buffered display flickers when TGIFImage is used by a transparent TImage // component. // This is a problem with TImage caused by the fact that TImage was designed // with static images in mind. Not much I can do about it. // //////////////////////////////////////////////////////////////////////////////// // To do (in rough order of priority): // { TODO -oanme -cFeature : TImage hook for destroy notification. } // { TODO -oanme -cFeature : TBitmap pool to limit resource consumption on Win95/98. } // { TODO -oanme -cImprovement : Make BitsPerPixel property writable. } // { TODO -oanme -cFeature : Visual GIF component. } // { TODO -oanme -cImprovement : Easier method to determine DrawPainter status. } // { TODO -oanme -cFeature : Import to 256+ color GIF. } // { TODO -oanme -cFeature : Make some of TGIFImage's properties persistent (DrawOptions etc). } // { TODO -oanme -cFeature : Add TGIFImage.Persistent property. Should save published properties in application extension when this options is set. } // { TODO -oanme -cBugFix : Solution for background buffering in scrollbox. }

2010-04-07

C#_接口多继承.txt

C#接口的例子 interface IPrint { void Print(); 接口多继承.txt

2009-11-01

DataGridview绑定

using (SqlConnection connection = new SqlConnection(@"server=.;database=gr;user id=sa;pwd=")) { //SqlDataAdapter sda = new SqlDataAdapter("select * from customers", connection); //DataSet ds = new DataSet(); //sda.Fill(ds); BindingSource bindingSource1 = new BindingSource(); connection.Open(); SqlCommand cmd = new SqlCommand("select * from T1", connection); SqlDataReader sdr = cmd.ExecuteReader(CommandBehavior.Default); if (sdr.Read()) { bindingSource1.DataSource = sdr; GridView1.DataSource = sdr; GridView1.DataSource = bindingSource1; } }

2009-11-01

txt文件写入读取.txt

private void inputdata_Click(object sender, EventArgs e) { string path1 = @"d:test1.txt"; string path2 = @"d:test2.txt"; //创建文件 if (!File.Exists(path1)) { StreamWriter sw = File.CreateText(path1); sw.WriteLine("write some text."); sw.Close(); } //打开文件 StreamReader sr = File.OpenText (path1); string s = ""; while ((s = sr.ReadLine()) != null) { textBox1.Text = s; } sr.Close();

2009-10-27

C# format 用法.txt

C# format 用法.txt,还不错

2009-10-27

C# 操作XML.txt

C# 操作XML.txt 还不错 多个关键字请用空格分隔,最多填写5个。点击右侧Tag快速添加

2009-10-16

c# socket 多线程

并发多线程 //entry point of main method.... public static void Main() { //TcpListener is listening on the given port... { TcpListener tcpListener = new TcpListener(1234); tcpListener.Start(); Console.WriteLine("Server Started") ; //Accepts a new connection... Socket socketForClient = tcpListener.AcceptSocket(); //StreamWriter and StreamReader Classes for reading and writing the data to and fro. //The server reads the meassage sent by the Client ,converts it to upper case and sends it back to the client. //Lastly close all the streams. try { if (socketForClient.Connected) { while(true) { Console.WriteLine("Client connected"); NetworkStream networkStream = new NetworkStream(socketForClient); StreamWriter streamWriter = new StreamWriter(networkStream);

2009-10-15

asp.net 完全入門

asp.net 完全入門,入门的教程,高手绕到

2008-04-14

ASP.NET 微软培训

ASP.NET 微软培训,呵呵觉得还不错,上传上来给大家,做人要厚道呀

2008-04-14

C# 教程

发布一个C# 教程 适合初学者,高手莫下

2008-04-14

arcigs +vb开发实例

一个很简单的arcigs +vb开发实例<br>高手模下

2008-04-14

文本编辑器

文本编辑器<br>一个在C#里的文本编辑器,好用呵呵

2008-04-14

Engine中鹰眼的实现

Engine中鹰眼的实现

2008-04-13

ArcGIS World第一期

ArcGIS World第一期

2008-04-13

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除