.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

application is faster while SSMS is open !?

Posted By:      Posted Date: September 18, 2010    Points: 0   Category :Sql Server
Hi,  I have my VB.Net 2010 win form app running a job on a table (35.000 rows). I read from an MS-Access Database and, while iterantig on an OleDbDatareader,  I write  to the SQL Server Express 2008R2 using SqlDbCommand.ExecuteNonQuery. A progress bar on the GUI shows the current row. I've noticed that, while the app is running, if I launch the SSMS and I perform an operation (i.e. a simple select on a table) against the same db,  the application goes much more faster. As  I close the SSMS, the application slows down. All this is running on the same PC. In both, application and SSMS, the SQL Server Server Authentication is used (same user). Here is the connection string, stored into the app.config file:   <add name="DB" connectionString="Data Source=localhost\sqlExpress;Initial Catalog=myDb;Integrated Security=False;User ID=myUser;Password=myPass;pooling=False;Connection Timeout=1200;"/> Any idea ? thanks in advance. Francesco

View Complete Post

More Related Resource Links

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

I cannot open application page which i created with Intranet and Internet.

for example, if i create an application portal : test:1000, then it is okay. but when i try to create an application portal: www.e.gov.au with ip address  i have added  www.e.gov.au into host files, but cannot open that page, system just said page not found. i just failed and failed. but when i checked in central admin, it is just fine....   can anybody tell me how to resolve it?   regards

Problem: Sessions got mixed up when open multiple tab for a sigle application

We got a problem that Sessions got mixed up when open multiple tab in a single application. We could change the code that do not use session variable in a that level, but a tons of page need to be modified. We need to find a quick fix for this problem. Is any thing we can do in code level to prevent user open multiple tab in a single application? O any thing we can do to keep its own session for a single tab?

open faster huge list of combobox

Hi All. In detail form I have combobox with some thousand rows. I preloaded collection view of this list in parent form and make equal collection view of parent form to collection view detail form for combobox. But still need wait approximately 5 second when list will open. How to do that list of combobox will open faster. Thanks.

claims authenticated (FBA) user cannot open a connection to our custom application database

We have designed a custom sharepoint site. This site uses a membership provider that I implemented, and the users are stored in our custom application database. These are the steps I follow to reproduce the error: 1. Browse to our site. Select Forms Authentication from the default.aspx selection. 2. Enter in a username from our DB table. This user I have configured as a site collection administrator. 3. Login to the site. The user is authenticated by our membership provider and allowed access (ValidateUser returns true) 4. Browse to a page that attempts to connect to the custom app DB. 5. I get the following error when the page attempts to open a connection to our DB: A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server NOTES: The code that opens the DB connection is running with SPSecurity.RunWithElevatedPrivileges. Our application pool account has access to the database. My user can connect to the database fine as well as the user that our  application pool is running as. I have validated the connection string that is being used in the debugger, and that is correct.

How do I open an application by clicking on a specific document from the list of documents on SP2010



I created my own file type. And I have an application to open this specific file (xml).  In SP2010 created a list of documents and have uploaded this file type on my list of specific documents and up to here everything is working fine. 

But when I click the file from the list of documents that he was open with my software or whether it is possible to synchronize with the file.
My application (WPF Application) is already prepared to receive through "CommandLineArgument" the name and location of the file. If I go to the folder where my file and make double click, my software starts and open the file.
How do I open t

open application in seperate browser when click on SiteMapNode


Hi All,

I want to open application in seperate browser when click on SiteMapNode.

Thanks in advance. 

Unable to open MSDB Folder Under integration services in SSMS. Urgent!!



I uanble to open MSDB folder in under integration services in SSMS. Please help me.

TITLE: Microsoft SQL Server Management Studio

Failed to retrieve data for this request. (Microsoft.SqlServer.SmoEnum)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&LinkId=20476


Client unable to establish connection
Encryption not supported on SQL Server. (Microsoft SQL Native Client)



Open .NET application/website in fullscreen(F11) mode.


When I run my application I want my web browser to open automatically in fullscreen(F11) mode.

Any suggestions?

Client need to open auditing reports in excel application not in browser


Good day,
I encountered with this issue in MOSS 2007. Auditing reports was opened from common SharePoint auditing page.
This page contains hyperlinks to auditing reports.
When any user tries to open this hyperlink, "open file" dialog does not appear, instead of this a IE browser silently open in text XML format.
I suppose that common behaviour is when user open a hyperlink, report will open with excel application through "open file" dialog.
For example, hyperlink in SharePoint contains URL:

SQL file will not open in SSMS on double-click (or jump list)


Hello, all.

I am running SQL Server Management Studio 2008 on a Windows 7 Enterprise machine here at work.  I am not sure when this started happening, but now, for some reason, when I double-click on a SQL file in Explorer, or from the jump list for SSMS (which I have pinned to my Windows 7 task bar), SSMS will open, but will not load the file in question, nor will it bring up a logon screen to connect to a DB.  I tried unassociating the .SQL extension and then re-associating it using "Open With" and it worked the first time (from the Open With), but then immediately reverted back to its old behavior.  Very annoying.

