[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

UserControl

Posted on 2006-03-28
1
Medium Priority
?
293 Views
Last Modified: 2010-04-16
Is it possible to add an user control to my project (For ex: MyControl.cs : Control) without an .resx file. i.e. if we look as the MyProject.csproj file I want MyControl.cs to have s subtype of 'Code'.

We want a control that is derived from Control, but is built at runtime, so we don't need designer support.  However, whenever we choose ReBuild Solution, Visual Studio automatically changes SubType to "UserControl" and then complains that there is no .resx file.
0
Comment
Question by:sreenaths
1 Comment
 
LVL 5

Accepted Solution

by:
RoninThe earned 100 total points
ID: 16325128
open your .csproj in notepad. delete the lines where it references MyControl.resx. and never open MyControl.cs in designer.

AFAIK, Visual Studio won't create .resx till you don't open it in designer, even if its subtype- usercontrol.

try this, add a blank code file to the project, copy MyControl.cs code in it, and remove MyControls.cs. In all probability it should work.

0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
Hello there! As a developer I have modified and refactored the unit tests which was written by fellow developers in the past. On the course, I have gone through various misconceptions and technical challenges when it comes to implementation. I would…
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…
Look below the covers at a subform control , and the form that is inside it. Explore properties and see how easy it is to aggregate, get statistics, and synchronize results for your data. A Microsoft Access subform is used to show relevant calcul…
Suggested Courses

872 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question