Now that VX releases can run side-by-side, it can be tricky to determine the active/current release. For example, if you double-click a .pcb which version of Xpedition or PADS Layout will it launch in?

 

Further below are a couple of different scripts that can be used to report the currently configured SDD release (see sample screenshot below).

 

 

Script Option #1:

 

This script determines the current release based on the "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\<executable>\eProductDesigner" registry string.

 

Instructions: Copy the lines further below into a file that end with ".bat", and double-click to run.

 

BEGIN script contents (copy content BELOW this line):

 

echo off

 

set DXKEY="HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\viewdraw.exe" /v eProductDesigner

set EXPKEY="HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\ExpeditionPCB.exe" /v eProductDesigner

set PADSKEY="HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\powerpcb.exe" /v eProductDesigner

set PADSPROKEY="HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\ExpeditionPE.exe" /v eProductDesigner

 

REG QUERY %DXKEY%

if %ERRORLEVEL% EQU 0 (

  for /f "skip=2 tokens=1,2,3" %%A in ('reg query %DXKEY%') do msg * "Currently configured release is %%C"

  goto end

)

 

REG QUERY %EXPKEY%

if %ERRORLEVEL% EQU 0 (

  for /f "skip=2 tokens=1,2,3" %%A in ('reg query %EXPKEY%') do msg * "Currently configured release is %%C"

  goto end

)

 

REG QUERY %PADSKEY%

if %ERRORLEVEL% EQU 0 (

  for /f "skip=2 tokens=1,2,3" %%A in ('reg query %PADSKEY%') do msg * "Currently configured release is %%C"

  goto end

)

 

 

REG QUERY %PADSPROKEY%

if %ERRORLEVEL% EQU 0 (

  for /f "skip=2 tokens=1,2,3" %%A in ('reg query %PADSPROKEY%') do msg * "Currently configured release is %%C"

  goto end

)

msg * "No current SDD configuration found!"

 

:end

 

END script contents (copy content ABOVE this line)

 

 

Script Option #2:

 

This script determines the current release based on the file association for .pcb (can be configured for other file extensions on the "set extension=" line in the script).

 

Note: This script assumes the target install folder is one level deep, for example: 'C:\MentorGraphics'. If you've installed 2 or more levels deep, for example: 'C:\Program Files\MentorGraphics', simply increment the "E" in "%%E" near the end of the last line in the script, one letter for each additional level. For example: %%E for one-level deep (C:\MentorGraphics), %%F for 2 levels deep (C:\Program Files\MentorGraphics), and so on...

 

Instructions: Copy the lines further below into a file that end with ".bat", and double-click to run.

 

BEGIN script contents (copy content BELOW this line):

 

echo off

:### set the extension type to check for. Some examples:

:  .pcb for Xpedition or PADS Layout.

:  .prj for xDX Designer.

:  .sch for PADS Logic

:###

set extension=.pcb

 

for /f "tokens=1,2 delims==" %%A in ('assoc %extension%') do for /f "tokens=1-6 delims=\" %%C in ('ftype %%B') do msg * "Currently configured release is %%E"

 

END script contents (copy content ABOVE this line)