I face above problem this morning when trying to install Windows XP on my friend’s notebook,
ops, “hard drive corrupt!”, that is my first impression, but, it just seems like the same problem I try to install on my cousin’s notebook last month, but I just told him his hard drive was corrupted, and ask him to replace a new one at that moment, sigh… sorry dude.
Anyway, forgot the experience, and I would like to thanks the owner from this post, because I got the solution from it.
Actually the solution is quite simple, just change the SATA mode from XXXX to IDE from BIOS setting, or another solution will be install your SATA RAID driver get from manufacture, that’s it!
Author: dicksonkho
Thread safe servlet
Just half way reading a book, and found something is important in order to create a thread safe servlet, few attribute and variable must be synchronized as below:
- Context Scope Attribute
- Session Scope Attribute
- Instance Variable
- Static Variable/Class Variable
Disable create a war/jar file in Netbeans6
To disable generation of a WAR file for a project:
1 . In the Files window, open your project folder and open build.xml.
2 . Override the do-dist target to have no contents and no dependencies. For example, add the following to build.xml:
<target name=”do-dist”/>
To disable generation of a JAR file for a project:
1 . In the Files window, open your project folder and open build.xml.
2 . Override the jar target to have no contents and no dependencies. For example, add the following to build.xml:
<target name=”jar”/>
*Information is getting from Netbeans help file.
Fedora core 8 – Twin View/DualScreen
Wow, desktop extended, can have more icon to put, can manipulate files at *large* screen…
1) open a terminal, type xrandr to check your display configuration, see image below:
NOTE : based on the result, maximum resolution to display = 2048 x 768 and 2 output is currently connected, which is VGA-0 and DVI-0, ok, note it down, it’s needed to edit xorg.conf file.
2) create a copy of /etc/X11/xorg.conf as xorg.conf.ori for backup purposes.
3) edit xorg.conf as example below :
# Xorg configuration created by pyxf86config Section "ServerLayout" Identifier "Default Layout" Screen 0 "Screen0" 0 0 InputDevice "Keyboard0" "CoreKeyboard" EndSection Section "InputDevice" Identifier "Keyboard0" Driver "kbd" Option "XkbModel" "pc105" Option "XkbLayout" "us+inet" EndSection Section "Monitor" Identifier "Monitor0" VendorName "Monitor Vendor" ModelName "FLATRON 775FT" HorizSync 31.5 - 61.0 VertRefresh 50.0 - 75.0 Option "dpms" EndSection Section "Monitor" Identifier "Monitor1" VendorName "Monitor Vendor" ModelName "FLATRON 775FT" HorizSync 31.5 - 61.0 VertRefresh 50.0 - 75.0 Option "RightOf" "Monitor0" EndSection Section "Device" Identifier "Videocard0" Driver "radeon" Option "Monitor-VGA-0" "Monitor0" Option "Monitor-DVI-0" "Monitor1" EndSection Section "Screen" Identifier "Screen0" Device "Videocard0" DefaultDepth 24 SubSection "Display" Viewport 0 0 Virtual 2048 768 Depth 24 Modes "1024x768" EndSubSection EndSection # End Xorg configuration created by pyxf86config
4) Few thing here you need to aware of (for those keyword in red colour), and need to change accordingly your hardware:
- RightOf – its a identifier which determine where your 2nd screen to display, other usable keywords are , “LeftOf” , “Above”, “Below”. In this case: monitor1 is RightOf monitor0
- VGA-0 and DVI-0 – there are output connected to your monitor.
- 2048 768 – It is maximum resolution for your Virtual configuration.
P/S : From my understanding after doing these, I think we just created a virtual screen which has big resolution(2048×768) and so, we can view it as twin screen as both screen will get 1024×768 individually.
Please correct me, if I’m wrong 🙂
NetBeans 6 java.lang.ClassCastException
Wow, Netbeans6 IDE is finally out! After download here.. installed, happily run the cool IDE with newly added features…. opps….. exception occur as :
(EditorSettingsImpl.java:233)
After playing around with those settings file located at home directory as .netbeans folder, I found that, when user trying to import setting from their previous settings created by older version of Netbeans will hit such error (I use Netbeans 5.5) in their first run.
Okie, here come with solution:
- Delete folder created/imported when first run in %HOMEDIR%/.netbeans/6.0.
- Run Netbeans again, then choose not to import settings created by previous version of Netbeans
p/s : I don’t know why this senario happen in Netbeans6, as I just try out this, if you know why or have better way to solve this, please help to comment here.
1st Computing Book I Read
Insert ampersand ‘&’ in MenuStrip
Busy Googling web to looking for information “How to put an ampersand ‘&’ in menustrip ” this morning. ….
found that hard to find the related article, finally, I try to put double ‘&’, WOW!! it works.
Normally we put ‘&’ to indicate underline for the character after ‘&’
For eg : &Property will show Property
To have Save & Close like image show, simply put &Save && Close will do.
Compiler Assumptions for integral and floating point
Java technology compiler makes certain assumptions when it evaluate expressions.
When you use primitive data type value in an expression with certain operator (*,+,-,/,%), the value are automatically converted to an int value (or higher if necessary), then the operation is performed.
Unhelpful Error Message
org.hibernate.PropertyAccessException: exception setting property value with CGLIB (set hibernate.cglib.use_reflection_optimizer=false for more info) setter of com.company.core.common.pojo.Consultant.setAvailability
I found this error when I’m trying to run a method which is not related at all for Consultant class, but this error occur and make me surprise, I’ve check through the maping file, the settle method as error claim, restart netBeans, clean and build project…
but it still not working as what the expected result, FINALLY…. I found that, there is a null value in Consultant table (But the field is allow null), can some 1 tell me why….
Hibernate mapping error
org.hibernate.type.IntegerType.set(IntegerType.java:39)
Let say you declare “long” as your variable data type in your class file, but you put type =”int” in hibernate mapping file, above exception will throw.
so, be careful when mapping your hibernate xml file.
