From: peter on

I am working on a win form C# application. I am using visual studio 2005,
..net 3.5, SQL Server 2005 Express. Windows XP sp3.
when the application starts and executes at the command of databaseNotSet =
_dirSettingTableAdapter.Fill(_filesDatabase.DirSetting) == 0;
DirSetting is a table in the database (fileDatebase), I got the error:
"Cannot generate SSPI context."

This error almost persistant, occationally it works several times then
stopped working agan.

Thanks a lot.

Peter

I copied the StackTrace here:
" at System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection
owningObject)\r\n at
System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection
owningConnection)\r\n at
System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection
outerConnection, DbConnectionFactory connectionFactory)\r\n at
System.Data.SqlClient.SqlConnection.Open()\r\n at
System.Data.Common.DbDataAdapter.QuietOpen(IDbConnection connection,
ConnectionState& originalState)\r\n at
System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[]
datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand
command, CommandBehavior behavior)\r\n at
System.Data.Common.DbDataAdapter.Fill(DataTable[] dataTables, Int32
startRecord, Int32 maxRecords, IDbCommand command, CommandBehavior
behavior)\r\n at System.Data.Common.DbDataAdapter.Fill(DataTable
dataTable)\r\n at
ClinicalComputers.CCOS.DocumentManagement.FilesDatabaseTableAdapters.DirSettingTableAdapter.Fill(DirSettingDataTable
dataTable) in
D:\\DotNet\\CCOSNet\\DocumentManagement\\DocumentManagement\\FilesDatabase.Designer.cs:line
5325\r\n at SimpleDocumentManagement.MainForm.LoadDirectorySetting() in
D:\\DotNet\\CCOSNet\\DocumentManagement\\DocumentManagement\\MainForm.cs:line
348\r\n at SimpleDocumentManagement.MainForm.MainForm_Load(Object sender,
EventArgs e) in
D:\\DotNet\\CCOSNet\\DocumentManagement\\DocumentManagement\\MainForm.cs:line
243\r\n at System.Windows.Forms.UserControl.OnLoad(EventArgs e)\r\n at
ClinicalComputers.CCOS.Common.UI.BaseUserControl.OnLoad(EventArgs e) in
D:\\DotNet\\CCOSNet\\Source\\Infrastructure\\Infrastructure.Module\\UI\\BaseUserControl.cs:line
44\r\n at System.Windows.Forms.UserControl.OnCreateControl()\r\n at
System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)\r\n at
System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)\r\n at
System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)\r\n at
System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)\r\n at
System.Windows.Forms.Control.CreateControl()\r\n at
System.Windows.Forms.Control.OnVisibleChanged(EventArgs e)\r\n at
System.Windows.Forms.Control.OnParentVisibleChanged(EventArgs e)\r\n at
System.Windows.Forms.Control.OnVisibleChanged(EventArgs e)\r\n at
System.Windows.Forms.ScrollableControl.OnVisibleChanged(EventArgs e)\r\n
at System.Windows.Forms.Form.OnVisibleChanged(EventArgs e)\r\n at
System.Windows.Forms.Control.SetVisibleCore(Boolean value)\r\n at
System.Windows.Forms.Form.SetVisibleCore(Boolean value)\r\n at
System.Windows.Forms.Control.set_Visible(Boolean value)\r\n at
System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32
reason, ApplicationContext context)\r\n at
System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason,
ApplicationContext context)\r\n at
System.Windows.Forms.Application.Run(Form mainForm)\r\n at
Infragistics.Practices.CompositeUI.WinForms.IGFormShellApplication`2.Start()\r\n
at ClinicalComputers.CCOS.Shell.ShellApplication.Start() in
D:\\DotNet\\CCOSNet\\Source\\Infrastructure\\Shell\\ShellApplication.cs:line
241\r\n at Microsoft.Practices.CompositeUI.CabApplication`1.Run()\r\n at
ClinicalComputers.CCOS.Shell.ShellApplication.RunInDebugMode() in
D:\\DotNet\\CCOSNet\\Source\\Infrastructure\\Shell\\ShellApplication.cs:line
86\r\n at ClinicalComputers.CCOS.Shell.ShellApplication.Main() in
D:\\DotNet\\CCOSNet\\Source\\Infrastructure\\Shell\\ShellApplication.cs:line
75\r\n at System.AppDomain._nExecuteAssembly(Assembly assembly, String[]
args)\r\n at System.AppDomain.ExecuteAssembly(String assemblyFile,
Evidence assemblySecurity, String[] args)\r\n at
Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()\r\n at
System.Threading.ThreadHelper.ThreadStart_Context(Object state)\r\n at
System.Threading.ExecutionContext.Run(ExecutionContext executionContext,
ContextCallback callback, Object state)\r\n at
System.Threading.ThreadHelper.ThreadStart()"


From: Bob Barrows on
This is one of the tougher ones to troubleshoot. Fortunately, a blog was
posted about it last week. Here it is:
http://www.sqlservercentral.com/blogs/robert_davis/archive/2010/07/13/Advanced-Troubleshooting-Week-at-SQL-University-Lesson-1.aspx
Good luck.

peter wrote:
> I am working on a win form C# application. I am using visual studio
> 2005, .net 3.5, SQL Server 2005 Express. Windows XP sp3.
> when the application starts and executes at the command of
> databaseNotSet =
> _dirSettingTableAdapter.Fill(_filesDatabase.DirSetting) == 0; DirSetting
> is a table in the database (fileDatebase), I got the error:
> "Cannot generate SSPI context."
>
> This error almost persistant, occationally it works several times then
> stopped working agan.
>


 | 
Pages: 1
Prev: problem in getting nulls
Next: GHD IV Salon Styler