Click here to Skip to main content
15,888,461 members
Home / Discussions / C#
   

C#

 
QuestionHow to delete file on client side using remote object Pin
dephlocus6-Apr-04 23:54
dephlocus6-Apr-04 23:54 
AnswerRe: How to delete file on client side using remote object Pin
Judah Gabriel Himango7-Apr-04 4:06
sponsorJudah Gabriel Himango7-Apr-04 4:06 
GeneralMem Usage Pin
DougW486-Apr-04 23:25
DougW486-Apr-04 23:25 
GeneralRe: Mem Usage Pin
Dave Kreskowiak7-Apr-04 1:35
mveDave Kreskowiak7-Apr-04 1:35 
GeneralRe: Mem Usage Pin
DougW487-Apr-04 1:43
DougW487-Apr-04 1:43 
GeneralRe: Mem Usage Pin
Heath Stewart7-Apr-04 6:13
protectorHeath Stewart7-Apr-04 6:13 
GeneralUserControl and interface implementation Pin
Corneliu Tusnea6-Apr-04 22:28
Corneliu Tusnea6-Apr-04 22:28 
GeneralRe: UserControl and interface implementation Pin
Heath Stewart7-Apr-04 5:46
protectorHeath Stewart7-Apr-04 5:46 
Sounds like a version problem. With .NET assemblies and the CLR, version numbers are VERY important (unlike version numbers with native DLLs, which are basically there for reference and for decent installers so they don't copy over newer versions).

When you work with multiple projects in a solution, you really should not use automatic versioning, i.e. using an asterisk in the [assembly:AssemblyVersionAttribute], typically found in your AssemblyInfo.cs file. The problem seems to be that the version your first project is referencing references one version while the component you added to the toolbox is of a different version.

One other way you can help this is to use a project reference instead of an assembly refernece. When you add a reference to your project (right click, Add Reference...), click on the Project tab and add the project that you want to reference. This establishes a build dependency (making sure that any changes in the dependency prompt a rebuild so the referencing assembly has the latest code) and make sure that the assemblies that are referenced are the correct version.

As far as the toolbox goes, don't explicitly add components to it that you develop and are currently developing in the open solution. Third-party controls and controls that you've build stables version of and deployed should be used there.

VS.NET - though not all the time - will automatically add a reference to any UserControl that you open in the VS.NET designer to the toolbox. If it doesn't, switch to code view, define your field, and instantiate it in the InitializeComponent method that the designer uses. This will make sure it can be designed if you need that sort of thing. You can then continue setting properties and adding event handlers like you normally would on a control using the designer.

 

Microsoft MVP, Visual C#
My Articles
GeneralRe: UserControl and interface implementation Pin
Corneliu Tusnea7-Apr-04 13:26
Corneliu Tusnea7-Apr-04 13:26 
Generaluneable to update an Access database Pin
michael.wikstrom6-Apr-04 22:14
michael.wikstrom6-Apr-04 22:14 
GeneralRe: uneable to update an Access database Pin
Heath Stewart7-Apr-04 4:49
protectorHeath Stewart7-Apr-04 4:49 
GeneralAutomailer Pin
sreejith ss nair6-Apr-04 19:54
sreejith ss nair6-Apr-04 19:54 
GeneralRe: Automailer Pin
Dave Kreskowiak7-Apr-04 1:43
mveDave Kreskowiak7-Apr-04 1:43 
QuestionHow to get the IP of SqlServer? Pin
Member 6449646-Apr-04 19:53
Member 6449646-Apr-04 19:53 
AnswerRe: How to get the IP of SqlServer? Pin
Colin Angus Mackay7-Apr-04 0:12
Colin Angus Mackay7-Apr-04 0:12 
GeneralRe: How to get the IP of SqlServer? Pin
Member 6449647-Apr-04 15:58
Member 6449647-Apr-04 15:58 
GeneralRe: How to get the IP of SqlServer? Pin
Dave Kreskowiak8-Apr-04 3:06
mveDave Kreskowiak8-Apr-04 3:06 
AnswerRe: How to get the IP of SqlServer? Pin
Heath Stewart7-Apr-04 4:42
protectorHeath Stewart7-Apr-04 4:42 
GeneralRe: How to get the IP of SqlServer? Pin
Member 6449647-Apr-04 16:00
Member 6449647-Apr-04 16:00 
GeneralDatagrid Record Numbering Pin
sreejith ss nair6-Apr-04 19:49
sreejith ss nair6-Apr-04 19:49 
GeneralRe: Datagrid Record Numbering Pin
Heath Stewart7-Apr-04 3:52
protectorHeath Stewart7-Apr-04 3:52 
QuestionMicrosoft.DirectX and image ??? Pin
student66696-Apr-04 19:39
student66696-Apr-04 19:39 
AnswerRe: Microsoft.DirectX and image ??? Pin
CWIZO6-Apr-04 20:52
CWIZO6-Apr-04 20:52 
GeneralRe: Microsoft.DirectX and image ??? Pin
Heath Stewart7-Apr-04 3:47
protectorHeath Stewart7-Apr-04 3:47 
GeneralRe: Date Pin
Christian Graus6-Apr-04 19:35
protectorChristian Graus6-Apr-04 19:35 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.