Monday, August 18, 2014

Autodesk Vault Programmer's Cookbook. 4.3. Adding users

You can add user by calling AddUser method.
Hereinafter Vault2014PowerConsole will be used to illustrate usage of methods.

"Autodesk Vault Extreme Administrating" training

Class Description

This class surveys approaches, technologies and tools that would be helpful for reliable Vault administration and management.
We will overview different ways to comprehensively minimize risks and optimize resources in planning, installing, managing, maintaining, migrating, securing, updating and upgrading your Vault system.
We'll show you bunch of tools and teach how to adapt them to cover your needs.

Class Length
4 Days

Learning Objectives
  • Recognize and prevent risks in Vault for which you are responsible
  • Comprehensively improve Vault reliability
  • Make fast deployments of new Vault systems, organize interaction with different CAD systems and PLM 360
  • Collect, configure and manage tools for handy Vault administration
Target audience
  • System integrators
  • System Administrators
  • IT
Date
Fall/Winter 2014-2015

Venue(s)
Most convenient for better part of attendees in next regions:
  • Americas
  • Asia
  • Europe
  • Oceania

Event registration

"Autodesk Vault Advanced Programming" training

Class Description

This class teaches you Autodesk Vault API essentials and provides you low start for programming under Vault.
We will create various client applications to interact with Autodesk Vault Server. Programs will be written on PowerShell - as easy-to-start, quick response, succinct and clear .NET environment for learning and administration objectives. We will also touch on some best practices, workflows, workarounds, tips and tricks in Vault management and administration.
Basics of interaction with different CAD systems and cloud services will be covered too.
We'll show you actual projects where Autodesk Vault API has been used, share the collection of PowerShell source code and learn how to utilize it properly. And show you how to translate it to other programming languages to create versatile plug-ins and stand-alone applications.

Class Length
4 Days

Learning Objectives
  • Clearly understand the concepts of Autodesk Vault API framework
  • To use PowerShell language for Vault server interaction and to solve tasks of IT administrator and system integrator with it
  • Develop applications to cover own needs in Vault management, interaction with different CAD systems and PLM 360
  • Easy create UI and automate frequent tasks of Vault Administration and management
Target audience
  • Programmers
  • System Administrators
  • IT
Date
Fall/Winter 2014-2015

Venue(s)
Most convenient for better part of attendees in next regions:
  • Americas
  • Asia
  • Europe
  • Oceania

Event registration


Friday, August 15, 2014

Autodesk Vault Programmer's Cookbook. 4.2. Getting more user information

To get information about users' permission and roles use next methods:
Object
Option
Method
Permissions
ByUserId
GetPermissionsByUserId
Roles
ByUserId
GetRolesByUserId
Hereinafter Vault2014PowerConsole will be used to illustrate usage of methods.
Where:

  • You are already logged in with Connect-VaultCMD or Connect-VaultVDF commandlet
  • $vltAdminSvc - AdminService

Tuesday, August 12, 2014

Connecting Autodesk Inventor Content Center from PowerShell

So. Some fun in the middle of the week.

In prospect you'll be able to edit Content Center libraries bypassing Autodesk Inventor Content Center Editor. Take a look.

How it works:

We are allowed to use this DLLs and their methods, but there is no documentation on them and no Autodesk support will be provided - this is the official position of Autodesk.

Friday, August 8, 2014

Starting with Vault2014powerConsole

Specifically for Autodesk Vault programming lectures by ZippyBytes, the PowerShell-based (Wikipedia, MSDN) module is designed.

