473,812 Members | 2,888 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

file access - design thoughts.

Hi, I'm hoping to get some advice on this design query to see if I'm
heading in the right direction.

I would like to read a file of many lines and then search for a
particular character to break up the sentence into separate words.
Once done I will sort them.

I thought of using fgets but the line could be very very long and I
won't know it's length of n characters that could be in a line.

Using fgetc seems the better bet and put each character into an array
so I can traverse the array.

However,if I put each character into an array, I still won't know how
large to make the array.

Is there a better strategy ?

Jay

May 20 '07
22 1331
Malcolm McLean wrote:

<snip>
However you managed to persuade me that I wasn't entirely right after
all insisting on IO separate from logic. That's one of the
characteristics of intelligent people. They modify their opinions after
listening to other intelligent people.
Indeed it is.
--
Flash Gordon
May 27 '07 #21
Flash Gordon <sp**@flash-gordon.me.ukwri tes:
Malcolm McLean wrote:

<snip>
>However you managed to persuade me that I wasn't entirely right
after all insisting on IO separate from logic. That's one of the
characteristic s of intelligent people. They modify their opinions
after listening to other intelligent people.

Indeed it is.
Well, I used to think so, but ...

8-)}

--
Keith Thompson (The_Other_Keit h) ks***@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <* <http://users.sdsc.edu/~kst>
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
May 27 '07 #22
Keith Thompson wrote:
Flash Gordon <sp**@flash-gordon.me.ukwri tes:
>Malcolm McLean wrote:

<snip>
>>However you managed to persuade me that I wasn't entirely right
after all insisting on IO separate from logic. That's one of the
characteristi cs of intelligent people. They modify their opinions
after listening to other intelligent people.

Indeed it is.

Well, I used to think so, but ...

Hmm.. since I didn't persuade Malcolm, it follows that one of us isn't
intelligent! :-/

Who is Tom? :-P

--
Tor <torust [at] online [dot] no>

May 27 '07 #23

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
11238
by: Lauren Quantrell | last post by:
Is there a way to create a text file (such as a Windows Notepad file) by using a trigger on a table? What I want to do is to send a row of information to a table where the table: tblFileData has only one column: txtOutput I want to use the DB front end (MS Access) to send the text string to the SQL backend, then have the SQL Server create a file to a path, such as F:/myfiledate.txt that holds the text in txtOutput, then the trigger...
1
1702
by: Tim | last post by:
Hi, We are downloading a few thousand rows of data for users to choose from and need to speed up the operation. The data is related in four levels. The current design allows the user to select the first level from about 20 choices and then the next level's choices are retrieved from the server. This is taking about 4 seconds. We are required to make it faster. We need to be able to download all the data once and save it for use
2
1905
by: moller | last post by:
Im looking in to the possibility of moving from mySQL to an access database. My reasons are: (1) Database is single user. (2) Database local on users PC. (3) Database has only 8 tables where 4 are filled at database creation with aprox 20 rows each and are never added to after that. (4) Database grows with ca 6000 rows/week. (5) No data is ever deleted, exept... (6)
3
3813
by: sea | last post by:
If a runtime installation of Access is created and installed on a client machine that has a full verion of access, will it still be possible to view the tables and queries in design view but not the forms? Thank you very much, Sue
0
961
by: JTS | last post by:
I need to create three ASP.NET applications - each one will run on a different production server. Each application does basically the same thing with respect to data access; the apps differ primarily in presentation and audience. Each app will need to interact with a SQL Server database that is running on its own server. All servers will initially be on the same subnet, however there is no guarantee that they will remain on the same subnet...
5
4604
by: Water Cooler v2 | last post by:
I know that we can add a single name value entry in app.config or web.config in the configuration/configSettings/appSettings section like so: <add key="key" value="value" /> Question: I want to add a dictionary of name-value pairs. In other words, instead of a single name-value, I want to add a name-value collection in there. I could do this:
18
1554
by: Wayne | last post by:
I have a potential client who has requested design access to the prospective database so that they can change reports if and when required. Their reasons for this are: 1. They don't want to be locked into a situation where it will cost them money every time management wants a report changed and 2. They are concerned that they will be locked into relying on one person for any future changes that may be required, especially if that...
13
2408
by: NickName | last post by:
"For the vision impaired, SVG offers tremendous potential for interactive Internet mapping applications as discussed by Gardner and Bulatov (2001).". Now, here's an SVG file with fair/medium complexity, http://www.carto.net/papers/svg/samples/canvas.svg, even as a sighted person, I find its source code albeit in xml format hard to "absorb" at the first glance, let alone a visually impaired individual. The most important element seems...
0
9734
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9607
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10139
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7677
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6897
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5568
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5704
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4357
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3881
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.