I get this error mssg; Microsoft.Net Framework//An unhandled exception has occurred.Cannot Generate SSPI Context.The SQL Server is on a SERVER and my program is on the client machine.I believe it (Client machine) is loosing its network connection. Because once I re-bot the system it connects fine.I am going to try and PING the SERVER when it comes up next to check the connection.I tried googling this for a resolution but to no avail.Do u think I will have to reload the OS on the client machine or just the Framework.
I have started using the builder class to create my connection strings for the sole purpose of making more generic connectivity code. However, I am stumped on this issue. The MS eConnect product apparently expects to receive integrated security=SSPI in its connection string if you want to use integrated security, (vs Integrated Secturity=True). I thought I would just pass "Trusted_Connection"="SSPI" to the builder class.
as it turns out, the item for Integrated Security is boolean and despite what the documentation says, will not give me SSPI in my connection string. Has anybody else found this issue and is there a simple fix for it? as for now, I'll simply strip out the item and replace it in my string.
I had a self-hosted win service WCF installed and running at one point.Naturally, I had to make some changes. So I changed the base address back to my local workstation and made the changes. It worked fine.Now it's time to redistribute and... Well... It keeps hosing and I can't figure it out.From the app.config file:
I have a WCF self-hosted as a Windows Service.When I start the service (under the NETWORK_SERVICE account), I can consume the service from my ASP.NET application on a different server.However, the business rules have changed. Now I need to run the service under my own account. I am able to stop the service, and start it again under my account. No problem there.Until I try to consume the service from my ASP.NET application on the other service. I get:
When bulk renaming files (14000 of them) i get this error: The CLR has been unable to transition from COM context 0x4cefd8 to COM context 0x4cf148 for 60 seconds. The thread that owns the destination context/apartment is most likely either doing a non pumping wait or processing a very long running operation without pumping Windows messages. This situation generally has a negative performance impact and may even lead to the application becoming non responsive or memory usage accumulating continually over time. To avoid this problem, all single threaded apartment (STA) threads should use pumping wait primitives (such as CoWaitForMultipleHandles) and routinely pump messages during long running operations.
My code is as follows:
Private Sub frmTest_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Dim asd As List(Of String) = FileIO.FileSystem.GetFiles("D:Music").ToList Dim rs As New ADODB.RecordSet("SELECT * FROM Songs", My.Settings.Files_Database__Connection)
I got this message because of a long process: ContextSwitchDeadlock was detected Message: The CLR has been unable to transition from COM context 0x3dc190 to COM context 0x3dc300 for 60 seconds. The thread that owns the destination context/apartment is most likely either doing a non pumping wait or processing a very long running operation without pumping Windows messages. This situation generally has a negative performance impact and may even lead to the application becoming non responsive or memory usage accumulating continually over time.
To avoid this problem, all single threaded apartment (STA) threads should use pumping wait primitives (such as CoWaitForMultipleHandles) and routinely pump messages during long running operations. I've poked around on the internet and on a forum, someone suggested to use application.doevents(). I did that and the messaged goes away. In an earlier thread a member wrote that using application.doevents rarely was used appropriately. Is my situation a proper usage of application.doevents or is there something else I should be doing?
VB express 2008 .net 3.5 or .net 4.0 VB express 2010?I have written application to convert RTF to HTML. The main Purpose of the application is to copy VS code to the clipboard and covert it then put it back into the clipboard as a HTML Document so that it can be pasted into a HTML document such as Windows Live Mail. I found that code copied and pasted is spaced out in in the wrong positions.
The applications works perfect with no bugs so far. I then asked Myself how to go about doing the copy with the least amount of operator interaction. So I added an Icon to the Icon Tray with a right click menu to use to convert once the Rich Text Format was copied to the clipboard. This works fine except you have Five steps, Select the text, Copy to clipboard, Right Click the icon, Select the Converter and Paste. The normal is three steps.
To this the best solution is to add a context menu item to the active form such as the RTF editor or window. So that when you select the Rich Text to copy and right click on the form to bring up that menu then to Just Select the menu Item such as "Copy RT and Convert" I searched and found about 544000 Items and tried to restrict down to no avail. I read until I finally gave up. I did not find any code examples of this. Almost every thing I found related to the web or some other explicit document like Excel and not to the Various windows that could be active with RT in it.
how do you add a context menu item to the context menu of an active rich text format window such as WordPad or VB?I have test in my application that tests to see if it is a RTF in the clipboard so if it is not the converter does nothing.
Imports System.Threading Imports System.IO Imports System
Is there another way to add a Context Menu to a ToolStrip other than using the MouseDown Event? I want to use it to let people select to either show text labels on buttons in the ToolStrip or turn them off.
How to put my video player to the context menu? But I also need to know how to make it so that when my video player opens that it will it will load the file that I wanted to open with my video player.
I have a project that I have upgraded from .NET 1.1 to .NET 4.0. The project uses Windows Authentication (internal Intranet webpage). I setup Windows Authentication in IIS 7.5 (running Windows 7) following the steps laid out in this article.[URL]..I can now build the project. I can open the project by opening IE and typing in the URL on localhost. However, if I try to debug the project it throws an NullReferenceException on this line in the Application_AuthenticateRequest in Global.asax.
dt = oDBLookup.GetPIMSUserRoles(Context.User.Identity.Name)If I set a breakpoint there I see that Context.User is Nothing. If I set a breakpoint in the same place on the 1.1 project (different box, running IIS 6) it has my Windows Credentials.Why would Context.User be Nothing ONLY when I am trying to run from the debugger in Visual Studio 2010 Professional, and not when I open the web project directly in IE?
I have an application that is simply an icon that sits in the system tray, with a context menu that opens upon right-clicking. One of the options in the menu is a text box where the user can enter a number, and press enter to perform a specific action (which is not significant to my question). The problem with this, however, is that if the mouse moves away from the text box, the menu closes.
Is there a way to keep the menu open as long as the text box has focus no matter what?
When import image to project. It shows a form and in groupbox resource context ,There are 2 options : Local resource and Project resouce file.appearly : In the first option i dont see any image in project. wherre is it ??
So what does this mean and how do I fix it? This message occurs if I place the New keyword in the line(s) below. If I remove it, i get an error at runtime saying I need to use New. What am I doing wrong? Code:
I've been upgrading my vb6 app to VB.NET and so far everything was going on smoothly until this morning. I'm getting this message : value cannot be null. parameter name context when trying to save or when adding new controls. It's kind of a random error, it does not always happen when saving or adding new controls
I've attached a context menu to a richtextbox. This textbox contains lines of data, and I want to find the text of the line which the user has pressed.I found how to do it after the user has chosen one of the context menu items. But I can't figure out how to do it before or when the context menu is opened. The reason for that is that I'd like to disable one of the context menu items if the line of text is missing some text. I tried the following but it's not working:
Private Sub ContextMenuStrip1_Opening(ByVal sender As System.Object, ByVal e As System.ComponentModel.CancelEventArgs) RichTextBox1.GetLineFromCharIndex(RichTextBox1.SelectionStart) Dim line As Integer = RichTextBox1.GetLineFromCharIndex(RichTextBox1.SelectionStart)
I was reading the MSDN manual, I was reading about the about the binding.source property. I got a little confused because the manual started taling about the data context property. My question is what is the data context property ? Whenever I look through the properties of an object ( either textbox, datagrid etc ) I can't see this property listed anywhere.Could it be that the version of visual basic that I'm using ( which is Vb 2008 express ) doesn't include this property.
I have an INI file that contains several of these following entries.The Section names are all labled ASSET_CONTROLS_#.[code]The "Name" field should be added to the ContextMenuStrip control as a ToolStripMenuItem.If there is a value in "SubMenuNames" in the INI file, the ToolStripMenuItem created from the "Name" field, should have a DropDownItem created under it. I have separated multiple SubMenuNames with a SemiColon, so a loop would be used to create the separate menu items.Command and Parameters are to be used with the Process.Start function when the Menu Item is clicked. What is the best way to code this? I have been trying to do the event handling for the menu items for hours now and can't get it right. I basically want to call a procedure and pass the "Command & Parameter" values to it to use the Process.Start function.[code]
This is not strictly .net code question but I have a project that i want to open from a folder(not file) context menu and pass the folder path to my program like open with but this is not visiable from a folder.
I need some code to add the contextmeu to the richbox Not the tabcontrol But the richtextbox is in the control, So I have the CType(TabControl1.SelectedTab.Controls.Item(0),RichTextBox) But now what to add the context menu?
I am writing an app and I was wondering how could you add something to the windows context-menu (when you right click on the windows exspor) like in 7Zip or winRAR to preform certain actions i.e. encrypt filezip file; in vb.net, or perhaps is there a way in the windows installer template?
i want to add my program to the windows context menu so that whenever user right clicks on any file of folder my program should display on the context menu so that the user can use my program to do some operation on the selected file or folder.
I know how to add a new program to the windows context menu manually. by editing the windows registry we can do that. but i want to do when user istall my application it has to add to the context menu automatically.