Replication or Save Conflict

Hi All,

       i am having a problem with Replication or save conflicts. i created a view to get all theconflicts documents fron that i am taking document by one by one & changing the form name & saving the documents. when i am saving the document that document has to move from the view know but its not moving. what may be the problem.

actually i want to move all the Replication or save documents from the view.

The agent is:

Set vec=Custview.AllEntries

Set entry = vec.GetFirstEntry

	Do While Not (entry Is Nothing)

	Set doc = entry.Document

	doc.Oldform=doc.form(0)

	doc.form="Replicaconflict"

	Call doc.Save(True, False)

	Set entry = vec.GetNextEntry (entry)

		If entry Is Nothing Then

		Exit Do

	End If

Loop

please help me.

Thanks & Regards,

Archee.

Subject: Replication or Save Conflict

If your view selects documents that have a $Conflict item, your documents will still show up after executing your agent, because you do not remove that.

Subject: RE: Replication or Save Conflict

hi, if we open the Conflict documents manually & saving means automatically it will go from this view. i dont want to delete the documents just i need to save conflict documents with the other form name. thats y i wrote that agent. but i dont know why that $conflict field is still there after saving also.

Thanks & regards,

Archee.

Subject: RE: Replication or Save Conflict

Your agent performs nothing but back-end operations on the documents. That means, the only changes applied are those performed by your code. There is absolutely no other hidden or automated functionality. If the document saved with the new form shall no longer be a conflict document, you have to remove the item in your code.

Subject: RE: Replication or Save Conflict

hi, no sir manually if we open the conflict document & if save the doc means it will move from the Replica conflict view (which contains only the replica conflict documents) while i am doing the same thing through the agent why its not happening? what may be the problem? you were telling that to remove the item which item i need to remove sir i am not getting that. please help me.

Regards,

Archi.

Subject: RE: Replication or Save Conflict

Seems we have to start with the basics.

  1. What is the selection formula for your view?

  2. Does it have a form formula?

  3. If you save your documents manually, how do you do that? Using the File → Save menu or through a custom action? If so, what’s the code of that action?

A document is a conflict document, if it contains an item called “$Conflict”

Subject: RE: Replication or Save Conflict

hi sir,

  1. view selection formulae is SELECT @All & @IsAvailable($Conflict)

2)no

3)custom action & the formulae written for that action button is @If(@Command ([FileSave] );@PostedCommand ([FileCloseWindow] );“”)

Regards,

Archi.

Subject: RE: Replication or Save Conflict

Add this to your code:

doc.form=“Replicaconflict”

Call doc.RemoveItem(“$Conflict”)

Call doc.Save(True, False)

You might need to refresh the view display in the client, either manually, or through LotusScript code.

Subject: RE: Replication or Save Conflict

Hi sir, I added the code its working fine thank u so much. but my question is “Replication or Save Conflict” occurs when the document is not saved know! In the code i am changing the form name & saving the document know sir. then automatically that $Conflict field has to be removed & document has to be saved know! manually if i open the document & saving means that $conflict field will go & document is saving. why through code its not saving?

          Anyhow now my application is working fine.thank u so much sir.

Regards,

Archi.