Quantcast
Channel: PTC Community : All Content - Windchill
Viewing all 6049 articles
Browse latest View live

Facing issue while getting Business Attribute of a WTpart by using NEW_VERSION event

$
0
0

Hi All,

 

My requirement -> fetch a Business Attributes of WTPart, just after the WTPart creation.

 

for this purpose, i am using this event " VersionControlServiceEvent.NEW_VERSION ".

i am able to get part Name,number, creator, timestamp etc here, but when i try to fetch Business Attributes, its gives value null, even there a business attribute present with valid values.

 

Here is My code, Please let me know where i am doing wrong ?

Any help will be great !!

 

1. VersionEventListenerAdapter.java

-------------------------------

package ext;


import wt.epm.EPMDocument;
import wt.events.KeyedEvent;
import wt.fc.PersistenceHelper;
import wt.fc.QueryResult;
import wt.fc.ReferenceFactory;
import wt.fc.WTReference;
import wt.part.WTPart;
import wt.query.QuerySpec;
import wt.query.SearchCondition;
import wt.services.ServiceEventListenerAdapter;
import wt.util.WTException;
import wt.util.WTPropertyVetoException;
import wt.vc.VersionControlServiceEvent;


public class VersionEventListenerAdapter extends ServiceEventListenerAdapter {


