design disappear
Could not find type 'DVLD.ctrPersonInformation'. Please make sure that the assembly that contains this type is referenced. If this type is a part of your development project, make sure that the project has been successfully built using settings for your current platform or Any CPU.
2 answers
-
AI answer
The error indicates that the Windows Forms Designer cannot find the type
DVLD.ctrPersonInformationbecause its assembly is not available or not built for the current platform.To fix this:
- Build the project that defines
DVLD.ctrPersonInformation:- In Visual Studio, select Build > Build Solution.
- Ensure the build configuration matches the platform used by the designer (for example, Any CPU or the specific platform mentioned in the error).
- Verify the project reference:
- In Solution Explorer, expand the project that shows the error.
- Under References (or Dependencies), confirm there is a reference to the project or assembly that contains
DVLD.ctrPersonInformation. - If missing, right-click References/Dependencies > Add Reference⦠and add the project/assembly that defines
DVLD.ctrPersonInformation.
- Rebuild and reopen the form:
- After adding/fixing the reference, rebuild the solution.
- Close and reopen the form designer so it can load the control from the newly built assembly.
If
DVLD.ctrPersonInformationis in the same solution but in a custom control project, that project must build successfully before the designer can display it.
References:
AI-generated content may be incorrect. Read our transparency notes for more information. - Build the project that defines
-
Nancy Vo (WICLOUD CORPORATION) 6,025 Reputation points β’ Microsoft External Staff β’ Moderator
Hello @Raneem kamel ,
Thanks for your question.
Base on Windows Forms Designer error page, this error means the control exists in your project's .Designer.cs file, but the Designer cannot load/instantiate it - usually because the assembly hasn't been compiled yet or has a build error.
You can refer to the following steps:
- The designer needs a compiled assembly to find the type. If ctrPersonInformation is in the same project, I suggest building before the Designer can use it.
- Build β Rebuild Solution (Ctrl+Shift+B).
- Then try opening the designer again.
- Clean + Delete bin/obj folders
- Build β Clean Solution
- Manually delete the bin\ and obj\ folders from your project directory.
- Rebuild Solution
- Reopen the Designer
- Verify the namespace & class name match exactly
- Check the error list window for errors inside
ctrPersonInformation.csor its related files. Please fix all errors β rebuild β reopen Designer. - After rebuilding, please close Visual Studio completely. Then, reopen the solution and build before opening any designer.
Please try and let me know if it works. I'd be happy to investigate further.
I hope this addresses your question. If this response was helpful, please consider following the guidance to provide feedback.
-
Nancy Vo (WICLOUD CORPORATION) 6,025 Reputation points β’ Microsoft External Staff β’ Moderator
Hi @Raneem kamel ,
I wanted to check if there are any updates on your side regarding this issue. Please let me know if you need further assistance.
Sign in to comment