Installing Vault 2014 PowerConsole

  1. Make sure that PowerShell is installed on your system. E.g. through Start menu, or executing powershell command from cmd.
  2. If PowerShell is not installed, install it using How to Install Windows PowerShell 4.0 article.
  3. Check PowerShell version by $PSVersionTable.PSVersion (Stack Overflow) command. If version is less than 4.0, you are recommended to update it to 4.0 using Windows Management Framework 4.0. Be sure to read the installation instructions and system requirements.
  4. Check execution policy by Get-ExecutionPolicy cmdlet. If it no equals RemoteSigned (e.g. Restricted), set it up by Set-ExecutionPolicy RemoteSigned.
  5. Download Vault2014PowerConsole.exe package from GitHub. Source code also available.
  6. Installation puts module files into c:\Users\[CurrentUser]\Documents\WindowsPowerShell\Modules\Vault2014PowerConsole directory, and also creates shortcuts in Start menu under ZippyBytes folder.

Starting with Vault 2014 PowerConsole

Connecting Vault

You can connect Vault using following cmdlets:

Connect-VaultCMD

Connects Vault through command prompt. Usage examples:
Connect-VaultCMD
After the launching cmdlet it will ask you for all parameters: server, vault, username, password.



Such approach is useful for scripting outside Vault 2014 PowerConsole. You are importing module first, then establishing connection. Example:



Connect-VaultVDF

Calling regular Vault login dialog.


Module variables

Fore useful dealing with module, next variables are defined:
  • vltActiveConn - current active connection
  • vltAdminSvc - AdminService
  • vltDocumentSvc - DocumentService
  • vltFilestoreSvc - FilestoreService
  • vltFolderCurrent - current folder, object of Autodesk.Connectivity.WebServices.Folder class
  • vltGroups - list of groups, an array of Autodesk.Connectivity.WebServices.Group objects
  • vltRoles - list of roles, an array of Autodesk.Connectivity.WebServices.Roles objects
  • vltUsers - list of users, an array of Autodesk.Connectivity.WebServices.Users objects
Note: place $ sign before variable to access it.

Module cmdlets

Next module cmdlets are available (you can get list of them by Get-Command -Module Vault2014PowerConsole):
  • Add-VaultFile
  • Add-VaultFileHidden
  • Add-VaultFolder
  • Add-VaultFolderLibrary
  • Connect-VaultCMD
  • Connect-VaultVDF
  • Disconnect-Vault
  • Get-FilePath
  • Get-VaultAllConnections
  • Get-VaultChildItem
  • Get-VaultFolder
  • Get-VaultPowerConsoleHelp
  • Get-VaultVariables
  • Get-VaultVariablesDescriptions
  • Set-VaultActiveConnection
  • Set-VaultLocation
  • Set-VaultVariables
To access cmdlet info use Get-Help cmdletName.


Tuesday, August 5, 2014

Autodesk Vault Programmer's Cookbook. 4.1. Getting user information

To retreive information about users you have to call Get*User* methods from AdminService:

Object Options Method name
AllUsers GetAllUsers
User ByUserId GetUserByUserId
MemberUsers ByGroupId GetMemberUsersByGroupId
UserInfo ByUserId GetUserInfoByUserId
UserInfos ByUserIds GetUserInfosByUserIds
The simplest is GetAllUsers(), it returns all users with no input.
After calling it you can output all objects, or filter required. PowerShell filtering is available from Where-Object cmdlet:
Since now the Vault2014powerConsole will be used to illustrate code. After login you have
$vltActiveConn object that represents active connection. You can also use $vltAdminSvc to acces AdminService.

Results are represented on video:

Using Vault2014powerConsole - Part 1. Connecting Vault

Now you can connect Vault via PowerShell command line. Take a look how to do this with Vault2014powerConsole.

 

Monday, August 4, 2014

Concept of Virtual Design Technology

Some thoughts in region of CAD and data management with proposing the solutions.

Introduction

What’s usually happening while implementing CAD, PDM or PLM technology?
After implementation users usually trying to find the way how can they deal with workflow. In CAD they’re trying to create model, or even “paint” it. If even they create model through parameterizing, they’re just “playing” with the expensive toy.

Problem formalizing

