Authors field loses Read/Write attribute

I have an Authors field on a web form to allow the author to edit saved docuents. This works fine. I have an agent which modifies the contents of the authors field. After running the agent the field has the desired values, but the Read/Write attribute is no longer in the field properties and the document author is no longer able to edit the document, even though their name is still in the field.

Subject: Authors field loses Read/Write attribute

Not sure what your code looks like but check out setting the NotesItem.IsAuthors property in the agent. (and I’m assuming you mean item, not field…)

Subject: Authors field loses Read/Write attribute

If your agent is LotusScript,ComputeWithForm often covers a multitude of sins.

Collin

Subject: RE: Authors field loses Read/Write attribute

That did it… the IsAuthors = True didn’t work, but ComputeWithForm did.Many Thanks!

Subject: RE: Authors field loses Read/Write attribute

I’d like to see the code using NotesItem.IsAuthors = True that didn’t work. It definitely does work when used correctly. Did you remember to save the document after setting the property?

Subject: RE: Authors field loses Read/Write attribute

THE Stan Rogers? (yikes, now I’m embarrassed!)I had copied the example from the Designer Help;

Dim item As NotesItem

’ …set value of doc…

Set item = doc.GetFirstItem( “my_field” )

If item.IsAuthors Then

’ this should be an Authors field

Call item.AppendToTextList( “desired value” )

’ next line added to try and force IsAuthors

Call item.IsAuthors = True

Call doc.Save( False, True )

End If

This didn’t work, so I simply set the field value:

doc.fieldname = “desired value”

Call doc.ComputeWithForm(False, False)

Call doc.Save(False,False)

And now my Authors field works properly again.

Subject: RE: Authors field loses Read/Write attribute

Small logic problem in there … if isAuthors is false, the code to set it to true is never going to execute.

Subject: RE: Authors field loses Read/Write attribute

Must be a different Stan Rogers from Canada, unless he got a web browser in heaven:

“Many fans consider Stan Rogers the greatest Canadian folksinger ever, and the loss due to his death in an airline disaster in 1983 is still felt deeply…”

Subject: RE: Authors field loses Read/Write attribute

That, Mika, was Stanley Allison Rogers – and the descriptions you may have read on the web are deserved. The good ones anyway – there are a few peple in Canada who strongly believe that if it comes from Canada, it can’t be that good. I’ve got all of his work, and listen to it regularly.

I, on the other hand, am Stanley Lewis Rogers. My father was Stanley Frank Rogers. We were both known exclusively to our friends and family as Stan for years before anyone ever heard that other guy singing.

Subject: RE: Authors field loses Read/Write attribute

I know a lot of good things which come from Canada, but I guess native citizens often look very critically at their own productions, I’ve seen the same in Finland too.

The best thing I know from Canada is the Maple Leaf Liquer from Maple Leaf Distilleries Inc., but it’s usually very rare and hard to get.

Subject: RE: Authors field loses Read/Write attribute

Well, I’d have to say that the best things to come from Finland have been Finns. Most of my friends when I was a child had names like Maki, Mikkola, Santala, Lahti, Vuorensyrja, Pakkala, Pirhonnen, …

Subject: RE: Authors field loses Read/Write attribute

Yeah, I always wonder how many Finns actually wandered to Canada, it seems that half of their surnames are finnish ones :)Even my colleaque who is from Canada has a finnish surname.

Oh, and also my grandfather’s cousin is also Canadian, who has the same surname as him/me.

Subject: RE: Authors field loses Read/Write attribute

There’s a lot of great things that come from Canada! :wink: