From koffice Mon Dec 16 22:06:49 2002 From: Nicolas Goutte Date: Mon, 16 Dec 2002 22:06:49 +0000 To: koffice Subject: Re: How to get data from my app to kspread X-MARC-Message: https://marc.info/?l=koffice&m=104007660504001 I suppose that your problem is not to import the ASCII files one by one i= nto=20 KSpread, but that you find it too complex/long/boring... (Otheriwise, I h= ave=20 misunderstood your question.) One way would be that your application generates KSpread files directly. = They=20 do not need to be zipped, as the KOffice library allows raw XML files to = be=20 loaded instead of zipped douments. However be careful that the file name = ends=20 in .ksp or the file would not be recognized as KSpread file. (The DTD is = in=20 koffice/kspread/dtd/kspread.dtd but be careful that the DTD might not=20 represent the effectively used KSP file format. So you better look at an=20 actual KSpread file to learn the file format.) Another possibility, but a more complex one, is to generate any XML file = and=20 to use the XSL facility of KOffice. However, you have to write the XSL=20 template yourself, so normally it is easier to chose another way to load. Of course, perhaps you could also use any of the other file format known = by=20 KSpread's import filters, like: Gnumeric, Excel, DBase, Opencalc or Appli= x=20 Spreadsheet. In theory, you have also another posibility: to generate a file in your=20 private file format and to import it in KSpread by a private import filte= r=20 that you would have written. I hope that at least one of the suggestion may suit you. Have a nice day/evening/night! On Monday 16 December 2002 21:31, Kevin E. Fogarty wrote: > I would like to use kspread(?) to tabulate data originating interactive= ly > in another application - one I wrote myself (not a KDE-based applicatio= n, > but OpenGL - actually Ygl which is an IRIX-GL library clone). For reas= ons > I won't go into here, I can/will not rewrite this to use KDE. However = I > would like to somehow get columns of numbers that are produced, as easi= ly > as possible into kspread so that the use can save/chart/edit them.=20 > Currently I just create a series of text files (each with many rows of = 2 > columns, i.e. (x,y) pairs). These ascii files have to then be imported= , > one by one, into a spread sheet (actually it is easier in gnumeric than > kspread as gnumeric has a more flexible text-import dialog requiring on= ly > "whitespace" between columns). Anyone have a suggestion how I might th= ink > about approaching this? > > -- Kevin Fogarty > ______________________________________________________________________ > > Kevin E. Fogarty Biomedical Imaging Group > Professor Program in Molecular > Medicine Department of Physiology University of MA Medic= al > Center Office: (508) 856-3785 Suite 114, > Biotech-2 FAX: (508) 856-1840 373 Plantatio= n > Street Email: Kevin.Fogarty@umassmed.edu Worcester, MA, USA 01605 > ______________________________________________________________________ > > ____________________________________ > koffice mailing list > koffice@mail.kde.org > To unsubscribe please visit: > http://mail.kde.org/mailman/listinfo/koffice ____________________________________ koffice mailing list koffice@mail.kde.org To unsubscribe please visit: http://mail.kde.org/mailman/listinfo/koffice