error in my design
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
-
Danny Nguyen (WICLOUD CORPORATION) 7,185 Reputation points • Microsoft External Staff • Moderator
Hi @Raneem kamel ,
I noticed this looks similar to your earlier post: error in my design - Microsoft Q&A
In that thread, I suggested checking whether
DVLD.ctrPersonInformationcan be found by the Windows Forms Designer at design time. Based on the Windows Forms designer troubleshooting documentation, this error usually happens when the required type or assembly reference cannot be found, or when the project containing the control has not been built successfully. The doc also suggests cleaning and rebuilding the project/solution, and deleting thebinandobjfolders if needed.Could you confirm whether you already tried the earlier suggestions?
- Make sure
DVLD.ctrPersonInformationexists in the expected namespace. - Make sure the project or assembly that contains this control is referenced.
- Make sure the full solution builds successfully.
- Try Clean/Rebuild.
- If needed, close Visual Studio, delete the
binandobjfolders, reopen the solution, and rebuild. - Check whether the control was renamed, moved, or had its namespace changed.
If you already tried these and the issue still happens, please share the result of each check, especially whether the full solution builds successfully and where
DVLD.ctrPersonInformationis defined. With that information, I can suggest the next troubleshooting steps.Hope to hear from you soon. I would greatly appreciate it if you could follow this guidance or provide feedback.
Thank you.
-
Danny Nguyen (WICLOUD CORPORATION) 7,185 Reputation points • Microsoft External Staff • Moderator
Hi @Raneem kamel , just checking in. Did my answer help with your problem? Feel free to reach out if you need any help.
-
Danny Nguyen (WICLOUD CORPORATION) 7,185 Reputation points • Microsoft External Staff • Moderator
As we haven’t heard back from you for a while, we’ll go ahead and close this thread for now.
If you still need assistance later, feel free to reach out.
Thank you for your understanding.
Sign in to comment - Make sure
-
AI answer
The error indicates that the Windows Forms Designer cannot locate the type
DVLD.ctrPersonInformationat design time. This is treated the same as “The type '<type name>' could not be found” / “Could not find type '<type name>'” in the designer.Use these steps:
- Build the project that contains
DVLD.ctrPersonInformation- In Visual Studio, select Build > Build Solution.
- If
ctrPersonInformationis a custom user control in the same solution, it must compile successfully before the designer can load it.
- Check project references
- If
DVLD.ctrPersonInformationis in another project (for example, a class library), open Solution Explorer, right‑click References (or Dependencies) of the form project, choose Add Reference…, and add a reference to the project or assembly that definesDVLD.ctrPersonInformation. - Ensure any assemblies that
DVLD.ctrPersonInformationdepends on are also referenced.
- If
- Verify the type name and namespace
- Open the code file where
ctrPersonInformationis defined and confirm its namespace isDVLDand the class name is exactlyctrPersonInformation(including case). - Open the
.Designer.csfile of the form that uses this control and verify the fully qualified name matches the actual namespace and class name.
- Open the code file where
- Confirm platform/target settings
- Make sure the project that defines
DVLD.ctrPersonInformationand the project that uses it are built for compatible platforms (for example, both Any CPU, or both x86). Then rebuild the solution.
- Make sure the project that defines
- If the error persists only in the designer
- Clean and rebuild the solution.
- Close and reopen the form designer after a successful build.
If
DVLD.ctrPersonInformationwas removed or renamed, update or remove the references to it from the form’s designer code.
References:
AI-generated content may be incorrect. Read our transparency notes for more information. - Build the project that contains
