.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

C++ Q&A: Sizing Windows for Text Strings, Creating Nonrectangular Windows, Activating an Open Docume

Posted By:      Posted Date: August 21, 2010    Points: 0   Category :ASP.Net

More Related Resource Links

Text Rendering: Build World-Ready Apps Using Complex Scripts In Windows Forms Controls


The System.Windows.Forms.TextRenderer class provides support for complex scripts in Windows Forms controls so you can render text the way you want and support international locales.

Miguel A. Lacouture

MSDN Magazine March 2006

Windows UI: Our WinMgr Sample Makes Custom Window Sizing Simple


Programmers using Visual Basic have always had an advantage over C++ programmers when it comes to component and window sizing. There are many third-party Visual Basic-based solutions to this age-old problem, but unfortunately, there are few elegant alternatives for the C++ crowd, short of using a full-fledged windowing toolkit. This article explains how to circumvent the tedious task of hardcoded pixel arithmetic. It starts by introducing a window sizing rules system, and then moves on to show how CWinMgr, a data-driven class, can intelligently manage an MFC application's window sizing.

Paul DiLascia

MSDN Magazine July 2001

Open With Windows Explorer very slow


I am trying to troubleshoot an issue where some users of our SharePoint environment have problems using the open with windows explorer option in a document library.


For some users this works fine...  the explorer opens quickly and they can manage the documents.


For other users it takes up to 5 minutes before the explorer view opens.  During this time the browser becomes completly unresponsive.


As part of the troubleshooting process I tried taking the UNC path that is shown in the explorer view and tried using the Start -> Run and then entering in the path.   This seems to cause the complete desktop to freeze until the explorer window displays.


This is occuring on Windows XP SP Pro SP2 with both IE6 and IE7.   The desktops are on the same domain as the SharePoint servers.


Any thoughts on next steps?

Open a windows application form names in another

Hi, Now i am in a horrible situation. I want to create an application for open another application(exe) and display all the form names in newly opened application in a compobox.If we selected a compobox item,ie;a form name in new application opened,i want to display all the control names in that form... is it possible? we can do it in same application.but how can i do it in another application? thanks in advance   Anoop

Wickedly Strange .Net WPF Performance Problem Dissapeers with Windows 7 Performance Monitor Open

Hello Everyone, I have been developing one large and complex WPF application for 13 months now, all is going well and especially tonight as I now have some sort of clue or hint to what I have been seing now for quite some time.  Here is the rundown. 1) Running on i5 processor with 4GB RAM and Windows 7 2) The application was developed all in .Net 4.0, WPF C#. 3) It is heavily GUI intensive and also uses Entity Framework Detached for Database Access. 4) Is multi-threaded / multi-tasking. I am a nutcase when it comes to testing.  Since my graphical application heavily depends upon performance and determinsm (please somebody don't start with the C++ vs .Net on here) and has been performing great FOR THE MOST PART.  Every once in a while, I see that the application runs into the weeds for 5 or 6 seconds and the interface is unresponsive.  I have this thing tuned finely too.  Well now toward the end of development I have finally had to face that bug so to speak.  I can force it by clicking spastically on my buttons causing an event storm and making the system update the GUI.  SO!  Great start, I can now cause the problem on a regular basis (for you youngsters that is actually a good thing)!  Alright, so I start with the easiest investigative tool, CNTRL - ALT - DEL into Windows 7 Performance Monitor.  As you can tell from

Cash Drawer - Method Open threw an exception - Windows Service

Hi All, I'm getting the following exception while calling Open method of Cash Drawer object. Method Open threw an exception.  Could not read the device name key's default value, or could not convert the Programmatic ID it holds into a valid Class ID. Code:   class Class1 { CashDrawer _uniCashDrawer1 = null; DeviceInfo cashDrawerDevice1 = null; PosExplorer posExplorer = new Microsoft.PointOfService.PosExplorer();   public void ClaimCashDrawer() { cashDrawerDevice1 = posExplorer.GetDevice("CashDrawer", "testDrawer"); if (cashDrawerDevice1 != null) { _uniCashDrawer1 = posExplorer.CreateInstance(cashDrawerDevice1) as CashDrawer; if (_uniCashDrawer1 != null) { _uniCashDrawer1.StatusUpdateEvent += new StatusUpdateEventHandler(UniCashDrawer1_StatusUpdateEvent); _uniCashDrawer1.Open(); _uniCashDrawer1.Claim(0); _uniCashDrawer1.DeviceEnabled = true; } } } }   Tha above code works fine if you put the code in WindowsApplication in all POS systems. The same is working if you put the code in Windows Service in all other POS systems. The same is not working if you put the code in Windows Service in Aures Galeo POS systems.  Thanks in advance. Ramakrishnan S

Error trying to open WPF Xaml windows from Visual Studio 2010 in Blend 4

