This page handles the issue of missing objects after analyzing DOTNet applications.
Release | Yes/No |
---|---|
8.3.x | |
8.2.x | |
8.1.x | |
8.0.x | |
7.3.x |
RDBMS | Yes/No |
---|---|
Oracle Server | |
Microsoft SQL Server | |
CSS2 | |
CSS3 |
Perform the below actions
Check if the source files for the missing objects are included in the project file
Open the project file in a text editor. Search for lines containing 'Compile Include' directives:
<ItemGroup> <Compile Include="DB2.cs" /> <Compile Include="Oracle.cs" /> <Compile Include="Program.cs" /> <Compile Include="Properties\AssemblyInfo.cs" /> </ItemGroup>
If you find a line as <Compile Include="<file_name>" /> file under examination, then the file should be analyzed and objects should be created. In this case, report your problem to CAST Technical Support with the below relevant input.
If you do not find a line as <Compile Include="<file_name>" /> under examination, then the project file could be either old or corrupt or the file is just not part of the project anymore. There are case where the physical source file location and the same file referenced in the project file does not match. This is case of old/corrupt file, recompile the project in Visual Studio and repackage again, as described in .NET - Confirm analysis configuration
Check if the source file for the expected objects contains a compilation directive such as #if : see example below.
Compilation directive#if FrontOffice namespace Console.UI.Controllers
If there is a compilation directive, then open the project file and check which configuration is selected
CSPROJ<?xml version="1.0" encoding="utf-8"?> <Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup> <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> <ProductVersion>9.0.30729</ProductVersion> <SchemaVersion>2.0</SchemaVersion> <ProjectGuid>{70930E81-00D1-4872-AF72-522085676E8B}</ProjectGuid> <OutputType>Exe</OutputType> [...]
In this example, the Debug configuration is selected.
Check in the same file if the selected configuration includes the compilation directive
CSPROJ<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> <DebugSymbols>true</DebugSymbols> <DebugType>full</DebugType> <Optimize>false</Optimize> <OutputPath>bin\Debug\</OutputPath> <DefineConstants>TRACE;DEBUG</DefineConstants> <ErrorReport>prompt</ErrorReport> <WarningLevel>4</WarningLevel> </PropertyGroup> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> <DebugType>pdbonly</DebugType> <Optimize>true</Optimize> <OutputPath>bin\Release\</OutputPath> <DefineConstants>TRACE;DEBUG;PreproDirective</DefineConstants> <ErrorReport>prompt</ErrorReport> <WarningLevel>4</WarningLevel> </PropertyGroup>
In this case, the PreproDirective constant is defined in RELEASE mode only.
Edit the project file, and :
Either add the PreproDirective constant to Debug configuration, as follows :
Debug mode<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> <DebugSymbols>true</DebugSymbols> <DebugType>full</DebugType> <Optimize>false</Optimize> <OutputPath>bin\Debug\</OutputPath> <DefineConstants>TRACE;DEBUG;PreproDirective</DefineConstants> <ErrorReport>prompt</ErrorReport> <WarningLevel>4</WarningLevel> </PropertyGroup>
Or select the Release configuration, as follows :
Select Release Configuration<?xml version="1.0" encoding="utf-8"?> <Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup> <Configuration Condition=" '$(Configuration)' == '' ">Release</Configuration> <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> <ProductVersion>9.0.30729</ProductVersion> <SchemaVersion>2.0</SchemaVersion> <ProjectGuid>{70930E81-00D1-4872-AF72-522085676E8B}</ProjectGuid> <OutputType>Exe</OutputType> [...]
- Re-analyze after editing the project file. If this does not solve the issue, report your problem to CAST Technical Support with the below relevant input:
Relevant input
- Sherlock export with the following options: Export Logs, Export Configuration files, Export CAST Bases (Management Base and Knowledge Base), source code
- In some cases the IN tables are also needed to investigate the missing object issue. Support will provide specific intructions to execute the following process when this is needed:
- Activate the IN Tables
- Run the Analysis.
- Take Sherlock with the above mentioned options
- Deactivate the IN Tables
Ticket #11801