Vytisknout stránku | Zavřít okno

Otváranie .ipt (.iam)

Vytištěno z: CAD Fórum
Kategorie: Autodesk - stavebnictví, strojírenství, CAD/GIS
Název fóra: Inventor
Popis fóra: Otázky k programům Autodesk Inventor Professional, Product Design & Manufacturing Collection, Factory Design; digitální prototypy
URL: https://www.cadforum.cz/forum/forum_posts.asp?TID=7458
Datum vytištění: 11.čer.2026 v 15:54


Téma: Otváranie .ipt (.iam)
Odeslal: mimo0912
Předmět: Otváranie .ipt (.iam)
Datum odeslání: 27.říj.2008 v 17:07
Pozdravujem,
potreboval by som poradiť, či sa dá v Inventore 11 pri otváraní súboru súčiastky alebo zostavy spustiť makro.  Ďakujem




Odpovědi:
Odeslal: flesar
Datum odeslání: 27.říj.2008 v 19:04
Podle nápovědy pro AIP2008 by to mělo jít zařídit.

Automatic Macros

Automatic macros are macros that are automatically run when certain events happen within Autodesk Inventor. An automatic macro is like any other macro except for its name. To create an automatic macro just name a macro so it contains any of the automatic macro names. Depending on the name of the macro, it will be automatically run by Autodesk Inventor if the associated event occurs. Automatic macros are only supported within document projects. Macros within the Application or a User Project that use the names below will be ignored as far as running automatically.

Inventor identifies automatic macros by their names. For example the name for the macro that will run automatically when the document is opened is "AutoOpen." Autodesk Inventor allows some flexibility in this naming by only requiring the string to be part of the macro name. For example, the following macro names will be considered auto-open macros: AutoOpen1, AutoOpen2, NewAutoOpen, autoopen3, or TestAutoOpen4. From these examples you can see that additional characters can precede or be appended to the auto macro name. In addition, it is not case-sensitive. Because of this flexibility you can create multiple automatic macros for a single event. If there are multiple macros for an event, their order of execution is arbitrary.

Autodesk Inventor runs automatic macros automatically whenever the associated events occur. If the user presses the Shift key when the event occurs, the automatic macro will not run. For example, if the user presses the Shift key while opening a document that contains an AutoOpen macro, the macro will not run.

AutoOpen
This macro is run automatically when the document it is contained within is opened.
AutoNew
This macro is run automatically when a new document is created from a template. For this macro to be used, it must exist within the template file.
AutoSave
This macro is run automatically whenever the document it is contained within is saved.
AutoClose
This macro is run automatically whenever the document it is contained within is closed.
AutoEdit
This macro is run when parts/sub-assemblies are opened or edited.



Odeslal: mimo0912
Datum odeslání: 29.říj.2008 v 06:02
Tento HELP je aj v 11, ale neviem to spracovať do Makra. Taktiež musím sa verejne priznať, že moja angličtina nie je až taká dobrá, takže v tom texte sa trošku zamotávam. Ale každé makro má základný tvar

Sub NazovMakra()
...
...
...
End Sub

pritom, tam to tak nie je. Uvažoval som aj, že to môže byť niejaká udalosť, ale neviem. Ak má niekto s týmto skúsenosť a chcel by poradiť, budem veľmi rád.


Odeslal: Charlee
Datum odeslání: 29.říj.2008 v 06:22
Mám to vyzkoušené že to funguje ve ver 11 a 2008. Makro musí být součástí souboru při jehož otevření se má spustit. Musí se jmenovat AutoOpen případne ještě něco za.

-------------
Včera jsem byl chytrý, proto jsem chtěl změnit svět. Dnes jsem moudrý, proto měním sám sebe.


Odeslal: Vladimír Michl
Datum odeslání: 29.říj.2008 v 11:10
Ano, podstatné je to uložení makra přímo v dokumentu. Lze to řešit i přes "nadstavbová" makra, ale to je složitější.

-------------
Vladimír Michl (moderátor)
ARKANCE CZ - https://arkance.world - arkance.world
(podpora viz emea.support.arkance.world)


Odeslal: mimo0912
Datum odeslání: 31.říj.2008 v 07:16
Vďaka, funguje to už aj mne. Fungovalo to aj predtým, ale príkaz v makre, ktorý sa mal vykonať som zrušil ďalším príkazom, takže ono to prebehlo, ale po načítaní dokumentu sa to neprejavilo. Tak ešte raz, ďakujem.



Vytisknout stránku | Zavřít okno