[prev in list] [next in list] [prev in thread] [next in thread] 

List:       koffice-devel
Subject:    Re: KSpread DCOP question
From:       Holger =?iso-8859-1?q?Schr=F6der?= <holger-kde () holgis ! net>
Date:       2003-04-21 17:19:36
[Download RAW message or body]

Hi,

you already get the idea:
in kspread we donīt provide a special layer for accessing stuff from outside 
of kspread, but we make the methods callable from outside, so you have to 
collect the information the way you described.

to get access to a cell, you have to do the following:

have a kspread open, then enter this on the command line:

sh-2.05b$ dcop
...
kspread-2669
...
sh-2.05b$ dcop kspread-2669
qt
0x8176220
Application
Document-0
Document/Map/unnamed
KoApplicationIface (default)
MainApplication-Interface
View-0
kspread-mainwindow#1
ksycoca
sh-2.05b$ dcop kspread-2669 0x8176220

[a lot of functions will be listed]

sh-2.05b$ dcop kspread-2669 0x8176220 text
call failed
sh-2.05b$

ahem, for koffice 1.2.1 it always crashes on me, but i donīt have 1.3_beta1 at 
hand, but i guess it will works there...
(bugreport already written.)

i am quite confident that, even if kspread-1.3_beta1 would have that bug, it 
will be fixed quite soon.

Holger

On Monday 21 April 2003 16:48, Pascal.Niklaus@unibas.ch wrote:
> Hi,
>
> I'd like to port an application I've originally written for Windows to KDE.
> It uses DDE to read and manipulate Excel spreadsheet cells.
>
> What I need to do is:
>
> - get a list of all open KSpread documents/sheet names
> - read the current selection (range of cells)
> - read and write specific cells
> - create a new document or sheet in an existing document
>
> I had a browse with dcop but wasn't sure what the best way to achieve my
> task was.
>
> Get all KSpread-<PID> and call KoApplicationIFace/getDocuments(), then call
> url() for all docs? Or is there an easier way? How do I get to the
> individual sheets and read/write to them?
>
> Thanks for your help
>
> Pascal
>
>
>
> -------------------------------------------------
> This mail sent through IMP: http://horde.org/imp/
>
> _______________________________________________
> koffice-devel mailing list
> koffice-devel@mail.kde.org
> http://mail.kde.org/mailman/listinfo/koffice-devel

_______________________________________________
koffice-devel mailing list
koffice-devel@mail.kde.org
http://mail.kde.org/mailman/listinfo/koffice-devel

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic