checking if cell view is writable with SKILL, if cell view i

X

XXX

Guest
Hi,

I need to run some SKILL code on a set of cell views in a library.
The library is managed with designSync and if the cell view is checked
in, then there are pointers to the cache. The cache is not writeable for
a project user.
In order to make sure, I can write to the cell view, I need to check,
that I can edit the cell view.
If I use
cv = dnOpenCellViewByType( "test" "testc" "layout" nil "w" )
I do get a pointer back.
A
dbSave( cv) then asks me, if I want to checkout the cellview.
At that point it might already be to late, because may be I don't have
the right to open for edit, or somebody else does an edit already and I
wouldn't get a lock anyways.
So that doesn't give me a viable check.
I came across some access check function (don't remember the name right
now). This one showed the same behaviour.

Any hints, what I can do?

Cheers,

LA
 
Hi,
try ddNeedCheckout() if it returns t, you will be able to write the cv after ddCheckout()
CIao,
Sylvio

XXX wrote:
Hi,

I need to run some SKILL code on a set of cell views in a library.
The library is managed with designSync and if the cell view is checked
in, then there are pointers to the cache. The cache is not writeable for
a project user.
In order to make sure, I can write to the cell view, I need to check,
that I can edit the cell view.
If I use
cv = dnOpenCellViewByType( "test" "testc" "layout" nil "w" )
I do get a pointer back.
A
dbSave( cv) then asks me, if I want to checkout the cellview.
At that point it might already be to late, because may be I don't have
the right to open for edit, or somebody else does an edit already and I
wouldn't get a lock anyways.
So that doesn't give me a viable check.
I came across some access check function (don't remember the name right
now). This one showed the same behaviour.

Any hints, what I can do?

Cheers,

LA
 

Welcome to EDABoard.com

Sponsor

Back
Top