Click here to Skip to main content
15,914,642 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Large Icon display in Explorer view Pin
Halawlaws10-Aug-05 20:38
Halawlaws10-Aug-05 20:38 
GeneralRe: Large Icon display in Explorer view Pin
BicycleTheif10-Aug-05 20:54
BicycleTheif10-Aug-05 20:54 
GeneralRe: Large Icon display in Explorer view Pin
Nishad S11-Aug-05 0:55
Nishad S11-Aug-05 0:55 
Generalcustom messages in windows forms app. Pin
Member 341989110-Aug-05 19:43
Member 341989110-Aug-05 19:43 
GeneralRe: custom messages in windows forms app. Pin
ThatsAlok10-Aug-05 20:40
ThatsAlok10-Aug-05 20:40 
GeneralRe: custom messages in windows forms app. Pin
S Douglas10-Aug-05 22:55
professionalS Douglas10-Aug-05 22:55 
GeneralHelp with fseek() Pin
Raza568010-Aug-05 19:26
Raza568010-Aug-05 19:26 
GeneralRe: Help with fseek() Pin
El Corazon10-Aug-05 19:59
El Corazon10-Aug-05 19:59 
no. of bytes from origin: the number of single character objects from the start of the file. Note on text files under windows, this sometimes includes CRLF combos of two characters to mark an end of line.

well, depending on how you want to do this. Read through each pair with fgets() storing the starting point of each pair with ftell() before each read, in an array of 1000 long integers. This provides an index to the text file that you can seek to.

Alternately, you can rewrite the file to binary, takes up less space and each integer has a known size (1,2,4,8 byte integers depending on what you want to use), or pad the text file with spaces to a known size.

If it were my software, I wouldn't randomly seek through a file that small, load the whole file in memory. But I figure that means this is probably a homework assignment. which is why my message ends here. Smile | :) good luck.

_________________________
Asu no koto o ieba, tenjo de nezumi ga warau.
Talk about things of tomorrow and the mice in the ceiling laugh. (Japanese Proverb)
GeneralRe: Help with fseek() Pin
Jose Lamas Rios10-Aug-05 20:11
Jose Lamas Rios10-Aug-05 20:11 
GeneralXP System Restore Pin
yqzq10-Aug-05 18:05
yqzq10-Aug-05 18:05 
GeneralRe: XP System Restore Pin
Supriya Tonape23-Aug-05 20:05
Supriya Tonape23-Aug-05 20:05 
GeneralList Subitem Background! Pin
LiYS10-Aug-05 17:59
LiYS10-Aug-05 17:59 
GeneralRe: List Subitem Background! Pin
Jose Lamas Rios10-Aug-05 18:10
Jose Lamas Rios10-Aug-05 18:10 
GeneralRe: List Subitem Background! Pin
LiYS10-Aug-05 18:34
LiYS10-Aug-05 18:34 
GeneralRe: List Subitem Background! Pin
Jose Lamas Rios10-Aug-05 19:54
Jose Lamas Rios10-Aug-05 19:54 
GeneralRe: List Subitem Background! Pin
LiYS10-Aug-05 20:36
LiYS10-Aug-05 20:36 
GeneralRe: List Subitem Background! Pin
LiYS10-Aug-05 20:46
LiYS10-Aug-05 20:46 
GeneralRe: List Subitem Background! Pin
Jose Lamas Rios10-Aug-05 21:17
Jose Lamas Rios10-Aug-05 21:17 
GeneralRe: List Subitem Background! Pin
LiYS10-Aug-05 21:23
LiYS10-Aug-05 21:23 
GeneralRe: List Subitem Background! Pin
Jose Lamas Rios10-Aug-05 21:39
Jose Lamas Rios10-Aug-05 21:39 
GeneralRe: List Subitem Background! Pin
LiYS10-Aug-05 21:43
LiYS10-Aug-05 21:43 
GeneralNewbie need help..! Pin
cue_ball10-Aug-05 16:48
cue_ball10-Aug-05 16:48 
GeneralRe: Newbie need help..! Pin
Christian Graus10-Aug-05 16:53
protectorChristian Graus10-Aug-05 16:53 
GeneralRe: Newbie need help..! Pin
cue_ball10-Aug-05 16:59
cue_ball10-Aug-05 16:59 
GeneralRe: Newbie need help..! Pin
Christian Graus10-Aug-05 17:01
protectorChristian Graus10-Aug-05 17:01 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.