EBDN - Community - Question & Answers

  Tuesday, 18 October 2016
  16 Replies
  6.1K Visits
0
Votes
Undo
Hi

This is my first post here, so be gentle with me :)


Default value of revisions in EB is 0-10. If user used this default setting to create 0 revision in a past, and now we need more of them, then I was fixing it with short script.
This script no longer works in EB6.6.1

Could you give me some hint how to solve it best way?

Here you can find EB6.2-6.5 script increasing limit to 100 revisions instead of 10.
Would be smarter to just replace 0-10 with 0-100 and keep other information but this is just to show principle without wall of code.


Dim oRevisions As ObjectItems
Dim oRevision As ObjectItem

Set oRevisions = Application.Selection(1).FindObjects(aucObjRevisions)

If oRevisions.Count = 1 Then
Set oRevision = oRevisions.Item(1)
oRevision.Attributes.ItemByID(425).Value = "1|10|0|0|1|0-100|0|Preliminary|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0|0||0|0|0|||(null)|0|0|0|1-32768|0|0|"
oRevision.Store
Else
MsgBox oFunction.FullName & "Installation with missing revisions"
Exit Sub

End If