ProE.net

The ProE Network

Teun Ham
  • Male
  • Arnhem
  • Netherlands
Share 
Share on Twitter
Share on Facebook

Teun Ham's Friends

Teun Ham's Groups

 

Welcome, Teun Ham!

Gifts Received

Gift

Teun Ham has not received any gifts yet

Give Teun Ham a Gift

Latest Activity

Will joined Teun Ham's group
The goal of this group is to share knowledge about the Visual Basic API which PTC has added to WildFire 4.
January 28
Claudiu joined Teun Ham's group
The goal of this group is to share knowledge about the Visual Basic API which PTC has added to WildFire 4.
January 18
I successfully ran (stepped thru) program above: Open a Pro/Engineer file in Excel VBA 2003. But when I tried to add code to it to Get a Parameter in the part file: A = oModel.GetParam("A") the Excel VBA compiler said: Method or data member not foun…
September 24, 2009
The goal of this group is to share knowledge about the Visual Basic API which PTC has added to WildFire 4.
September 24, 2009
Hi, I also get the same error message and my environment is set up just as you described. I tried to find solution on ptc.com site but there is none. Maybe the path to the text folder have to be explicitly defined in connection function. Nice site.…
September 16, 2009
I forgot one thing, which is likely the cause why you are getting that error... You have to add two System Variables in order to be able to communicate with ProE 1) RMB on My Computer --> Properties 2) Advanced --> Environment Variables 3) Add the…
August 28, 2009
Hi Gary, Strange, it looks like you have got the correct setup (WF4 running, and a reference to "Pro/E VB API Type Library for Pro/E Wildfire 4.0"), so you should not get that error... Can you get the macro which starts WF4.0 to work? (see another…
August 27, 2009
Can you tell me what the prerequisites are to be able to run this code? I have ProE Wildfire 4.0 installed and running, I have MS Excel 2007 with the Pro/E API Reference loaded, but when I run it, I get an error window on the Set conn = asynconn.Con…
August 27, 2009
Teun Ham added a blog post
This code will connect to a running session of Pro/ENGINEER and will change the Working Directory: Sub Main() Dim asynconn As New pfcls.CCpfcAsyncConnection Dim conn As pfcls.IpfcAsyncConnection Dim session As pfcls.IpfcBaseSession 'Make an asynch…
July 11, 2009
The goal of this group is to share knowledge about the Visual Basic API which PTC has added to WildFire 4.
July 9, 2009
Teun Ham updated their profile photo
July 9, 2009
Teun Ham added a photo to the album 'Visual Basic API KB'
July 9, 2009
Teun Ham added 2 blog posts
July 8, 2009
The goal of this group is to share knowledge about the Visual Basic API which PTC has added to WildFire 4.
July 2, 2009
Teun Ham and Chris Bouwman are now friends
July 2, 2009
Teun Ham added 2 blog posts
July 2, 2009

Profile Information

Teun Ham's Blog

Teun Ham

VBA - Connect to Pro/ENGINEER

This code will connect to a running session of Pro/ENGINEER and will change the Working Directory:

Sub Main()
Dim asynconn As New pfcls.CCpfcAsyncConnection
Dim conn As pfcls.IpfcAsyncConnection
Dim session As pfcls.IpfcBaseSession

'Make an asynchronous connection with Pro/ENGINEER
Set conn = asynconn.Connect("", "", ".", 5)

'Get the current session
Set session = conn.session

'S
Continue

Posted on July 8, 2009 at 12:00pm — 4 Comments

Teun Ham

VBA - Run a 'mapkey'

The code below shows how to run a 'mapkey'

For this example you will need to have a drawing open in Pro/ENGINEER

Sub Print_Current_Sheet_To_PDF()
Dim asynconn As New pfcls.CCpfcAsyncConnection
Dim conn As pfcls.IpfcAsyncConnection
Dim session As pfcls.IpfcBaseSession

'Make an asynchronous connection with Pro/ENGINEER
Set conn = asynconn.Connect("", "", ".", 5)

'Get the current s
Continue

Posted on July 2, 2009 at 3:00pm —

Teun Ham

VBA - Open a Pro/E file in a new window

This routine will open a Pro/E file from your WorkingDirectory in a new window:

Sub Main()
Dim asynconn As New pfcls.CCpfcAsyncConnection
Dim conn As pfcls.IpfcAsyncConnection
Dim session As pfcls.IpfcBaseSession
Dim oModel As pfcls.IpfcModel

'Make an asynchronous connection with Pro/ENGINEER
Set conn = asynconn.Connect("", "", ".", 5)

'Get the current session
Set session = conn.
Continue

Posted on July 2, 2009 at 2:00pm —

Comment Wall (1 comment)

You need to be a member of ProE.net to add comments!

Join ProE.net

At 11:49pm on September 5, 2009, www.makemoneywith-google.com said…
I just made $765 this week working from home for google. I cant believe how easy this is. Im recommending this to everyone, check out this guys google blog makemoneywith-google.com
 
 

Badge

Loading…
 

© 2010   Created by Deelip Menezes on Ning.   Create a Ning Network!

Badges  |  Report an Issue  |  Privacy  |  Terms of Service

Sign in to chat!