2009年3月30日星期一

vs2008 无法打开项目文件

vs2008 无法打开项目文件 .vsproj .vdproj
此安装不支持该项目类型C:\Documents and Settings\Administrator\Local Settings\Temp

因为莫名其妙的错误,刚刚重新ghost了系统,然后重装了vs2008,之后打开我原来的项目报上面的错误,狂晕,项目文件我也没动过啊,搜索微软帮助,建议重装vs2008,重装vs2008后可以了

==
今天想学学WPF,靠,打开我原来建的一个WPF项目还报上面的错误,突然想到我以前装过vs2008 sp1

大大提醒了我

装上sp1后 OK

转载:

安装中文VS2008 SP1 和.NETFRAMEWORK 3.5SP1后智能提示是英文的解决办法
期待已久的VS2008 SP1 和.NET FRAMEWORK 3.5 SP1都出来了

下载地址

Microsoft Visual Studio 2008 Service Pack 1 (iso)

http://www.microsoft.com/downloads/details.aspx?displaylang=zh-cn&FamilyID=27673c47-b3b5-4c67-bd99-84e525b5ce61

Visual Studio 2008 Team Foundation Server Service Pack 1(iso)

http://www.microsoft.com/downloads/details.aspx?displaylang=zh-cn&FamilyID=9e40a5b6-da41-43a2-a06d-3cee196bfe3d

Microsoft .NET Framework 3.5 Service Pack 1

http://www.microsoft.com/downloads/details.aspx?displaylang=zh-cn&FamilyID=ab99342f-5d1a-413d-8319-81da479ab0d7

      第一时间安装完后,智能提示却是英文的,呵呵这对于我这个英文不好的人来说,有点郁闷,重新装了好几次.NETFROAMWORK 3.5 SP1语言包都解决不了问题,后来就用备份的资源文件替换掉ZH-CN目录。问题解决掉了呵呵,下载地址

点击下载(2.0)

完了解压后,替换掉

C:\Windows\Microsoft.NET\Framework\v2.0.50727\zh-CN 目录,

点击下载(3.0)

完了解压后,替换掉

C:\Program Files\Reference Assemblies\Microsoft\Framework\v3.0\zh-CN目录

点击下载(3.5)

完了解压后,替换掉

C:\Program Files\Reference Assemblies\Microsoft\Framework\v3.5\zh-CN目录

2009年3月26日星期四

myeclipse7插件安装

import java.io.File;
import java.util.ArrayList;
import java.util.List;

public class Test {
private String path;

public Test(String path) {
   this.path = path;
}

public void print() {
   List list = getFileList(path);
   if (list == null) {
    return;
   }

   int length = list.size();
   for (int i = 0; i < length; i++) {
    String result = "";
    String thePath = getFormatPath(getString(list.get(i)));
    File file = new File(thePath);
    if (file.isDirectory()) {
     String fileName = file.getName();
     if (fileName.indexOf("_") < 0) {
      continue;
     }
     String[] filenames = fileName.split("_");
     String filename1 = filenames[0];
     String filename2 = filenames[1];
     result = filename1 + "," + filename2 + ",file:/" + path + "\\"
       + fileName + "";
     System.out.println(result);
    } else if (file.isFile()) {
     String fileName = file.getName();
     if (fileName.indexOf("_") < 0) {
      continue;
     }
     int last = fileName.lastIndexOf("_");// 最后一个下划线的位置
     String filename1 = fileName.substring(0, last);
     String filename2 = fileName.substring(last + 1, fileName
       .length() - 4);
     result = filename1 + "," + filename2 + ",file:/" + path + "\\"
       + fileName + ",4,false";
     System.out.println(result);
    }
   }
}

public List getFileList(String path) {
   path = getFormatPath(path);
   path = path + "/";
   File filePath = new File(path);
   if (!filePath.isDirectory()) {
    return null;
   }
   String[] filelist = filePath.list();
   List filelistFilter = new ArrayList();

   for (int i = 0; i < filelist.length; i++) {
    String tempfilename = getFormatPath(path + filelist[i]);
    filelistFilter.add(tempfilename);
   }
   return filelistFilter;
}

public String getString(Object object) {
   if (object == null) {
    return "";
   }
   return String.valueOf(object);
}

public String getFormatPath(String path) {
   path = path.replaceAll("\\\\", "/");
   path = path.replaceAll("//", "/");
   return path;
}

public static void main(String[] args) {
   new Test(
     "D:\\Program Files\\Genuitec\\Common\\Dropins\\JSEclipse\\eclipse\\plugins")
     .print();//插件路径
}
}
执行完之后,将控制台中打印出的执行结果,直接复制到下面这个文件中: C:\Genuitec\MyEclipse 7.0\configuration\org.eclipse.equinox.simpleconfigurator\bundles.info

E:\Program Files\Genuitec\Common\plugins\vss\eclipse\plugins\org.vssplugin_1.6.1

2009年3月19日星期四

hibernate异常

备案:
java.lang.IllegalStateException: No data type for node: org.hibernate.hql.ast.tree.IdentNode


hibernate查询时报上面的异常,仔细检查hql写的有不对的地方,我就是把逗号,写成点.