Revision Block Description

Revision Block Description

Boleivia
Contributor Contributor
576 Views
2 Replies
Message 1 of 3

Revision Block Description

Boleivia
Contributor
Contributor

Greetings

 

We are using some i logic to place the initial revision table on our drawings and to remove a "Preliminary, Do not Manufacture" symbol when the drawings are ready for release.

 

We have been able to read the description item from the table but can not write to it.

 

We have not been able to fill in the revision table description thru the iLogic code.

 

Am I missing something? Is the description item read only?

 

Thanks

Scott

 

' Start of iLogic code.....

' This iLogic code will renumber hole tags for all hole tables in all sheets of the active drawing
        
' Define document
        Dim oDoc As DrawingDocument
        
' Is the currently active document a drawing?
        Try
            oDoc = ThisApplication.ActiveDocument
        Catch
            MsgBox("This rule can only be run in a drawing document! - Exiting...", 64, "Cadline iLogic")
            Return
        End Try
        
'*******************************Add Revision Table******************************************'Define Revision Table 
        Dim oRTBs As RevisionTables
            oRTBs = oDoc.ActiveSheet.RevisionTables
 
'Define Revision Table Location    
    Dim oLocation As Point2d
            oLocation = ThisApplication.TransientGeometry.CreatePoint2d(63.77, 53.34)
 
'add a new table
     Dim oRTB As RevisionTable
        oRTB = oRTBs.Add2(oLocation, True, True, True, "A")

'Populate Description
    Dim oRow As RevisionTableRow
    oRow = oRTB.RevisionTableRows.Item(1)

    
    Dim oCell As RevisionTableCell
    oCell = oRow.Item(3)
    'MsgBox(oCell.text)
    'oRow.Item(3)="MFG RELEASE"



'*******************************Remove Prelim Symbole******************************************'Define Symbol
    Dim oSketchedSymbol As SketchedSymbol

'Search for Preliminary symbol and delete
    For Each oSketchedSymbol In oDoc.ActiveSheet.SketchedSymbols
        If oSketchedSymbol.Definition.Name = "PRELIMINARY" Then
            oSketchedSymbol.Delete
        End If
    Next       
        
' End of iLogic code...
    

 

0 Likes
Accepted solutions (1)
577 Views
2 Replies
Replies (2)
Message 2 of 3

MechMachineMan
Advisor
Advisor
Accepted solution

You also need to access the Text method to write to the cell.

 

ie;

 

oCell.Text = "RELEASED FOR MFG"


--------------------------------------
Did you find this reply helpful ? If so please use the 'Accept as Solution' or 'Like' button below.

Justin K
Inventor 2018.2.3, Build 227 | Excel 2013+ VBA
ERP/CAD Communication | Custom Scripting
Machine Design | Process Optimization


iLogic/Inventor API: Autodesk Online Help | API Shortcut In Google Chrome | iLogic API Documentation
Vb.Net/VBA Programming: MSDN | Stackoverflow | Excel Object Model
Inventor API/VBA/Vb.Net Learning Resources: Forum Thread

Sample Solutions:Debugging in iLogic ( and Batch PDF Export Sample ) | API HasSaveCopyAs Issues |
BOM Export & Column Reorder | Reorient Skewed Part | Add Internal Profile Dogbones |
Run iLogic From VBA | Batch File Renaming| Continuous Pick/Rename Objects

Local Help: %PUBLIC%\Documents\Autodesk\Inventor 2018\Local Help

Ideas: Dockable/Customizable Property Browser | Section Line API/Thread Feature in Assembly/PartsList API Static Cells | Fourth BOM Type
0 Likes
Message 3 of 3

Boleivia
Contributor
Contributor

Perfect

Thanks Justin

0 Likes