  public VersionEventListenerAdapter(String serviceId) {     super(serviceId);  }  public void notifyVetoableEvent(Object event) throws WTException, WTPropertyVetoException {     if (!(event instanceof KeyedEvent)) {         return;     }     Object target = ((KeyedEvent) event).getEventTarget();     Object eventType = ((KeyedEvent) event).getEventType();         System.out.println("FROM @@@@@@@@@  Target >>>>> "+target);     System.out.println("FROM @@@@@@@@@  eventType >>>>> "+eventType);         ReferenceFactory refFactory = new ReferenceFactory();  WTReference ref = refFactory.getReference(target.toString());     if (eventType.equals(VersionControlServiceEvent.NEW_VERSION))     {        /** Call your business code here            example : yourMethod(target);         **/      System.out.println(">>>>>>>> INSIDE EVENT TYPE >>>> ");          if(target instanceof WTPart){      WTPart wtp = (WTPart)ref.getObject();          System.out.println("Name >> "+wtp.getName());      System.out.println("Number >> "+wtp.getNumber());      System.out.println("Created By >> "+wtp.getCreatorFullName());      System.out.println("Creation Time >> "+wtp.getCreateTimestamp());      System.out.println("Time >>> "+System.currentTimeMillis());      System.out.println(" VERSION >> "+wtp.getVersionIdentifier().getValue()+"."+wtp.getIterationIdentifier().getValue());      System.out.println("======= =================");                // below code to fetch attribute GOB_WEIGHT      com.ptc.core.lwc.server.LWCNormalizedObject obj = new com.ptc.core.lwc.server.LWCNormalizedObject(wtp, null,             java.util.Locale.US, new com.ptc.core.meta.common.DisplayOperationIdentifier());          obj.load("GOB_WEIGHT");      java.lang.String string_value = (java.lang.String) obj.get("GOB_WEIGHT");      System.out.println("Soft attibute value : " + string_value);      }     }  }  }

 

2. MStandardListenerService.java

package ext;


import wt.services.ManagerException;
import wt.services.StandardManager;
import wt.util.WTException;
import wt.vc.VersionControlServiceEvent;


public class MStandardListenerService extends StandardManager implements MListenerServiceInterface {


  private static final long serialVersionUID = 1L;  protected synchronized void performStartupProcess() throws ManagerException {     VersionEventListenerAdapter versionEventListenerAdapter = new VersionEventListenerAdapter(getName());     getManagerService().addEventListener(versionEventListenerAdapter, VersionControlServiceEvent.generateEventKey(VersionControlServiceEvent.NEW_VERSION));     getManagerService().addEventListener(versionEventListenerAdapter, VersionControlServiceEvent.generateEventKey(VersionControlServiceEvent.PRE_NEW_VERSION));     getManagerService().addEventListener(versionEventListenerAdapter, VersionControlServiceEvent.generateEventKey(VersionControlServiceEvent.POST_INSERT_ITERATION));     getManagerService().addEventListener(versionEventListenerAdapter, VersionControlServiceEvent.generateEventKey(VersionControlServiceEvent.POST_ROLLUP));     getManagerService().addEventListener(versionEventListenerAdapter, VersionControlServiceEvent.generateEventKey(VersionControlServiceEvent.POST_SUPERSEDE));      }  public static MStandardListenerService newMStandardListenerService() throws WTException {     MStandardListenerService instance = new MStandardListenerService();     instance.initialize();     return instance;  }
}

 

 

Please check and suggest me.

 

Regards,

Vivek


CAD WORKER ERROR

$
0
0

Hello everyone,

i have a problem with our cad worker, we have the following error:

18-nov-2015 18.31.59:Start Job: Assembly - 6601497a.asm, 1.11
18-nov-2015 18.31.59:make temp dir F:\ptc\Windchill\temp\pubtemp\publish1472366436063873968.tmp
18-nov-2015 18.31.59:"As Stored" Config Spec is available
18-nov-2015 18.31.59:The EPMDocument As Stored Config Spec was selected as the default
18-nov-2015 18.31.59:Start: Assembly - 6601497a.asm, 1.11
18-nov-2015 18.31.59:Authoring Application: Creo
18-nov-2015 18.31.59:Transferring Files to: F:\ptc\Windchill\temp\pubtemp\publish1472366436063873968.tmp
18-nov-2015 18.32.15:Number of Files (identified to be) Transferred: 1.201
18-nov-2015 18.32.15:Creo Asm Conversion
18-nov-2015 18.32.15:Added request to PROE queue
18-nov-2015 18.32.15:Job 33.611 submitted to worker: ARGOCREO.landini.msft-PROE:1
18-nov-2015 18.32.15:LOGID: worker_120.log
18-nov-2015 18.32.15: Registering Server
18-nov-2015 18.32.16: Downloading 6601497a.asm
18-nov-2015 18.32.20: Loading 6601497a.asm
18-nov-2015 18.33.49:Failure to retrieve 6601497a.asm name 6601497a (err = -4)
18-nov-2015 18.33.49:Asm Processing Returned: $ERROR$ Failure to retrieve 6601497a.asm name 6601497a (err = -4)
18-nov-2015 18.33.49:Attempting to delete temporary workspace publish1472366436063873968tmp.
18-nov-2015 18.33.49:Done deleting temporary workspace publish1472366436063873968tmp.
18-nov-2015 18.33.49:CadAgent Returned: $ERROR$ Failure to retrieve 6601497a.asm name 6601497a (err = -4)
18-nov-2015 18.33.49:End (with Error): Assembly - 6601497a.asm, 1.11
18-nov-2015 18.33.49:End job (with error): Assembly - 6601497a.asm, 1.11
18-nov-2015 18.33.49:Publish Complete event dispatched
18-nov-2015 18.33.49:remove temp dir: F:\ptc\Windchill\temp\pubtemp\publish1472366436063873968.tmp

every failed publishing has the same error err = -4

do you know what it means?

thanks

The transaction log for database 'WindchillDB' is full due to 'LOG_BACKUP'

$
0
0

we just started everyone in our company with creo this monday.  its only mid day wednesday, and this is the error we are all getting.

 

The transaction log for database 'WindchillDB' is full due to 'LOG_BACKUP'.

 

what is the deal with this.  is there something we can do to prevent this from happening?  not sure what these log files are, and why they take up so much space.

New to 10.2: Promotion Request rights worse than previous versions?!!

$
0
0

According to my research and the below SPRs, it appears that the rights for users to promote files are worse than previous versions of Windchill. Has anyone seen this? PTC does not want to fix it in 10.2.

  1. Users can promote checked out objects
  2. Promotion Requests with checked out objects will hand in the OPEN state and not change to UNDER REVIEW
  3. Objects UNDER REVIEW can be checked out

 

SPRs:

https://support.ptc.com/appserver/cs/view/solution.jsp?n=CS158224&source=Case%20Viewer

https://support.ptc.com/appserver/cs/view/spr.jsp?n=2892612&source=Case%20Viewer

How do i change an inherited attribute's contraint?

$
0
0

Hello all,

 

This may have already been posted somewhere, but I could not find anything on it.

 

I have performed a subtype of Part in the Types and Attribute Manager.  I now have two issues that I cannot resolve.

1) I need to use the attribute "Default Unit" - Internal Name (defaultunit), however, the legal value list is cannot be changed from "ea|as_needed|kg|m|l|sq_m|cu_m" and I need it to be "ea|as_needed|in|ft|oz|lbs|kg|m|l|sq_m|cu_m".

2) I need to add the attribute "Organization" - Internal Name (orgid).  The users need this information to associate the parts with where they are coming from - internal/vendor.

 

I know Part is a modeled type and Default Unit is inherited but the legal value list does not meet our needs.  Is there a way to modify it in some way.  I have tried adding another legal value list in constraints to override the existing one, but it did not work.

 

Any help would be greatly appreciated.

 

Thank you,

Steven

Handling customizations in upgrade from 9.1 to 10.2

$
0
0

 

All,

 

I have a couple of questions on handling customizations in our test upgrade from Intralink 9.1 M060 to 10.2 M030.

 

  1. Is our filebased versioning a customization that has to be reloaded on the target server? We originally loaded this on the source with: java wt.series.LoadFileBasedSeries.
  2. Are Object Initialization Rules (OIR's) customizations that need to be created on the target server? We originally created OIR's on the source from .xml files.

 

The upgrade guide says the following about filebased series:

 

"If your source system has file-based series, then you need to verify that the file-based series on the target system is in sync with the source system’s filebased series. Ensure that the versioning scheme is set up in wt.properties on the target system exactly like it is on the source system."

 

How would I verify that the "file-based series on the target system is in sync with the source system’s filebased series"?

 

Which properties in wt.properties am I looking for to "Ensure that the versioning scheme is set up in wt.properties on the target system exactly like it is on the source system."?

 

The upgrade guide also mentions OIR's with this statement:

 

"Verify that there are object initialization rules (OIRs) for every versioned object type in the system and that they are using a valid series (defined in wt.properties or a file-based series). Ensure that the wt.properties has the same series configuration as the source system."

 

How would I verify this? When the upgrade guide says "verify" does in really mean "create"?

 

In general I don't have a clear understanding of what Windchill configurations and settings have to be manually performed on the target server versus which ones come in with the imported database.

 

Thanks,

 

Mike Foster

 

Orbital ATK

 

How to query out (SQL Query on Oracle DB) classification in Windchill 10.2?

$
0
0

We notice the infrastructure changes in the database schema starting Windchill 10.2 and it would be helpful if someone could suggest the new tables and joins so we get our query right.

 

Here is a working query from Windchill 9.1 system (PDMLink, PartsLink, SUMA and Oracle DB)

 

SELECT

   M1.WTPARTNUMBER,

   D1.VERSIONIDA2VERSIONINFO,

   D1.ITERATIONIDA2ITERATIONINFO,

   CN.NAME

FROM

   REFERENCEDEFINITION R,

   REFERENCEVALUE RV,

   MANUFACTURERPARTMASTER M1,

   MANUFACTURERPART D1,

   CLASSIFICATIONNODE CN

WHERE

   R.DISPLAYNAME = 'Part' AND

   R.IDA2A2 = RV.IDA3A5 AND

   RV.CLASSNAMEKEYA4 = 'com.ptc.windchill.suma.part.ManufacturerPart' AND

   RV.IDA3A4 = D1.IDA2A2 AND

   D1.IDA3MASTERREFERENCE = M1.IDA2A2 AND

   RV.IDA3B5 = CN.IDA2A2;

How make to multi check select box

$
0
0

Hi, i ask something.

 

How make to multi check select box.

 

checked Item value into input box.

 

qa2.PNG


PTC LiveWorx Europe 2015 Thank you

$
0
0

Hello

 

I've been there (see picture)

IMG_2197.JPG

Thank you PTC and all your partners, It has been an excellent 2 days full of information gathering and networking.

I look forward to 2016.

 

Who else was there ?

 

Best regards

How growing Vault is managed for backup activity at your site

$
0
0

Hello Windchillers,

 

I would like to know how the growing vault is managed for the backup activity at your site.

With us when we draw a graph of vault Growth vs Days, the graph is going up, if we imagine this for a year, we will have a lot of problem in backup process as the backup process runs for days hampering server performance.

 

Is Vault at your site is split into different drives?. So as to manage backup plan for each drive at different intervals?

 

Thanks,

Shashi

Workflow Comments

$
0
0

I need ideas on how to get comments sent to all participants in a workflow.

 

Example:

We have a doc called Sales Call Report, basically it's a document that is filled out after meeting with a customer.  Then it's routed around to various departments notifying them of the visit and what transpired.  People have been commenting when completing task thinking that the comments are sent to the creator.....but they are not.  I have explained that the comments are viewable only if you go back in and look for them.  Is there a way to have the creator of the document notified if a comment is entered down stream in the workflow?

 

Thanks in advance:

Greg

Positioning Assembly After Component Modification

$
0
0

I'm testing positioning assemblies and do not know if I came across a bug or functionality.

 

I have an assembly set to a Positioning Assembly.  I modify the length of one of the components.  When I go to the viewable for the assembly it shows the component with the new length which is what I expect.  However, it does not move any components that are assembled to that component.  Is this normal functionality or is this a bug?  The component that is not moving is constrained to the component that changed size.

Deny contractor user access to Reports?

$
0
0

Have been asked to set up such that some contractors doing design work in Windchill (who have only needed access via ACLs and group membership) be denied access to run Reports (e.g. from Home, Reports) since most reports are set up to bypass access control. OTB, there is an ACL at Site /System for ReportTemplate, ALL, Read.  Trying to override this with Deny for a certain group at Org level. Deny applied so far in all the usual ways doesn't have the needed effect. Anyone know how to do this?  Tech support case pending. thanks

Search Settings for multiple Released file types?

$
0
0

 

Sorry, but the title is not very good.  The longer version is that we are replacing some AutoCAD files with equivalent Creo files.  As the Creo model and drawing are Released we now have 2 drawings (Creo and AutoCAD) appear in the search results when "Latest version" is the company search parameter.  Manufacturing can only view Released.  If we simply demote the latest AutoCAD drawing to Obsolete, the next most recent Released AutoCAD then appears in the search results.  It doesn't appear that I am able to move all previous Released iterations to Obsolete, and I don't think that is even a good idea, since that would be changing the history of the AutoCAD drawing.  How can we make sure Manufacturing is seeing a single Latest (by date) Released object when there are multiple file types?  I know we cant be the first company to convert one file type to another and need to filter out the old type.  Thanks!

 

Set custom UOM while creating a new Part with using code.

$
0
0

I have custom UOM in Windchill loaded to QuantityUnitRB, but I am not able to create a new Part with custom UOM using code.

 

getting the values via

QuantityUnit[] qu = QuantityUnit.getQuantityUnitSet();

 

but when I set to part, getting null pointer .

 

Has anyone come across this. Please suggest the way to do this.

 

Thank You,


Store Part Inspection Records in Windchill?

$
0
0

Was curious if anyone out there stores Part Inspection records in Windchill?  If so, what has been your experience?  Should these be Reference Docs vs. Describe By docs of a Windchill WT/Part?  Or neither? 

SFTP support for Windchill and Worker

$
0
0

Windchill and Worker can’t support SFTP for the shared file system in 10.1M040, but because of the security transfer reason, we must use this , so let have a vote

Secret/Secure projects

$
0
0

Hi all,

 

I'm looking for some advice on strategies for handling design work in our company that needs to be kept secure/secret from all users except those specified as having permission to access it. Additionally, those people who are given access should only have access for as long as they need it to do their work and then their access should be disabled.

 

I've done some looking into possible solutions like security labels, projects (project link), and using products with "private access". Can anyone in the group chime in on what they've done? What solutions have you implemented and what long term ramifications do I need to be aware of?

 

FYI we are a contract house building automation solutions so we produce large numbers of new designs to release on a yearly basis. Probably on the order of 400+ newly released assemblies each year with an average of 200 unique constituent parts/subassemblies. Rarely do any of these objects get revised once they reach the final released state. I point this out because managing each design in a separate product context may be a challenge. We currently manage all designs in a single context with sub-folders for each machine we're designing. This may play an important roll in a good strategy to handle Secret/Secure projects.

 

Any input you all can offer will be much appreciated.

 

Steve Pikaart

different qty / um for replacement parts?

$
0
0

For Product Structures, we use replacements quite a bit (so far just Substitutes). For the primary part, we use for example: quantity=two, unit=feet for a spool of tubing.  In the replacement part, for this example, the tubing is precut to two feet, and is used as one each. In the replacement part UI, we do not see a field where we can select a different quantity or unit of measure. Is there a Windchill configuration that we can use to allow a replacement to have a different unit of measure and qty from the part that it replaces?

How to make a custom code run on a dedicated MS or BGMS,

$
0
0

Hi,

I am writing an custom application to download the contents from Windchill.

I want to do this on a dedicated Method Server/BGMS.

Earlier I tried with Queues and adding them to groups and then to BGMS.

 

As I am  using Windcholl 10.0Mo30,

What is the better way to achieve this.

 

Thank You,

Avinash Patil

Viewing all 6049 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>