Let’s draw an analogy of working process to playing chess, or proving of the math theorem. The big task of winning, or theorem proving divides on bunch of hierarch-spitted common tasks. In chess – this is chess etudes, which are masterly linking into game, in math – the conveyor of lemmas, that provides the solution. Etudes and lemmas – are “best practices”, “jazz standards” of knowledge field, which they are representing.

Currently almost all of domains are isolated each from other by vendors, software, geo-locations, companies and even departments.

Why can’t we share each other our knowledge and achievements? Surely there’re certain business secrets, but what about basic knowledge, like: physic, chemistry, math, standards (DIN, ISO, JIS, etc.), electrics, mechanics and others? A numerous work hours are spending daily to reproduce already solved problems; we’re stuck in basics instead developing something really good. End-users in Germany are spoiling their time on created already designed piping models for Inventor while there’re already created ones in Canada for Solidworks or Plant 3D. Vendors are developing different HVAC tools for AutoCAD, then for Revit, ArchiCAD – but all they are having the same functionality. But if you can calculate the ducts size depending on consumers in one app – you can’t do this in other, and even you can’t enhance it to do this.

Statement of a problem

In computer-aided design there are next matters of fact:
  1. Almost every design task have been every solved and have common solution, that’s not depends on platform. 
  2. Computer aided design is aimed on reducing user’s interaction. 
  3. End-user really waits from vendor solving of all routing tasks, or just out-of-the-box best practices. 
  4. If there’s no out-of-the-box, they’re ready to buy a pack of them. 
  5. Parametric models have no interoperability within different CAD systems: Inventor Content Center components, Inventor iLogic, Revit families, Plant 3D specs, AutoCAD MEP, etc. So user has to define parametric model for each application separately. 
  6. As in previous statement, for each CAD designed separate modeling environment and wizards: Routed systems (Cable & Harness routing and Tube & Pipe routing) and frame generator in Inventor, cabling and HVAC tools for Revit, AutoCAD MEP, Plant 3D. Each content center model has to be designed with CAD-specific connector, and user could edit certain system just in that CAD it had been designed. 
  7. No CAD or PDM/PLM can provide fully-implemented system approach. At now we’re mainly playing with tools instead solving tasks. We can't see the forest behind the trees.

Solution

Let’s outline several directions of solving raised issues.
  1. Creating catalogue of best-practices blocks: components, operations, standards, rules, wizards, user interfaces. 
  2. They should be widely applicable: in different apps of one vendor, for different vendors’ software, on desktop or in the cloud. 
  3. The main repository is always up-to date, end-users can get new functions like an anti-virus updates. 
  4. The best practices are described on common language, which could be interpreted by add-on over CAD/PDM system, any part of PLM solution – the analog of Virtual Studio Technology (VST) in audio software.
Here are some obvious benefits of technology:
  1. Benefits of end-users 
    1. Standardized workflows for different tasks and regions (MFG, AEC). 
    2. No more from the ground development. 
  2. Benefits of vendors 
    1. Providing more conformity tools enhances user’s sympathy. 
    2. Development of platform-independent VDT’s (Virtual Design Technology) reduces costs on software development. 
  3. Benefits of distributors 
    1. Increasing of sales via big implementations and subscriptions. 
  4. Benefits of resellers 
    1. Resellers receive great ability to create more complex and flexible monetizing plans. 
  5. Benefits of system integrators/implementers 
    1. Implementers should no more to develop implementations from scratch. 
    2. This is better than pre-defined implementations because customization is more flexible. 
  6. Benefits of third-party developers 
    1. Third party-developers will cover much wide target auditory – not just one vendor.
Actual delivering of technology to end-users is shown above.

Hosting of VDT at engineering systems
Workflow diagram also shown:
VDT workflow

Conclusions

Why it this technology inevitable? In evolution the symbiosis is the most winning stratagem for all parties, and must survivors are seeking this. The main goal of any vendor should be in satisfying end-user’s requirements – not in upgrading theirs solution. If vendor doesn’t meet this – he’ll become an out-sider.

--
Kind regards, Dmitry Yemelyanov aka MiWa NiZa