几何尺寸与公差论坛

 找回密码
 注册
查看: 269|回复: 2

PR 246973 GD&T Dialog inserts invalid Total Runout command into part

[复制链接]
发表于 2008-8-3 20:49:06 | 显示全部楼层 |阅读模式
<< Larry Clark  --  03/02/07  15:37:29>>
An invalid total runout command can be inserted into a part program.  Attempting to execute the command produces an invalid input error dialog.

Steps to reproduce:
1) Open attached part program (runout.prg) and go to the end of the program.
2) Insert | Dimension | Runout | Total...
3) In FCF editor, click on the datum 'D' and change it to [X] (that is, no datum selected);
4) In the Features group, click on CYL1, then click on AXIS_CIR2;
5) Click the Create button;
6) In the resulting 'Datum reference frame error dialog' click OK;
7) In the FCF editor, click in the datum area and select datum 'D', then click the Create button;
8) In the resulting dialog 'Invalid Input'  'RNOUT2 The first item for total runout must be the name of a cylinder, cone, or plane.  Click the OK button;
9) Click the Close button in the GD&T dialog;
 楼主| 发表于 2008-8-3 21:00:18 | 显示全部楼层

回复: PR 246973 GD&amp;T Dialog inserts invalid Total Runout command into

<< Don Turcotte  --  03/05/07  14:52:17>>
There were two issues here :  
1.  Not all the features selected were checked for validity.
2.  Invalid features should not be in the features list to begin with.
Fixed in V42 beta and V43B.

Files inserted to server
------------------------
V42\DIMENS\FEATCTRLFRMUTIL.CPP
V42\INCLUDE\FEATCTRLFRMUTIL.H
V42\MENU\FEATCTRLFRMDLG.CPP
V43B\DIMENS\FEATCTRLFRMUTIL.CPP
V43B\INCLUDE\FEATCTRLFRMUTIL.H
V43B\MENU\FEATCTRLFRMDLG.CPP
<<END>>

// PR246973
BOOL IsConeTypeFeature(CPCDcommand * pFeature)
{
  BOOL bStatus = FALSE;
  if ( !pFeature )
    return bStatus;

  int typ= pFeature->feature();

  switch(typ)
  {
  case F_CONE:
    bStatus = TRUE;
    break;

  case F_SET:
    {
      if(pFeature->type() == CONST_SET)
      {
        int iNumSetFeat= pFeature->get_num_inputs();
        CPCDcommand ** pSetFeatures= new (CPCDcommand * [iNumSetFeat]);
        pFeature->get_inputs(pSetFeatures);

        for( long jj = 0; jj < iNumSetFeat; jj++ )
        {
          bStatus = IsConeTypeFeature( pSetFeatures[jj]);
          if(bStatus) // PR232338
            break;
        }
        delete []pSetFeatures; // sab 10-may-2005
      }
    }
    break;
  }

  return bStatus;
}
 楼主| 发表于 2008-8-3 21:05:23 | 显示全部楼层

回复: PR 246973 GD&amp;T Dialog inserts invalid Total Runout command into

case ID_INSERT_DIMENSION_TOTAL_RUNOUT:
    if(featType == F_CONE || // PR246973
      featType == F_CYLINDER || featType == F_PLANE)
      bReturn = TRUE;
    break;
  case ID_INSERT_DIMENSION_CIRCULAR_RUNOUT:
    if(featType == F_CIRCLE || featType == F_CONE || // PR246973
      featType == F_CYLINDER || featType == F_SPHERE)
      bReturn = TRUE;
您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|Archiver|小黑屋|几何尺寸与公差论坛

GMT+8, 2024-12-23 05:14 , Processed in 0.037918 second(s), 19 queries .

Powered by Discuz! X3.4 Licensed

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表