编程技巧 - 文章列表

  • oracle 新建用户并授权的方法

    运行-》cmdcdC:\ProgramData\Microsoft\Windows\StartMenu\Programs\Oracle-OraDB12Home1\应用程序开发sqlplus/assysdba连接到:OracleDatabase12cEnterpriseEditionRelease12.2.0.1.0-64bitProductionSQLcreateuserusernameident

  • 分部声明一定不能指定不同的基类

    wpf使用usercontrol继承父类的时候,报了这个错,解决方法修改子类的xaml文件如下如UI_Select继承于UI_Config另外,父类不能有xaml文件,否则会报“XXXXX.XXX”不能是XAML文件的根,因为它是使用XAML定义的

  • servlet中文乱码显示为??的解决方法

    方法一:设置response的header为utf-8编码protectedvoiddoGet(HttpServletRequestrequest,HttpServletResponseresponse)throwsServletException,IOException{response.setHeader(content-type,text/html;charset=UTF-8);PrintW

  • tomcat配置使用不同端口访问不同网站

    比如127.0.0.1:8880访问站点一,127.0.0.1:8881访问站点二配置方法为复制一份service节点,然后修改端口号如下图所示

  • android 右下角弹出1/4圆盘菜单的效果

    android右下角弹出1/4圆盘菜单的效果具体效果如下所示1、默认状态下右下角显示一个加号2、点击后展开两层菜单,同时旋转加号,变成关闭符号demo下载地址http://download.csdn.net/download/xwt0511/10148781

  • android通过intent浏览图片的方法

    Intentintent=newIntent(Intent.ACTION_VIEW);Uriuri=Uri.parse(MediaStore.Images.Media.insertImage(getContentResolver(),bmp,null,null));//将bitmap转换为uriintent.setDataAndType(uri,image/*);startActivity(int

  • android选择文件,通过uri获取文件真实地址的方法(兼容7.0)

    1、发起选择文件的请求Intentintent=newIntent(Intent.ACTION_GET_CONTENT);intent.setType(*/*);intent.addCategory(Intent.CATEGORY_OPENABLE);((Activity)context).startActivityForResult(Intent.createChooser(intent,请选择

  • Android 7.0的手机在eclipse上无法显示logcat的解决方法

    Android7.0的手机在eclipse上无法显示调试信息logcat的解决方法需要下载ADT-24.2.0下载地址:https://github.com/khaledev/ADT/releases或http://pan.baidu.com/s/1gfFX5HxADT使用方法下载文件后在Eclipse中点击目录HelpInstallNewSoftware...AddArchive...然后选择下

  • swift 播放网络音频

    var audioPlayer:AVAudioPlayer!func playsong(musicdata:NSData){    do{        try audioPlayer = AVAudioPlayer(data: musicdata)        audioPlayer.prepareToPlay()        audioPlayer.play()    }catch {&n

  • c# post大文件报错OutOfMemoryException 内存溢出

    c#post大文件时(大于500M),会报OutOfMemoryException的错误,后来设置request.ContentLength后,文件上传上去了,但是在关闭流的时候,报错“请求被中止: 请求已被取消”,原因应该是写入的大小跟设置的大小不一样,解决的方法是写入与请求的大小相同的字节数完整的代码如下://post上传文件public static byte[] PostFile(string url, IEnumerable<UploadFile> files, NameValueCollection values)  &