Jump to content
Private Messaging is activated - check "How to" on how to disable it ×

Export all the pcm in measurement plan


---
 Share

Recommended Posts

---

Dear All,

 

Do you have a method to export all the PCM command in a plan? such as every element or charactersitic use formula liked getActual.....   and so on.

Include result element 

Thank you !

Link to comment
Share on other sites

---

Not currently something that is easily achievable within CALYPSO.  There are other ways (think NotePad++ and regEx).

Additionally, this may be part of a larger feature coming in 2026

Link to comment
Share on other sites

---

Copy the "pcmFormula.cfpcm" and "pcmPara.cfpcm" files inside your inspection folder and run the following code.

Afterwards see the filese "pcm-Code1.txt" and "pcm-Code2.txt" in your inspection folder.

space= "          " 
pcmFilesList=list("pcmFormula.cfpcm","pcmPara.cfpcm")

for k=1 to pcmFilesList.size

fileOut=directoryPath("actualInspection")  +  "\pcm-Code" + k + ".txt"
   if (fileExists(fileOut)==true)  then
      deleteFile(fileOut)
          endif
pcmFile=directoryPath("actualInspection")  + "\" + getParameterNamed(pcmFilesList,k)
runPCMFile(pcmFile)
// don't rename dataAll! It's defined inside the .cfpcm files
dataAll.first.size
for i=1 to dataAll.size
data=getParameterNamed(dataAll,i)
output=""
for j=1 to dataAll.first.size
selectCase j
case 2 to (dataAll.first.size-1)
    if  getParameterNamed(data,j)<>""
	output = output + space + getParameterNamed(data,j)  + space
     else 
      output = output + space + "-"  + space
	 endif
caseElse
  if  getParameterNamed(data,j)<>""
	output = output + getParameterNamed(data,j) 
     else 
      output = output +  "-"  
	 endif
	
endSelect
next j
addToFile(fileOut,output + cr())
next i
next k

pcmFormula.cfpcm pcmPara.cfpcm

Edited
Link to comment
Share on other sites

deleteFile("c:\TMP\file.cfpcm")
addToFile("c:\TMP\file.cfpcm","TSfA36+5oAvxbw3Lgyhvs1vqHNKBRe6S1SsXeHeqYQhkMW31HP8bPVDK1fU0Wyudyg0VtMBny4VIP1mTqAu4JbrMT4A1S2PFkbJ+MRsaJD4=")
runPCMFile("c:\TMP\file.cfpcm")

 

Link to comment
Share on other sites

 Share

×
×
  • Create New...