For now I just open SSMS first (which pops up a logon screen and things proceed normally), but that kind of defeats the purpose of having a jump list or a file association.  Has anybody run into this before and can anybody suggest a fix or what's wrong?

Thanks in advance for any wisdom anyone can provide. 

System.Windows.Media.Composition.DUCE.Channel.SyncFlush() error when we open our application in IE 8


Experts, please advice.

I have a WPF application developed using Visual Studio 2008 + DotNET 3.5 + Windows XP - SP 3.We have wrapped Our WPF application in Active X and hosting in IE 6 and it is works fine ,recently we migrated to IE 8 .Actually we are launching our app inside a parent application which is Browser based application(developed in java).

When we launch our app in IE 8 and switching between different modules along with our app in parent application our application is crashing.Pls find below stack trace for the problem.


Exception from HRESULT: 0x88980406
Exception Stack Trace: 

  at System.Windows.Media.Composition.DUCE.Channel.SyncFlush()
   at System.Windows.Media.MediaContext.CompleteRender()
   at System.Windows.Interop.HwndTarget.OnResize()
   at System.Windows.Interop.HwndTarget.HandleMessage(Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Interop.HwndSource.HwndTargetFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)

SQL Server Management Stduio 10.0 (SSMS) Window Menu Listing Open Windows


In SSMS for 2008 the windows menu listing of open files is inconsistent.

When only windows that have previously been saved to a file are opened the Window menus lists as follows:
File Name - Connection (Username(spid)) - This is perfect since the file name is at the front and it's easy to identify a window

However, when an unsaved window is open (typically named SQLQueryX.sql) along with these saved windows the Window menu lists as follows:
File Name - Connection (Username(spid)) - Only for the first (active) window
C:\...\Connection (Username(spid)) - For remaining windows - this is annoying since we can't easily identify the windows by file name

Export to Pdf needs to open in a new window other than the same application



I am using crystal reports 2008 with asp.net 3.5 to generate .pdf reports.

When I use the code below it exports the pdf file in the same application window. I hate this. I have to go back for getting another report.

I want this to be opened in a separate window so that users can still work on input parameter page.

RecDetrpt.ExportToHttpResponse(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat, Context.Response, false, string.Empty);

RecDetrpt.ExportToHttpResponse(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat, Context.Response, false, string.Empty);

I checked out some posts but I didn't get all. Please someone who has gone through this earlier can suggest me code to do this. Thanks in advance.


Double click an associated file type and have it open in your WPF application?


I have a WPF application that does a number of things. When running the app, I can go to File > Open, browse to a file, and open it in the app. Fields on the UI are updated with values from the file and everything works great.

The file I am opening contains binary data and has a custom file extension that is associated with my application. The problem is that if I DON'T have the WPF application running and I double click one of my associated files, it simply opens the application. I would like it to open the application and then load the contents of the file I clicked on. How can I go about doing this?

I have looked into using the Application_Startup event handler in the App.xaml.cs but cannot get the filename when double clicking on it as my StartupEventArgs are empty. However, the sender.ToString from Application_Startup handler returns "MyCompany.MyApp.App". How can I get the filename and go about loading it?

Another thing is that if I put a breakpoint in the Application_Startup event handler and double click my associated file, I never hit the breakpoint. The only way I hit the breakpoint is when I run the application from the IDE. I would like to be able to double click a file, then hit the breakpoint so I can do some debugging.

Thanks in advance.

How to open multiple .sql files in only one ssms instance


I'm pretty sure this almost equal to some question I already read here but did not solved my problem.

Here we go... I'm currently working on a Windows Server 2008 R2 with SQL Server 2008 and SQL Server Management Studio istalled.

When working in Visual Studio with database solution with lot of .sql files I used to double-click on the .sql files and they were opened in the same SSMS instance (if any already opened). Due to a OS error I formatted and reconfigured everything again but now I'm getting a new SSMS instance when double clicking in each sql file. Its really painful one .sql - one SSMS instance so I started my research about that.

What I've tried till now:

1) Right click on the .sql file > "Open With" option > "Add" option > "Program Name: C:\Program Files\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\Ssms.exe" and "Friendly Name: SQL" > "Ok" > "Set as Default". Does NOT work. Still having one sql - one ssms instance.

2) Perfomed Run > regedit > and modify the value data of HKEY_CLASSES_ROOT\sqlwb.sql.9.0\Shell\Open\Command  and replace /dde with "%1". DOES NOT WORK

3) Right click on the .sql file > "Open With" option > "Add" option > "Programe Name: explorer.exe" and "Fri

How to make Excel open in application not browser by default


I'm facing a problem here. I tried the to open an excel file (.xls) which was attached in a Calendar Item.

On 1 PC, it opens automatically with the Excel application and thus the user is able to edit and save.
On another PC, it opens in the browser and the user is unable to edit / save the file.

Initially, I tried and thought that it's user rights issue but apparantly, it is not.

How can I make the .xls to open in excel by default? Can someone help me?

Really appreciate the help and answers.


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