.net-2.0

maximize a window programmatically

hi i want to maximize a window programmatically so that it cannot be resized once it reaches the maximized state(for ex: maximize the internet explorer and see it), i want to do it. i set FormWindowState property as this.WindowState = FormWindowState.Maximized; this.MaximizedBounds = (x,y); but it doesn't work.how to do this. the...

Is it possible to add an a tooltip for each item that shows up in the autocomplete using c# ?

Is it possible to add an a tooltip for each item that shows up in the autocomplete using c# ? Give complete answer in only c# please ...

System.ValueType Understanding

I tried to create a ValueType. I understand that creating a struct would help me. I also tried to derive a type from System.ValueType which is an abstract class. But I got a compiler error message ".. cannot derive from special class System.ValueType" When I see the metadata of ValueType, it looks to be a regular abstract class. W...

Why am I getting "call to OpenGL ES API with no current context" ?

Hello, I am new to both openGL and android development so please forgive me if my question is very trivial. I am trying to build a simple little app that takes input from the user in three EditTexts representing a 0 - 100% value for each component of a RGB color to be displayed in a GLSurfaceView. The catch is that I need this to use o...

Problem in datagridview

hi, i used datagridview in my project,while double click a particular cell in a datagridview i will create a combobox and put it exactly over the cell,while doing this i got an exception Attempted to read or write protected memory. This is often an indication that other memory is corrupt. and my application gets hanged,how to avo...

Automation error running .NET 2.0 application

We have a client who recieve this error when trying to run our .NET 2.0 application: System.IO.FileNotFoundException: Automation error The specified module could not be found. at xyz.getClass.Setup() The xyz module is a dll written in vb6.0 and should have been installed propertly. The application is running fine on houndrets of o...

Updating MCPD in WinForms from .NET 2.0 to 3.5 - what study materials (MS books) are required/recommended?

For my 2.0 exams it was simple - I just bought the MCPD Self-paced Training Kit which contained the books for exams 70-536, 70-526 and 70-548. But now that I want to update my certification to 3.5 (prior to going to 4.0) via exam 70-566, I can't seem to find what books to buy for studying purposes (besides revising the previous exams). I...

Error 500 - CascadingDropDown AJAX Extender toolkit control

Hi, I am trying to populate 3 dropdown lists with using CascadingDropDown. DDLs shows make, model and color of a car respectively. Data resides in a .xml file. The last DDL is having AutoPostBack = true and I am trying to display the values from dropdown in one label control. I am pulling data from a webservice to populate DDLs. I a...

What would be the RegularExpression for the followings?

I have a nomenclature to respect while performing some tasks against the Active Directory. Here's the nomenclature: TT-EEE-Mnemonic: if TT = 'GA' or 'GS' or 'PA' or 'PF' -> the schema to create is a "group", with a groupScope of Global. LT-EEE-Mnemonic: if T = 'A' or 'G' or 'I' or 'N' or 'P' -> the schema to create is a "gro...

Why is it not possible to catch MissingMethodException?

I have a dependency on .NET 2.0 SP2 in my ClickOnce deployed application (the ApplicationDeployment.CurrentDeployment.CheckForDetailedUpdate(false) method is SP2 only). I would like to check whether SP2 is present during app startup. I have tried to detect this by catching MissingMethodException after calling a SP2-only method. ///...

VS2010: Using COM in a .NET 2 Project

I have a .NET 2.0 project that needs to use a COM component (specifically Redemption). In Visual Studio 2010 I add a reference to the COM dll as I would in all prior VS versions (right click project->Add Reference->COM tab->select product->Ok). When I build and try and run the app I keep getting the following error: Creating an insta...

Refactor to take either NameValueCollection and KeyValueConfigurationCollection as parameter ?

Example code : EDITED : clarified example. Sorry for any confusion. using System.Collections.Specialized; using System.Configuration; ... // get collection 1 NameValueCollection c1 = ConfigurationManager.AppSettings; // get collection 2 ExeConfigurationFileMap map = new ExeConfi...

Keep two-way binding when whole object has changed

I have a class: Public Class TestClass Implements INotifyPropertyChanged Public Event PropertyChanged As PropertyChangedEventHandler Implements INotifyPropertyChanged.PropertyChanged Public Sub OnNotifyChanged(ByVal pName As String) RaiseEvent PropertyChanged(Me, New PropertyChangedEventArgs(pName)) End Sub P...

.NET Framework version

I have an app that was created using .net Framework 3.5. However, I now need to change this to use the 2.0 Framework, as it needs to be distributed to a Windows 2000 machine. Will simply changing the Application Target Framework on the project properties be sufficient to do this? ...

Risk of migrating website from .NET 2.0 to .NET 3.5

What are the inherent risk of upgrading a website from the 2.0 framework to the 3.5 framework? I know the features given to me in the upgrade, just curious if there are any known issues that may pop up when upgrading. I.E. Function X used to behave this way, and now behaves a new way. ...

Most maintainable method to share code between multiple projects

Given multiple websites all running the same sourcecode, what's the best/most maintainable way to organise these into projects within visual studio? For example, say we have websites Red, Blue, and Green (etc). Their HTML may be different, but they are a functionally the same. Previously in one solution we have created one project Col...

How to use reflection to unit-test an internal (Friend in VB) class within an assembly, when the InternalsVisibleToAttribute is not an option?

I have a solution with two projects within: Company.Project.vbproj Company.Project.Tests.vbproj Within the Company.Project.vbproj assembly, I have a class FriendClass.vb which scope is Friend (internal in C#). Now I wish to test this FriendClass.vb from within the Company.Project.Tests.vbproj assembly. I know about the InternalsVisib...

Difference between EventLog.WriteEntry and EventLog.WriteEvent methods

I tried using WriteEntry and WriteEvent methods of EventLog class. EventLog.WriteEntry("Saravanan", "Application logs an entry", EventLogEntryType.Information, 2, 3); EventLog.WriteEvent("Saravanan", new EventInstance(2, 3), "Application logs an event"); Both output the same result. Is there any difference in usage of these methods?...

How to create Auto Hide Tab?

Hi Friends, I am working on an Window application using VS 2005. here i have a scenario where i have to create a Docked window that auto hide like our 'Solution Explorer' or 'Property Window' in VS. I have not find that such control in VS. Please, sugges where i can find this docked control. ...

Monitoring a folder for new file creation without using FileSystemWatcher in .net

Hi I have to create a windows service which Monitors a specified folder for new files and does someprocessing on it and moves it to other location. I started with using FileSystem Watcher. But my boss doesn't like FileSystemWatcher and wants me to use polling on Timer or any other mechanism other than File System Watcher. I am confus...