.com.unity Forums

.com.unity Forums (http://forum.shrapnelgames.com/index.php)
-   Space Empires: IV & V (http://forum.shrapnelgames.com/forumdisplay.php?f=20)
-   -   HTML and Excel (http://forum.shrapnelgames.com/showthread.php?t=9579)

Taera June 2nd, 2003 09:00 AM

HTML and Excel
 
i need help there, does anyone know how to incorporate information from excel files into HTML files? what im looking for is putting specific cells in specific .xls file into an HTML page. anyone?

Fyron June 2nd, 2003 09:16 AM

Re: HTML and Excel
 
Maybe there is an export option that will help?

What happened to going to sleep? http://forum.shrapnelgames.com/images/icons/icon12.gif

Taera June 2nd, 2003 09:22 AM

Re: HTML and Excel
 
i didnt say i was going to sleep, i said good night http://forum.shrapnelgames.com/images/icons/icon7.gif
im studying for test fyron http://forum.shrapnelgames.com/images/icons/icon7.gif

"export" - i want the HTML to refer directly to the Excel so i only need to change one file - the .xls - for changes to take effects in numerous places. i want to use the .xls as a database for numbers untill i learn proper language such as php.

(interesting, i joined the same time fyron did... but he has 6 times my Posts)

[ June 02, 2003, 08:25: Message edited by: Taera ]

Fyron June 2nd, 2003 09:31 AM

Re: HTML and Excel
 
You can convert it to a database type file and then write a PERL, PHP, etc. script to get the values out of it. I don't think there is a way to do it with just HTML. If there is, I haven't heard of it. http://forum.shrapnelgames.com/images/icons/icon12.gif

Some way to study for a test, posting on shrapnel. http://forum.shrapnelgames.com/images/icons/icon12.gif

Jack Simth June 2nd, 2003 10:05 AM

Re: HTML and Excel
 
There is almost certainly a way to do it with VBscript, but that would require learning VBscript. Ideally, you do want to learn PHP or some such. Short term, you could theoretically build all the web pages that use the numbers as Excel spreadsheets, save the .xls Version, and use Excel's Save As function to have it generate HTML. You then have to re-post all of the HTML files every time, but you only need to change things in one place. Mind you, Microsoft products generate bad HTML and script, but it should work.

Taera June 2nd, 2003 10:16 AM

Re: HTML and Excel
 
yes fyron i know i need to learn php and i can do it via php. and yes im studying, just the page was open and the thought ran through my head... duh

jack - well yes, i guess thats the only way after all... i just thought i've seen somewhere a mentioning of using .xls spreadsheets as a simplified database accessible from other sources. bad luck, i guess.

Roanon June 2nd, 2003 10:26 AM

Re: HTML and Excel
 
I too recommend learning PHP and using something like MySQL. Its definitely faster than updating by hand, exporting/editing/importing somehow or writing a VBScript, or anything like that. And, besides, you just need to know PHP these days http://forum.shrapnelgames.com/images/icons/icon12.gif .

http://www.php.net/docs.php is a good documentation site, has them in several Languages.

Jack Simth June 2nd, 2003 10:37 AM

Re: HTML and Excel
 
Quote:

Originally posted by Taera:
jack - well yes, i guess thats the only way after all
<font size="2" face="Verdana, Helvetica, sans-serif">NOT THE ONLY WAY - just the simplest and fastest if you don't already know a good language to do it in (such as PHP). If you aren't up against a deadline, and have a good chunk of time to spare, buy a good book on PHP and write the page with that; my advice on Microsoft Excel is a stopgap measure for when you are in a hurry.
Quote:

Originally posted by Taera:
... i just thought i've seen somewhere a mentioning of using .xls spreadsheets as a simplified database accessible from other sources. bad luck, i guess.
<font size="2" face="Verdana, Helvetica, sans-serif">Oh yes, it is possible - Microsoft tries to be everything to everyone - but Office products are designed primarily for one user at a time; using Excel or Access for an Online database, while supported, is a very bad idea; it can become unstable rather readily. Ultimately, you want PHP (or equivalent) connected to an actual database. In the long run, it will be faster and easier to maintain that way.

rdouglass June 2nd, 2003 07:56 PM

Re: HTML and Excel
 
[quote]Originally posted by Jack Simth:
Quote:

Oh yes, it is possible - Microsoft tries to be everything to everyone - but Office products are designed primarily for one user at a time; using Excel or Access for an Online database, while supported, is a very bad idea....
<font size="2" face="Verdana, Helvetica, sans-serif">Maybe IYO...

Access can be a very acceptable DB platform for ASP pages - you don't HAVE to go out and fork over the $$$ for SQL. Most of it relies on the person doing the coding. I hear almost weekly how Access DB's are only good for 10 Users at a time - BAH!! I support 90+ Users on an Intranet server using Access as the DB and these are not lightweight Users. The system is 'hit' at minimum 1 every 90 seconds per user and serves up info on over 30,000 pages (not dynamic pages but static content) and doesn't even hiccup.

Again, the key is in the coding. You have to be efficient when opening and closing the DB connection (open at the Last possible moment and close as soon as possible), usig commands like "getrows" and not stuff like rs.movenext http://forum.shrapnelgames.com/images/icons/shock.gif http://forum.shrapnelgames.com/images/icons/blush.gif . Don't use DSN connections and let your SQL query define the records as precisely as possible. IOW don't use "SELECT * FROM myTable...".

There's a lot written out there, but the bottom line is don't think you need a sledge hammer to kill a mosquito. There are so many people saying you need that sledgehammer....'course there were many people saying the 'world is flat' as well http://forum.shrapnelgames.com/images/icons/icon10.gif

If you really want to use Excel you can. Check MS's site or try this page:

http://www.aspfaqs.com/webtech/051502-1.shtml

Hope it helps... </$.02>

[ June 02, 2003, 18:56: Message edited by: rdouglass ]

tesco samoa June 2nd, 2003 09:22 PM

Re: HTML and Excel
 
hi taera I as well recommend that you do not use excel as a database.

Mysql is free and can be used on most os's

If you want send me a pm... and let me know what your doing....

Perhaps I can send you some sample code... or point you to that direction.

The scripting language php and/or asp is good to learn ( both scripts are rather similar, it is the coding concepts that take time ).

The good thing about the database and a scripting language is that you can do your table generation (with data )on the fly using responce.write

There are a few really good tutorials on creating a database driven web site that will help you.

such as asp today. 4 guys from rolla,

http://www.phpbuilder.com/
www.planet-source-code.com

As your new at this. I recommend you learn it the right way first time around.

At first it will seem like alot of investment in time... But it will save time a few weeks down the road.

A solid weekend is all it should take to learn basic mysql and one of the scripting Languages at a basic level( to a point you understand what you need to do to create spread sheets on the fly from a database )

And it will help you with reading source code examples so you can take and reuse.

Trial and error will help you gain experience


All times are GMT -4. The time now is 05:14 AM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2025, Shrapnel Games, Inc. - All Rights Reserved.