Hi I have Visual Studio 2010 ultimate, and expression Blend 4. I have created a WPF 4 project in Visual Studio and when i try to open the MainWindow.xaml file in Expression Blend 4 - i get an error stating that the file or folder is not a valid blend project. Is there something i need to install for visual studio to make blend able to edit WPF Xaml files in Blend 4? I can open blend4 and create WPF applications with no problem - its just trying to open a mainwindow.xaml created in Visual Studio 2010 in blend 4 when i get the error. I am running windows 7 32 bit. Cheers Rod. Mono / DotNet Rocks!

how to open 2 different windows from different buttons with window.open or...

Hello, I'm trying to open 2 different windows from different buttons with window.open Do not manage... Annyone  who knows how? I need code xample...   Is it posible to set ID for this window.open ?   Thanks

Text in code windows became very blur

I do remember what I did but text in code windows became very blur. Another screens such as option, solution explorer are still very clear. How to fix it? I tried to reset to reset all setting but no luck.I do remember what I did but text in code windows became very blur.Another screens such as option, solution explorer are still very clear.How to fix it?I tried to reset to reset all setting but no luck.

Get control over the other open windows to avoid resizing them

Hi, I am developing C# WinForms application. I need to have control over the other open windows to avoid resizing them. If a user try to resize the open document say myDocument.doc, i.e., word file, then i should avoid resizing that window and set back to its previous size. I can get the Windows handle and Process ID and the File path of that document as well. Will any of these help me to solve my problem? Thanks for the help in advance. ViVidyadhar - V the destiny

Windows 7 window.open() and - target issue



In Windows 7 when I use window.open(url, "_MyWindow") a new browser window opens every time I click.

Expected behaviour is - URL is replaced in the browser window with the same target attribute (_MyWindow) if it's already open.

Any suggestion/workaround is greatly appreciated.

All works fine in any other OS/IE config, even on XP/IE8.




same issue appears using <a href=http://www.microsoft.com target="_MyWindow">Open link</a>

Access Denied creating a web application in SP Foundation 2010 installed on windows 7 with local acc



I've installed SharePoint foundation over windows 7 with a local account using this guide: http://sharepoint.microsoft.com/blogs/fromthefield/Lists/Posts/Post.aspx?ID=112

When I try to create a new web application the ribbon button is disabled. Using the link located in /_admin/createsite.aspx I get an "Access Denied" error message.

I access the SP Administration with the same user used during installation. This user is local admin and member of SQL server roles "securityadmin" and "dbcreator".

Any idea about this error?


Thanks in advance

How should an SQL statement refer to a Text field value on a Windows Form Application?


In a WindowsFormApplication, I have a form that contains an MS Office Spreadsheet (an Office Web component).  The data source of the spreadsheet is  an Oracle table which is referenced in an SQL statement  - for example, the following works fine: 


I've now added a Text field (TextBox1) to the form and would like to have the SQL statement refer to the value of this field.  I've tried various syntaxes, including the following::


This generates an error (ORA00904: "HOST: invalid identifier)

I've also tried the following: 


This generates an error (ORA00904: "FORM1"."TEXTBOX1"."VALUE": invalid identifier)

I'd appreciate any ideas on what the correct syntax should be in referring to the Text field or whether or not this is even possible.


Cannot open Microsoft Expression Studio 4 using Windows 7 Ultimate


I run Windows 7 Ultimate and I purchased the academic version/pricing of Microsoft Expression Studio 4 - I have it installed but when I try to open it I get windows is searching for a problem the error reads:

Microsoft Expression Web 4 has stopped working. A problem caused the program to stop working correctly. Windows will close the program and notify you if a solution is available.

Then I removed and reinstalled the product and still got the message.  I have .NET Framework 4  and Silverlight 4 installed as well.  I have already tried live chat and they sent me to this forum section.  I have a Dell Studio XPS with a full set of amenities - lots of Ram, hard drive space, etc.  Any help or suggestions are greatly appreciated - I'm in the need for a fast fix as work is piling up.   Thanks so much,

traveling librarian

Is there a way to disable the Open in Windows Explorer option for a single document library (SP2010)

I am looking to disable the Open in Windows Explorer option for a single document library (SP2010). Can someone help me with this?

Open a powerpoint presentation in a panel in windows forms


Dear All,

I have a problem of opening a powerpoint presentation in my window form's panel! i don't want to display the  presentation on the whole screen instead in a panel or other window forms control.

Any help would be greatly appreciated.

Thanking You. 

Trying to open a sharepoint library in Windows Explorer via IE 8 results in the error "your client d


I am attempting to connect to a Microsoft Sharepoint library, via the "Actions -> Open in Windows Explorer" option from the Sharepoint page.  When I do so, I get the error message "your client does not support opening this list with windows explorer".  In short, I am trying to get the "drag and drop" functionality of a Sharepoint library.

I am running Windows 7 64-bit and IE8.  The target Sharepoint environment is a MOSS 2007 EE.  My Windows "WebClient" service is running, and I have no problem connecting to this exact library via a Windows XP computer running IE8.

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend