Want the transfer of data from the database into the drop-down list , below is the code. But always fail to get value . Great God seeking to explain ~ ~
------ Solution ------------------------------------- ------- alas, the boss then you end affixed to the I dotted it ------ For reference only --------------- ------------------------ found the problem. . . was written
public Integer getValueStandardId() { return this.valueStandardId; }
public void setValueStandardId(Integer valueStandardId) { this.valueStandardId = valueStandardId; }
public Integer getParentId() { return this.parentId; }
public void setParentId(Integer parentId) { this.parentId = parentId; }
public String getName() { return this.name; }
public void setName(String name) { this.name = name; }
public String getNote() { return this.note; }
public void setNote(String note) { this.note = note; }
public String getSequence() { return this.sequence; }
public void setSequence(String sequence) { this.sequence = sequence; }
}
------ Solution ------------------------------------- ------- java tree menu on the left to do http://blog.sina.com.cn/s/blog_6c7f922d0100q9xo.html ------ Solution ---------------------------------------- ---- do it in the page , with the z-tree, well used ------ Solution ------------------- ------------------------- tree menu can be done is ugly ------ Solution ----- --------------------------------------- a look at how to achieve a recursive algorithm , imitate what you can . This simple recursive menu easier to achieve ------ Solution ------------------------------- ------------- entity class encapsulates error ------ Solution -------------------- ------------------------ feel easyUI foreground framework written in this more convenient ------ Solution ---- ---------------------------------------- http://blog.csdn .net/yeness/article/details/9496647 ------ Solution ------------------------------ -------------- after setting up the data sets in the foreground show , this is a graphic design in general , and their own words to the Internet to look for your favorite style , but also a lot of ------ Solution ---------------------------------------- ----
I 've written a tree , and now mainly to the transfer of this tree , as an attribute of another one table.
Oh misunderstood you mean, you want to call is now showing a tree in another page? If so you can use ajax call to this method alone extracted directly return a json string or data can be of ------ Solution --------------- ----------------------------- http://www.ztree.me/v3/demo.php ------ For reference only ---------- ----------------------------- their top . ------ For reference only -------------------------------------- -
Well using easyUI reception ------ For reference only ---------------------- -----------------
I 've written a tree , and now mainly to the transfer of this tree , as an attribute of another one table. ------ For reference only -------------------------------------- -
I 've written a tree , and now mainly to the transfer of this tree , as an attribute of another one table. Write how to modify the above action ------ For reference only --------------------------- ------------
I 've written a tree , and now mainly to the transfer of this tree , as an attribute of another one table.
Oh misunderstood you mean, you want to call is now showing a tree in another page? If so you can use ajax call to this method alone extracted directly return a json string or the data can be Well I use ajax, but backstage action retrieval tree method is not so, the above is the transfer of a tree way I write, but can not be adjusted to take, you help me look at the code , where there are problems. ------ For reference only -------------------------------------- - been resolved , thank you.
I'm furious ! java beginner, engage in the afternoon today , there are two problems: . 1 compile time , a direct hit in the dos window javac Test.java prompt " File not found" , so I added a path in front : "c: \ Users \ 1 \ desktop \ Test.java " just fine , gave birth to the class file , though passed, but still have a problem , why others can not trails? After 2. generate class files , enter "java Test" Enter a " Can not find or load main class " in the dos window, I found a lot of solutions will not work.
environment variables:
Classpath:;.% Java_Home% \ lib
Java_Home: D: \ Program Files \ Java \ jdk1.7.0_11
Path:% Java_Home% \ bin
code is as follows :
public class Test
{
public static void main (String [] args)
{
System.out.println ("Hello World!");
}
} these two problems are not related ah ? ------ Solution ---------------------------------------- ---- your working directory in the desktop cmd in what ------ For reference only ---------------------- ----------------- great God please help me , Online! ------ For reference only -------------------------------------- - java installed on it? Open dos: java-version
take a look at what the output ------ For reference only ----------------------------- ---------- certainly fitted the way, is the 1.6 version , I just found a problem that only in the root directory of each disk in order to compile and run successfully. For example, I built on the D drive a Test.java, dos window and then type D: Enter, then type javac Test.java ( no need to enter the path ) , compiled successfully , enter java Test return, run success. How is this going ? ------ For reference only -------------------------------------- - Yes, ah , no, , dos default is c: \ users \ 1 below ------ For reference only --------------- ------------------------
your files in c: \ users \ 1 \ desktop you are in c: \ users \ 1 how might find it?
When you hit java Test he will not help you scan your hard disk to find Test.class ah ------ For reference only ---------------- -----------------------
You look at my reply to the third floor , is not only to build java files in the root directory ah ------ For reference only ---------------- -----------------------
not
Because you do when your working directory is D: \ where your files are
If you want to place the file in c: \ users \ 1 \ desktop, when you first thing to do is punch cmd cd desktop
then javac Test.java java Test ------ For reference only ------------------------------- -------- that if I usually put the program files on the E drive a folder under the n how do ------ For reference only ------ ---------------------------------
For example, the file in your E: \ toto \ titi \ Test.java
either after you hit cmd e: cd toto \ titi javac Test.java java Test After you hit cmd either
javac E: \ toto \ titi \ Test.java java E: \ toto \ titi \ Test ------ For reference only ------------------------ ---------------
The reply was deleted administrator at 2013-01-18 08:58:02
------ For reference only ---------------------------------- ----- Thank you very much ! ------ For reference only -------------------------------------- - this run java program also appeared "Unable to load the main class " error , close the DOS window , then enter the program directory , run no such mistake , very strange , oh ! ------ For reference only -------------------------------------- - I know why Right-click the project properties-java Builder Path-Libraries see your jdk right
first to welcome everyone to vote for me : (2013CSDN blog Star Award ) http://vote.blog.csdn.net/blogstaritem/blogstar2013/zhangerqing some knowledge of my own summary Java -based aspects , as a Java programmer , we need to put them all to learn through, this is just a part of every so often there will be a new blog post came out, welcome everyone to read !
12 years have been found not post knot ah. . . . . . ------ For reference only -------------------------------------- - give you voted , post knot soon ! ------ For reference only -------------------------------------- - thanks Ha ! ------ For reference only -------------------------------------- - Thank you ! ------ For reference only ---------------------------------------
------ For reference only ------ --------------------------------- Shen gone then ! ------ For reference only -------------------------------------- - to a statement posted on the 20th floor , grasp ah ! ------ For reference only -------------------------------------- -
---- - For reference only ---------------------------------------
12 years have been found not post knot ah. . . . . . Oh , just forget it, already have got . Welcome to vote for me , immediately got this post . http://vote.blog.csdn.net/blogstaritem/blogstar2013/zhangerqing ------ For reference only -------------------------------------- - refueling
As the title of my website www.findmaven.net and www.find.com the biggest difference can be found in the fuzzy according to class or jar jar maven repository name in the link (GAV group: artifact: version). you have any good ideas do better or improve opinion? Give me some suggestions to make this site better and stronger .
------ Solution ------------------------------------ -------- good landlord refueling ------ For reference only ----------------------- ---------------- page elements feel a little
There are two tables A B Table A fields: id name bid ( foreign key ) Table B fields: id name
entity class
@Eneity public class A {
@Id @GeneratedValue private int id; private Sreing name;
@OneToOne //这里该怎么写 private int bid;
//setter getter...... }
@Eneity public class B {
@Id @GeneratedValue //这里要写什么? private int id; private Sreing name;
//setter getter...... }
hql how to write in order to make final
select * from A
Return to the list so there B 's name ------ Solution -------------------- ------------------------ entity class a landlord 's wrong
@ Eneity public class A {
@ Id @ GeneratedValue private int id; private Sreing name;
@ OneToOne / / Here how to write private B b;
/ / setter getter ...... } . so check out the A, B 's name had a list.get (i) getB () getName ();. ------ Solution ----- --------------------------------------- hibernate recommend using bidirectional many- to achieve one ------ Solution ------------------------------------ --------
@Entity public class A { //最好还是把这些注解写在getter上 @Id @GeneratedValue private int id; private String name; private int bid; @OneToOne @JoinColumn(name="bid",insertable=false,updatable=false) private B b;
//setter getter...... }
@Eneity public class B { //最好还是把这些注解写在getter上 @Id @GeneratedValue private int id; private String name; @OneToOne(mappedBy="b")//双向一对一关联以A类的b属性配置来进行关联 private A a; //setter getter...... }
------ Solution -------------------------- ------------------ not hibernate annotations can look at this document http://docs.jboss.org/hibernate/annotations/3.4/reference/ zh_cn / html_single / ------ For reference only ---------------------------------- -----
is to B as it is an attribute of A That comment how to write ? ------ For reference only ------------------------------------ ---
give a simple example you ------ For reference only --------------------------- ------------ you search on the Internet , many are ------ For reference only --------------- ------------------------
I could not find a satisfactory asked to come to this . . . ------ For reference only ---------------------------------------
Well I write mainly on getter on the property too lazy to play on my first try and see. . ------ For reference only -------------------------------------- -
This post last edited by the Anders_Zhuo on 2013-11-04 23:36:59
I do back in the game development companies, some data will be temporary to memcache
But when it came to developing such a question:
lot of background development in their own writing extension classes which use memcahce, will declare their own key.
Thus, for me to write my extended class, to use memcache, declared key , I was a bit tangled
I do not know which key has been used , I can not go to other people , I read through the code and see what key has been used. This is too cumbersome
Ever since, I do not know how to do ?
sum up the problem :
1 memcache the key how to manage it, is to put all the key are written in a separate statement inside a class , or write in a configuration file, so if you use a key which others can know . . Or are there better ways ? ? ? ?
For example, class A which has the code : memcache.set ("key1", value); memcache.set ("key2", value2); < br /> then class B which also has some of this code , memcache.set ("key3", value); memcache.set ("key4", value2);
also there are class C, class D , and so too much
so I set method when I do not know which key has been used by others .
2 memcache now there are a lot of data , and also can not be deleted , I want to know what key, how do you know ? ? I checked on the Internet , there is a way a lot of trouble : telnet connection memcache, stats items, then stats item index 0 this will put all the key listed, but it feels a lot of trouble , there is no other way to know what has been using key????
first, your avatar protest. key statement for each project should have its own rules , your own set like. The easiest way : project name , delimiter , the module name , delimiter, function name , delimiter , key you use. Small projects unlikely to repeat . ------ For reference only -------------------------------------- -
Under this you ask my colleagues should give you answer it ------ For reference only ------------------- -------------------- does this thing do not need to go global constraints , or interact with a few per cent more cache , each upper application to make a conventions like ------ For reference only ---------------------------------- ----- this comparison approach is to do kung fu provincial convention slightly, to achieve perfect configuration is quite troublesome cough is not considered half-baked ------ For reference only --------------------------------------- All are written in the same key the next class like, ah , you need to go to class adds new content under Key , of course, everyone put their use in a range of key inside, so it will not conflict . ------ For reference only -------------------------------------- -
first, your avatar protest. key statement for each project should have its own rules , your own set like. The easiest way : project name , delimiter , the module name , delimiter, function name , delimiter , key you use. Small projects unlikely to repeat .
this picture , I spent a whole year now ! Protest is invalid !
Recently read a book "Java TCP / IP Socket" The book explains some of the content on the Socket , which saw the content on obstruction after a little would not understand, you can not help me look at the code , why is there blocking ah ?
example , there are two cases, case 1 : will not clog ; case 2 : will be blocked ;
code is as follows :
//客户端 public class CompressClient { public static final int BUFSIZE = 256;
public static void main(String[] args) throws IOException { InetAddress inetAddr = InetAddress.getLocalHost(); int port = 8888; String fileName = "D:\\杂乱\\桌面.jpg";
FileOutputStream fileOut = new FileOutputStream(fileName + ".gz"); final FileInputStream fileIn = new FileInputStream(new File(fileName));
@Override public void run() { handleCompressClient(clntSock, logger); } }
Two commented the situation , but the use of a code , it will not be blocked . This is what principle ah ? We can explain the explanation? ------ Solution ---------------------------------------- ----
private static void sendBytes (Socket socket, InputStream fileIn) throws IOException { OutputStream sockOut = socket.getOutputStream (); int bytesRead = 0; byte [] buffer = new byte [BUFSIZE]; while ((bytesRead = fileIn.read (buffer))! = -1) / / Here will be blocked because if there is no bytes are read , then blocked { sockOut.write (buffer, 0, bytesRead); System.out.print ("W"); } System.out.println ("\ nClient send data complete!"); socket.shutdownOutput (); System.out.println ("Client is deadlock No?"); } The code in question , ------ Solution ------------------------------ --------------
------ For reference only ----------------------------------- ---- answer is no well-wishers it? Online ...... ------ For reference only ---------------------------- ----------- right, I ask you to send queue and (RecvQ) receive queue size is how much ah TCP socket (SendQ) in ? ------ For reference only --------------------------------------- read the socket read ! (buffer) = -1 only in one case established that in each call socket.shutdownOutput (); methods. -1 otherwise never have occurred , so you never end here , unless two conditions: 1 each call socket.shutdownOutput () ;/ / You will receive a -1 , but if the other program is not what you write , can not guarantee oh. 2 each call socket.close (); / / there is an exception, the end , but when you have to re- write data anomalies appear -----!! - For reference only ---------------------------------------
Thank you, my own problems to solve , first you will good, but one thing you analyze wrong, when calling sockOut.write (buffer, 0, bytesRead), I found that the program is here was only blocked , indicating that - " receiving end SendQ queue has been filled , so will cause obstruction when the server calls sockOut.write (buffer, 0, bytesRead)", this problems with "Socket receive queue SendQ" about !
However, there still want to thank you , while ((bytesRead = in.read (buffer))! = -1) is used in this way depends on what the scene , You can also use the " custom message boundary character " to achieve .
Thank you ! ------ For reference only -------------------------------------- -
"! socket in the read (buffer) = -1 only established in one case ," you say this view is wrong , the correct view is : Only two views establishment , 1.socket.shutdownOutput () 2.socket.close (), I suggest you try it yourself ! ------ For reference only -------------------------------------- - I'm here to write the code , just learning to use , does not suggest that you direct use projects, is just learning to use Oh ! correct code is as follows :
/* * 服务端 */ public class TestServer { public static void main(String[] args) throws IOException { System.out.println("服务端启动......"); ServerSocket server = new ServerSocket(8888);
byte[] temp = new byte[10]; int realLen = 0; while ((realLen = input.read(temp)) != -1) { System.out.println("【服务端】正在发送数据......"); output.write(temp, 0, realLen); } System.out.println("【客户端】发送数据完毕!"); output.flush();
client.close(); } }
/* * 客户端 */ public class TestClient { public static void main(String[] args) throws UnknownHostException, IOException { System.out.println("客户端启动......"); final Socket client = new Socket(InetAddress.getLocalHost(), 8888);
final OutputStream out = client.getOutputStream(); InputStream in = client.getInputStream(); final FileInputStream fileIn = new FileInputStream(new File( "D:\\杂乱\\桌面.jpg"));
// 使用一个子线程发送数据 Thread handlerExecute = new Thread() { @Override public void run() { try { byte[] fileTemp = new byte[1024]; int realFileLen = 0;
Regular expression (?! \ \ D) What is the meaning ------ Solution -------------------------- ------------------ this is called negative lookahead , represents the right location can not figure ------ For reference only --- ------------------------------------ etc. downstairs to answer .... ------ For reference only ---------------------------------------
Do not be so wet bar . . ------ For reference only -------------------------------------- -
probably know, test it, just do the right limit , which it does not match the results ------ For reference only ---------- ----------------------------- this is a non-capturing group , not numbers match back position. ------ For reference only -------------------------------------- - \ d matches a digit character. Equivalent to [ 0-9 ] . (?! \ \ d) positive negative pre-investigation, the figures do not match any string of characters at the beginning of the search string match . This is a non-matching , that is, the match does not need access to for future use . For example, "Windows (95 |?! 98 | NT | 2000)" matches "Windows3.1" in the "Windows", but can not match "Windows2000" in "Windows". ------ For reference only -------------------------------------- - upstairs positive solution. . .
------ Solution ------------------------------------- ------- because the ternary operator : ? precedence than the binary + operator is low, add operations to run , so in fact the above formula is equal to: str = (("92 =" + strs [i]) == null) "":? strs [i] + "|"; first computing the sum + , and then determine whether the string is equal to the sum of the null.
See seems to be class ------ Solution ---------------------------------- ---------- point that attach source, find your jdk installation src.zip directory, confirmed on the line ------ For reference only ---- ----------------------------------- ah , I have done .
Console error saying can not load jdbc driver ------ Solution -------------------------------- ------------ put your jdbc driver Kaodao tomcat lib folder ------ For reference only ----------- ---------------------------- OK .
Ask everyone calls between the two systems , it is the choice rpc or mq, talk about it and select your system
such rpc can be a simple spring httpinvoker, but the premise is all java applications and are used spring framework, can choose restful web service or a heavyweight soap web service, or use rmi, or write java api socket program ; mature soa or using third-party products, such as alibaba 's dubbo
or use mq system
But for calls between two applications , the above methods can be used, the choice of how we are , where several aspects to the choice of it ?
------ Solution ------------------------------------ -------- project used ActiveMQ, can be downloaded ActiveMQ agency services as message forwarding station , to achieve data transmission between the two applications , and ActiveMQ failover support for 32 and 64- bit operating systems are supported, in my experience is concerned , activeMQ is a good choice, you can download the first study, http://download.csdn.net/detail/baohuan_love/6683581 - ----- Solution --------------------------------------------
you that this is not analyzed very Okay , basically that's all ------ For reference only ---------------- ----------------------- there are more comments? I personally feel that if it is needed to return the data in real time , then mq field it may be irrelevant , mq advantages of asynchronous and decoupled , access needs to be sent immediately after the sending end of the scene estimated return information or rpc more suitable , we mean it
When installed appache tomcat server, view port occupies 360 procedures , there , the problem of learning tomcat does not matter , but I very much want to learn how to program or get rid of the 80 -port , let him take up another port , so that the 80 -port - ----- Solution -------------------------------------------- you first enter cmd console and enter the netstat-ano view to find occupied port 80 in the last column of the process id Figure: then to the Task Manager to find the corresponding process will get rid of it . Of course, if you start to get rid of it , then there is a possibility , windows will occupy port 80 is iis service (asp.net web server will use this to do it , of course, can also be another ) , so you can iis service stopped on it. In the process of doing web tomcat configuration is often used as a 80 -port , after all, so the user input ip Visit our website will not need to enter port it ------ Solution -------- ------------------------------------ quote = reference to the 7th floor huchunlinnk ; 's reply : ]
You say this , I have used it , id you occupied port 80 process is 4060 , not a system process , is able to kill . But my process id is 4, the system is unable to kill the process . . .
So I said, you should go to the iis services to shut up, because this is the only service windows in the occupied port 80, you're running in cmd in xp services.msc then find close iis services , win7 then control Panel \ All control panel Items \ programs and Features - " turn on or off windows features - > internet information services will remove the checkbox
iis my side after win7 will open port 80 will be the process ID of the program to take up to four . But these two removed on ok
------ For reference only ---------------------------------- ----- seemingly more difficult now , Microsoft is now looking ------ For reference only --------------------------------------- hope you mean the web publish projects to the 80 port? Yes, directly to the tomcat following config folder below server.xml modify the following code connectionTimeout = "20000" redirectPort = "8443" URIEncoding = "GBK" /> ; in 8080 to 80 ports can be ------ For reference only ------------------------ ---------------
The reply was deleted at the moderator 2013-12-12 09:17:40
------ For reference only ---------------------------------- -----
not the problem, which is not adjusted occupied tomcat server port , but the port is occupied by 80 program to get rid of , because if there is , then the program occupies port 80 , tomcat server is started up , so the program should occupy 80 port changed, let him use another port , in this case , port 80 on the idle out, so the tomcat server port 80 can be changed to the normal start up ----- - For reference only ---------------------------------------
you say this , I have used it , id you occupied port 80 process is 4060 , not a system process , is able to kill . But my process id is 4, the system is unable to kill the process . . . ------ For reference only -------------------------------------- -
you say this , I have used it , id you occupied port 80 process is 4060 , not a system process , is able to kill . But my process id is 4, the system is unable to kill the process . . .
So I said, you should go to the iis services to shut up, because this is the only service windows in the occupied port 80, you're running in cmd in xp services.msc then find close iis services , win7 then control Panel \ All control panel Items \ programs and Features - " turn on or off windows features - > internet information services will remove the checkbox ------ For reference only ----- ---------------------------------- recommend you a software tcpview deal specifically with this situation you ------ For reference only -------------------------- -------------
you say this , I have used it , id you occupied port 80 process is 4060 , not a system process , is able to kill the . But my process id is 4, the system is unable to kill the process . . .
So I said, you should go to the iis services to shut up, because this is the only service windows in the occupied port 80, you're running in cmd in xp services.msc then find close iis services , win7 then control Panel \ All control panel Items \ programs and Features - " turn on or off windows features - > internet information services will remove the checkbox I shut the IIS . . . Or no matter what . . . ------ For reference only -------------------------------------- - I encountered this problem , System occupied port 80, is a server 2008 system, the internet can find , what I remember is to change the registry ------ For reference only --- ------------------------------------
you said this I also use over it , id you occupied port 80 process is 4060 , not a system process , is able to kill . But my process id is 4, the system is unable to kill the process . . .
So I said, you should go to the iis services to shut up, because this is the only service windows in the occupied port 80, you're running in cmd in xp services.msc then find close iis services , win7 then control Panel \ All control panel Items \ programs and Features - " turn on or off windows features - > internet information services will remove the checkbox I shut the IIS . . . Or no matter what . . .
off after restart the computer to remember enough ------ For reference only ------------------------ ---------------
I think the landlord said he shut iis described iis port 80 must have been occupied by the landlord should not have to restart the computer but nothing in the windows where the default port 80 is assigned to the web service on this is not necessary unless you modify the registry iis port that is anything else
------ For reference only ---------------------------------- -----
I think the landlord said he shut iis described iis port 80 must have been occupied by the landlord should not have to restart the computer but nothing in the windows where the default port 80 is assigned to the web service on this is not necessary unless you modify the registry iis port that is anything else
iis not a problem , the process takes a 'System', not iis, iis uninstall this case is useless . ------ For reference only -------------------------------------- -
you say this , I have used it , id you occupied port 80 process is 4060 , not a system process , is able to kill . But my process id is 4, the system is unable to kill the process . . .
So I said, you should go to the iis services to shut up, because this is the only service windows in the occupied port 80, you're running in cmd in xp services.msc then find close iis services , win7 then control Panel \ All control panel Items \ programs and Features - " turn on or off windows features - > internet information services will remove the checkbox I shut the IIS . . . Or no matter what . . .
off after restart the computer enough to remember has been resolved. . . Thank you restart the computer off after ......
Why is my own definition of JButton class does not correctly display ? I think we should rewrite JButton some way? The results are:
------ Solution ------- ------------------------------------- lz beginner swing it, go see their landlord achieve JButton, feel landlord has the idea to create the code for lz in : 1.lz own custom JButton is already added to the JFrame , but did not display button content. 2.lz To display the contents MyButton , you need to add a constructor in the MyButton class :
public MyButton(String text) { super(text); }
because you MyButton class contains a JButton, the JButton and you add in the JFrame MyButton not directly related , so that you created in the Test MyButton method is not displayed content. ------ Solution ---------------------------------------- ---- MyButton inherited JButton, new MyButton () to create the button name is not displayed , so the display is right on the screen. You can try this.add (my_bt.bt); ------ Solution ------------------- ------------------------- you write something called "Creating did not add ." ------------------ your MyButton inherited JButton, meaning MyButton itself is jbutton, your constructor super () this one is the MyButton set as the default JButton (). At this point, you have a constructor which bt = JButton ("Save"); You probably online, do not show me this how ah ? Yes, your bt actually exist, but your JFrame 's add () to add the MyButton, rather than bt = JButton ("Save"); That bt. ------------------- you here actually creates three Button, but there are two added into the JFrame ...
not believe it, you can try to add Test in this sentence: JButton bu = my_bt.bt; this.add (); try ...... [I just look at your code, have not tried , there is a problem ask it ... ] ------ For reference only --------------------------------------- Thank stride _ YUAN Shen Jian , Yimenchuixue, weidu23 three answers , I just started to learn Swing, yesterday to write a panel in the project , there have this problem. Thank you for your answer ! ! !
If my main method to call three methods in turn , f1 (), f2 (), f3 (). Three methods may throw an exception. how to design exception handling can be achieved : 1. regardless of whether an exception is thrown three methods , can be executed in sequence f1, f2, f3. 2. If there is an exception in the main final play of all exception information .
is not to say, if the exception is caught and handled , the program is not terminated , will continue down the order of execution ? yes. unless they use the throw statement in the catch block , the exception will be caught and then thrown out , otherwise dispose of captured , it will not terminate the program at the exception occurred . ------ For reference only -------------------------------------- - give ideas, there are pre- flash people :
is not to say, if the exception is caught and handled , the program is not terminated , will continue down the order of execution ? ------ For reference only -------------------------------------- - floor China good IT, China good code ------ For reference only --------------------------------------- 2 Building on the good way . ------ For reference only -------------------------------------- - when the exception is caught , the following code can proceed . Therefore, the second floor of the code is completely OK. Floor thinking too complicated.
The main exception is not done these small tests.
too lazy to write the code , on the second floor directly copy! ------ For reference only ---------------------------------------
I noticed oh_Maxy mao brother, you are in the main inside out here , if not main inside, but a private void exe () inside, so it is easy to write the problem , right? I think add a finally {} is better ... ------ For reference only ------------------ ---------------------
I noticed oh_Maxy mao brother, you are in the main inside out here , if not main inside, but a private void exe () inside, so it is easy to write the problem , right? I think add a finally {} is better ... not add finally, because each catch block has captured the exception , the equivalent internal digested . finally dispensable .
RT document upload done stored in the database is to upload the document path project needs now is to click on the document name to open the document in a jsp page, kind of like Baidu library preview document format currently has three kinds of PPT WORD PDF Internet to find a Many use poi to resolve the but currently only done parsing text and parsed out , open it slowly, so certainly not table format and pictures are resolved not out very tangled There are dozens with flexpaper to convert swf file is displayed in the preview but still could not get some of the software is not free or open source, not just with the commercial version of the software increasingly tangled
Who do the Demo ah Online ah heroes ------ Solution ---------------------------------- ---------- not so simple , it is best to have a background batch upload PDF documents are unified into a format or directly open the front desk to preview the PDF.
conversion process suggested tools , not limited to the Java implementation ; their use be resolved like POI achieve efficiency is too low. ------ Solution ---------------------------------------- ---- have to use third-party plug-ins , otherwise no way do we use third-party companies are plug-ins, such as excel displayed in IE. guess you do not have an example in the search, I have found over and over the give you an excel example , can only be used in IE , other browsers are not supported. important is the phrase
IPA: OWCVBA11.CHM yourself to download and play it
var aa = eval("Spreadsheet1"+"_BeforeContextMenu"); //调用事件 Spreadsheet1.attachEvent("BeforeContextMenu",aa); Spreadsheet1.attachEvent("CommandExecute",Spreadsheet1_CommandExecute); Spreadsheet1.attachEvent("BeforeKeyDown",Spreadsheet1_BeforeKeyDown);
<table width="100%" cellpadding="0" cellspacing="0" border="0"> <tr> <td bgcolor="#336699" height="25" width="10%"> </td> <td bgcolor="#666666" width="85%"> <font face="宋体" color="white" size="4"> <b> 缺少 Microsoft Office Web Components</b> </font> </td> </tr> <tr> <td bgcolor="#cccccc" width="15"> </td><td bgcolor="#cccccc" width="500px"><br> <font face="宋体" size="2">此网页要求 Microsoft Office Web Components。 <p align="center"> <a href="C:/IUware Online/Microsoft Office Professional Enterprise Edition 2003/files/owc11/setup.exe"> 单击此处安装 Microsoft Office Web Components。 </a>. </p> </font> <p> <font face="宋体" size="2"> 此网页同时要求 Microsoft Internet Explorer 5.01 或更高版本。</p> <p align="center"/><a href="http://www.microsoft.com/windows/ie/default.htm"> 单击此处安装最新的 Internet Explorer</a>. </font><br> </td> </tr> </table>
</OBJECT> </body>
</html>
------ Solution ------------------------------------- ------- 1. use openoffice to pdf convert . swf 2.jsp used flexpaper open . swf file ------ Solution -------------------------- ------------------
correct. I said before how I deal with : 1. user uploaded word, xls, ppt, pdf after such original documents processed in the background , if not pdf format are converted into pdf format with openoffice 2. obtained in the first step of pdf files can be converted by this tool into the corresponding pdf2swf.exe swf 3. step used in jsp flexpaper generated can preview the swf
OK ------ Solution ----------------------------------- --------- our items are third-party tools to pay ------ Solution ----------------- --------------------------- ask your question solved? I have to solve this problem , can help me ? ------ Solution ---------------------------------------- ---- reference openOffice swftools done before send you a link http://www.cnblogs.com/star-studio/archive/2011/12/09/2281807.html
------ Solution ------------------------------------ -------- should also have some weboffice plug it, with a commercial version of the company 's gold grid control , compatible with what are good ------ Solution ------ -------------------------------------- not so much trouble now , java can be achieved ah. Oh, I've done :
------ Solution ------------------------------------- ------- flexpaper this plugin, I personally think it is very easy to use , have used before . ------ Solution ---------------------------------------- ---- determine if the type of office documents 1. Through openoffice convert files to pdf 2. speaking through swftools convert pdf files into swf format 3. browse through flex web
------ Solution ------------------------------------ -------- top 1L, my suggestion is that if the requirements are not particularly stringent , uniform turn into a pdf document , the front page with adobe reader plug-in to the online preview pdf documents, such as we have just done demand ------ Solution --------------------------------------- ----- nb plugin AC_FL_RunContent ------ For reference only ------------------------ --------------- may not help you, this thing is done to make money , it is impossible free ------ For reference only - --------------------------------------
Thank you for your help I imagine the way ------ For reference only ------------------------------ ---------
Demo Or you can give a good example of not before , now on-line project hurry , hurry ah Thank ------ For reference only --------------------------------- ------ directly open pdf achieved through the online preview, how not ? ------ For reference only -------------------------------------- - landlord seeking to achieve the right demo grateful ah ah. . . . ------ For reference only -------------------------------------- - my mailbox 454402218@qq.com ------ For reference only -------------------------- ------------- openoffice and flexpaper to use this combination to achieve . . I study two days before good ! ! Also need to install a few things. . There needs to be sent to you. . . ------ For reference only -------------------------------------- - above world can only preview the document , if you want to preview documents in other formats , add their own judgment, and then set the header information.
------ For reference only ----------------------------------- ----
look it troublesome to me thank my mailbox 454402218@qq.com ------ For reference only ------- -------------------------------- has been sent to your mailbox. . . ------ For reference only -------------------------------------- - can send it to my mailbox , I also do this , 365834556@qq.com, grateful ------ For reference only ------------- --------------------------
Before adopting done this way , but the function is not very powerful. ------ For reference only -------------------------------------- - landlord , you can send to my mail? I'm looking for this , 1525950302@qq.com grateful ------ For reference only ------------------------ --------------- landlord, also send me free copies Oh , flexpaper use always reach the desired effect 2633522342@qq.com ------ For reference only ----------------------------- ---------- landlord , you can send to my mail? I'm looking for this , 602749539@qq.com grateful ------ For reference only ---------------------- ----------------- this online viewing . I personally feel that depends on how you are planning : 1 , online documents, so that after the display . 2 , deal with the next line of the document , online direct display . willing to invest , get hold of the commercial code, and convenient. Refused to vote the money , how simple and how to do . purely with people views. ------ For reference only -------------------------------------- - landlord , you can send to my mail? I'm looking for this , 88165868@qq.com grateful ------ For reference only ---------------------- ----------------- read a pdf using iText to read data from the database when generating pdf quickly, and as long as the client installed adobe flash basic can online preview. If only online preview iText basically no problem . iText support picture form displayed. ------ For reference only -------------------------------------- -
752915708@qq.com trouble appreciate a copy of it ! ! ! ------ For reference only -------------------------------------- - studied flexpaper, basically based on third-party tools to achieve them will be relatively simple, but do not know if you have not found the file flexpaper only access to the project directory and can not access local files ( such as the file uploaded on the D drive ) to achieve the landlord did not know , or have solved this problem brothers seeking examples ~ 691226682@qq.com ------ For reference only ----- ---------------------------------- are learning , like to refer to demo, I hope my dear friend sent me a grateful brother . 784773798@qq.com ------ For reference only --------------------------------- ------
ie how I can only preview ah , Firefox will not be in , ah, please guide us , thank you ------ For reference only - ------------------------------------- 957581081@qq.com trouble to send a recently the company to the task bar , be grateful ! ! ! ------ For reference only -------------------------------------- - wq_1108@qq.com seeking code ah ------ For reference only ------------------------------- -------- today found a very good document preview online service, you can install your own server , REST interface calls , pure html page, the browser compatibility is very good, in the phone , tablet and computer adaptive perfect preview of different terminals , 1M about the document completely free , recommended for everyone, Website : www.idocv.com ------ For reference only ------------- -------------------------- pro said that you did , give or sub- dome , said the next item? yaodk@neusoft.com ------ For reference only --------------------------------- ------
I need , thank you ! dhdream@126.com
------ For reference only ---------------------------------- -----
I need , thank you ! dhdream@126.com
I also need to thank the 877344151@qq.com ------ For reference only ------------------- --------------------
seeking example , 877344151@qq.com ------ For reference only ------------------------ --------------- seeking examples , thank you 877344151@qq.com ------ For reference only - -------------------------------------
I need , thank you ! dhdream@126.com with the request, thank you ! ! ! 516412376@qq.com ------ For reference only ------------------------------- -------- seeking to share ! ! ! 982910864@qq.com ------ For reference only ----------------------------- ---------- give me a copy of it , 317335525@qq.com. Thank you !