This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
hii guys .. i was trying develop sample test proram to read from the file with the following code... first 4 bytes are said to be the magic cookie value(Numeric)and other header part .. It doesnt give me the proper values as i was expecting numeric value for cookie and total fields ..can anyone tell me whats wrong with the follwoing code ...
SCJP 1.4<br />SCWCD 1.4(91%)<br />Working on SCJD -Bodgitt & Scrapper Constructions...<br /> <br />"It takes 43 muscles to frown & 17 to smile but it doen't take any to just sit there with a dumb look on your face .. Keep Smiling "
To elaborate a little: when the assignment specification mentions binary (numeric) data it means that you can read it into a variable that is a Javaprimitive type. You can determine that type usually by looking at the length of the field. So if the binary field is 2 bytes it must be a 16 bits Java primitive. Once you have determined the primitive type you can select from the API the appropriate methods to read and write it. [ September 23, 2006: Message edited by: Barry Gaunt ]