I m getting crazy... A solution with 8 projects, and suddenly when publishing using ClickOnce and trying to run the app on the client machine appears this error :
*ERROR DETAILS
Following errors were detected during this operation.
* [16/04/2014 7:23:12] System.ArgumentException
- Value does not fall within the expected range.
- Source: System.Deployment
- Stack trace:
at System.Deployment.Application.NativeMethods.CorLaunchApplication(UInt32 hostType, String applicationFullName, Int32 manifestPathsCount, String[] manifestPaths, Int32 activationDataCount, String[] activationData, PROCESS_INFORMATION processInformation)
at System.Deployment.Application.ComponentStore.ActivateApplication(DefinitionAppId appId, String activationParameter, Boolean useActivationParameter)
at System.Deployment.Application.SubscriptionStore.ActivateApplication(DefinitionAppId appId, String activationParameter, Boolean useActivationParameter)
at System.Deployment.Application.ApplicationActivator.Activate(DefinitionAppId appId, AssemblyManifest appManifest, String activationParameter, Boolean useActivationParameter)
at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut, String textualSubId, String deploymentProviderUrlFromExtension, BrowserSettings browserSettings, String& errorPageUrl)
at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state)*
anybody can help me ???? Thanks in advance to all who read this question.
Related
I am getting error while inserting flat file into SQL Server. Direct transfer from SQL Server to SQL Server is not possible. Data has to be exported and then imported. Note : Data was exported from SQL server with text qualifier "double quotes" and pipe delimited "|". I tried to re-extract the data using fixed width format still unable to import. Please assist.
Error Message :
Error inserting data into table. (Microsoft.SqlServer.Import.Wizard)
------------------------------
Program Location:
at Microsoft.SqlServer.Import.Wizard.InsertData.ResultCheck(Result result)
at Microsoft.SqlServer.Import.Wizard.InsertData.DoWork()
at Microsoft.SqlServer.Management.TaskForms.SimpleWorkItem.Run()
===================================
Error inserting data into table. (Microsoft.SqlServer.Prose.Import)
------------------------------
Program Location:
at Microsoft.SqlServer.Prose.Import.BcpSynthesis.InsertIntoDB(String inputFilePath, String tableName, String schemaName, SqlConnection connection, Int32 batchSize, SqlTransaction transaction)
at Microsoft.SqlServer.Prose.Import.BcpProcess.<>c__DisplayClass42_0.<InsertIntoDb>b__0()
at Microsoft.SqlServer.Prose.Import.BcpProcess.ExecuteOperation(Action operation)
===================================
Object reference not set to an instance of an object. (Microsoft.SqlServer.Prose.Import)
------------------------------
Program Location:
at Microsoft.SqlServer.Prose.Import.OutputDataReader.GetValue(Int32 i)
at System.Data.SqlClient.SqlBulkCopy.GetValueFromSourceRow(Int32 destRowIndex, Boolean& isSqlType, Boolean& isDataFeed, Boolean& isNull)
at System.Data.SqlClient.SqlBulkCopy.ReadWriteColumnValueAsync(Int32 col)
at System.Data.SqlClient.SqlBulkCopy.CopyColumnsAsync(Int32 col, TaskCompletionSource`1 source)
at System.Data.SqlClient.SqlBulkCopy.CopyRowsAsync(Int32 rowsSoFar, Int32 totalRows, CancellationToken cts, TaskCompletionSource`1 source)
at System.Data.SqlClient.SqlBulkCopy.CopyBatchesAsyncContinued(BulkCopySimpleResultSet internalResults, String updateBulkCommandText, CancellationToken cts, TaskCompletionSource`1 source)
at System.Data.SqlClient.SqlBulkCopy.CopyBatchesAsync(BulkCopySimpleResultSet internalResults, String updateBulkCommandText, CancellationToken cts, TaskCompletionSource`1 source)
at System.Data.SqlClient.SqlBulkCopy.WriteToServerInternalRestContinuedAsync(BulkCopySimpleResultSet internalResults, CancellationToken cts, TaskCompletionSource`1 source)
at System.Data.SqlClient.SqlBulkCopy.WriteToServerInternalRestAsync(CancellationToken cts, TaskCompletionSource`1 source)
at System.Data.SqlClient.SqlBulkCopy.WriteToServerInternalAsync(CancellationToken ctoken)
at System.Data.SqlClient.SqlBulkCopy.WriteRowSourceToServerAsync(Int32 columnCount, CancellationToken ctoken)
at System.Data.SqlClient.SqlBulkCopy.WriteToServer(IDataReader reader)
at Microsoft.SqlServer.Prose.Import.BcpSynthesis.InsertIntoDB(String inputFilePath, String tableName, String schemaName, SqlConnection connection, Int32 batchSize, SqlTransaction transaction)
I'm using Nhibernate 4 and FluentNhibernate 2.0.3 with db Microsoft Access 2000. I can't save the entry on the DB because i'm getting an error when I go to insert the Note field sending a request HTTP POST for example:
{
"Note": "bla bla bla"
}
NOTE: In the database table, the column "Note" is setted as "LONG TEXT" (Not Required)
Could It be a problem of conversion of data Types?
Here's the stack trace:
NHibernate.Exceptions.GenericADOException: could not insert: [Domain.Destinatari#1773][SQL: INSERT INTO `Destinatari` (Note, IDDestinatario) VALUES (?, ?)] ---> System.Data.OleDb.OleDbException: Errore di sintassi nell'istruzione INSERT INTO.
in System.Data.OleDb.OleDbCommand.ExecuteCommandTextErrorHandling(OleDbHResult hr)
in System.Data.OleDb.OleDbCommand.ExecuteCommandTextForSingleResult(tagDBPARAMS dbParams, Object& executeResult)
in System.Data.OleDb.OleDbCommand.ExecuteCommandText(Object& executeResult)
in System.Data.OleDb.OleDbCommand.ExecuteCommand(CommandBehavior behavior, Object& executeResult)
in System.Data.OleDb.OleDbCommand.ExecuteReaderInternal(CommandBehavior behavior, String method)
in System.Data.OleDb.OleDbCommand.ExecuteNonQuery()
in NHibernate.JetDriver.JetDbCommand.ExecuteNonQuery()
in NHibernate.AdoNet.AbstractBatcher.ExecuteNonQuery(IDbCommand cmd)
in NHibernate.AdoNet.NonBatchingBatcher.AddToBatch(IExpectation expectation)
in NHibernate.Persister.Entity.AbstractEntityPersister.Insert(Object id, Object[] fields, Boolean[] notNull, Int32 j, SqlCommandInfo sql, Object obj, ISessionImplementor session)
--- Fine della traccia dello stack dell'eccezione interna ---
in NHibernate.Persister.Entity.AbstractEntityPersister.Insert(Object id, Object[] fields, Boolean[] notNull, Int32 j, SqlCommandInfo sql, Object obj, ISessionImplementor session)
in NHibernate.Persister.Entity.AbstractEntityPersister.Insert(Object id, Object[] fields, Object obj, ISessionImplementor session)
in NHibernate.Action.EntityInsertAction.Execute()
in NHibernate.Engine.ActionQueue.Execute(IExecutable executable)
in NHibernate.Engine.ActionQueue.ExecuteActions(IList list)
in NHibernate.Engine.ActionQueue.ExecuteActions()
in NHibernate.Event.Default.AbstractFlushingEventListener.PerformExecutions(IEventSource session)
Below my mapping code:
Public Class DestinatariMap
Inherits ClassMap(Of Destinatari)
Public Sub New()
MyBase.New
LazyLoad()
Id(Function(x) x.IDDestinatario).GeneratedBy().Increment()
Map(Function(x) x.Note)
End Sub
End Class
Here's my Domain code:
Public Class Destinatari
Private _ID_Destinatario As Integer
Private _Note As String
Public Overridable Property IDDestinatario() As Integer
Get
Return Me._ID_Destinatario
End Get
Set
Me._ID_Destinatario = Value
End Set
End Property
Public Overridable Property Note() As String
Get
Return Me._Note
End Get
Set
Me._Note = Value
End Set
End Property
End Class
Thanks
NHibernate version 3.3.1.4000
Query:
IQueryable<Activity> activities = _repository.GetList<Activity>();
IQueryable<ActivityStatistic> statistics = activities
.GroupBy(activity => activity.ActivityLicense.SerialNumber)
.Select(grouping => new ActivityStatistic
{
ActivityCount = grouping.Count(),
LicenseCode = grouping.Key
})
.OrderBy(stat => stat.LicenseCode);
List<ActivityStatistic> result = statistics
.Skip(request.StartIndex)
.Take(request.Count)
.ToList();
If I comment Skip/Take code, it works properly. How can I make it to work together without calling ToList() after OrderBy using LINQ to NHibernate?
Thanks in advance.
Update:
Exception:
The method or operation is not implemented.
at NHibernate.Linq.GroupBy.AggregatingGroupByRewriter.FlattenSubQuery(SubQueryExpression subQueryExpression, QueryModel queryModel)
at NHibernate.Linq.GroupBy.AggregatingGroupByRewriter.ReWrite(QueryModel queryModel)
at NHibernate.Linq.Visitors.QueryModelVisitor.GenerateHqlQuery(QueryModel queryModel, VisitorParameters parameters, Boolean root)
at NHibernate.Linq.NhLinqExpression.Translate(ISessionFactoryImplementor sessionFactory)
at NHibernate.Hql.Ast.ANTLR.ASTQueryTranslatorFactory.CreateQueryTranslators(String queryIdentifier, IQueryExpression queryExpression, String collectionRole, Boolean shallow, IDictionary`2 filters, ISessionFactoryImplementor factory)
at NHibernate.Engine.Query.QueryPlanCache.GetHQLQueryPlan(IQueryExpression queryExpression, Boolean shallow, IDictionary`2 enabledFilters)
at NHibernate.Impl.AbstractSessionImpl.GetHQLQueryPlan(IQueryExpression queryExpression, Boolean shallow)
at NHibernate.Impl.AbstractSessionImpl.CreateQuery(IQueryExpression queryExpression)
at NHibernate.Linq.DefaultQueryProvider.PrepareQuery(Expression expression, IQuery& query, NhLinqExpression& nhQuery)
at NHibernate.Linq.DefaultQueryProvider.Execute(Expression expression)
at NHibernate.Linq.DefaultQueryProvider.Execute[TResult](Expression expression)
at Remotion.Linq.QueryableBase`1.GetEnumerator()
at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
at MBP.AuthorizationService.Logic.LicenseService.GetActivityStatistic(CommonRequest request, Int32& recordsCount) in D:\Projects\MBP.Launcher\MBP.AuthorizationService.Logic\LicenseService.cs:line 201
Michael Petito answered to the question:
This is a known issue that I just ran into as well:
nhibernate.jira.com/browse/NH-2566 – Michael Petito Aug 22 at 19:56
Waiting for new releases...
I am using
MVC 3
VB.NET and
Razor ViewEngine.
I am playing around with WebGrid in my application and it is telling me "failEmList" does not exist.
Below is the code from the calling Function, the View, and the part of the model that it is getting the data from.
FailEmailSends is just a List(of string) and has lines with single entries of email Addresses.
Dim vm As New MassEmailVM
For Each _fail In failEmailSends
vm.failEmList.Add(_fail)
Next
ViewBag.succCount = succCount.ToString
ViewBag.failECount = failEmailCount.ToString
Return View(vm)
View is as follows:
#Modeltype xxxxxxxxxxxxx
#Code
ViewData("Title") = "Mass Emails Sent"
End Code
<table>
<tr><th>Total Sent</th><td>#ViewBag.succCount</td></tr>
<tr><th>Total Fail</th><td>#ViewBag.failECount</td></tr>
<tr><th>Fail Email Addresses</th></tr>
</table>
#code
Dim grid = New WebGrid(Model.failEmList)
End Code
<div id="grid">
#grid.GetHtml(
tableStyle:="grid",
headerStyle:="head",
alternatingRowStyle:="alt",
columns:=grid.Columns(
grid.Column("failEmList", "Email List")
))
</div>
Relevant part of view Model:
Private _failEmList As New List(Of String)
Public Property failEmList() As List(Of String)
Get
Return _failEmList
End Get
Set(ByVal value As List(Of String))
_failEmList = value
End Set
End Property
Any ideas why this is throwing the following error:
System.InvalidOperationException was unhandled by user code
Message=Column "failEmList" does not exist.
Source=System.Web.Helpers
StackTrace:
at System.Web.Helpers.WebGridRow.get_Item(String name)
at System.Web.Helpers.WebGrid.GetTableBodyHtml(IEnumerable`1 columns, String rowStyle, String alternatingRowStyle, String selectedRowStyle)
at System.Web.Helpers.WebGrid.Table(String tableStyle, String headerStyle, String footerStyle, String rowStyle, String alternatingRowStyle, String selectedRowStyle, String caption, Boolean displayHeader, Boolean fillEmptyRows, String emptyRowCellValue, IEnumerable`1 columns, IEnumerable`1 exclusions, Func`2 footer, Object htmlAttributes)
at System.Web.Helpers.WebGrid.GetHtml(String tableStyle, String headerStyle, String footerStyle, String rowStyle, String alternatingRowStyle, String selectedRowStyle, String caption, Boolean displayHeader, Boolean fillEmptyRows, String emptyRowCellValue, IEnumerable`1 columns, IEnumerable`1 exclusions, WebGridPagerModes mode, String firstText, String previousText, String nextText, String lastText, Int32 numericLinksCount, Object htmlAttributes)
at ASP._Page_Views_Admin_MassEmailsSent_vbhtml.Execute() in C:\Users\Skindeep\Documents\Visual Studio 2010\Projects\xxxxxxxxxx\Views\Admin\MassEmailsSent.vbhtml:line 21
at System.Web.WebPages.WebPageBase.ExecutePageHierarchy()
at System.Web.Mvc.WebViewPage.ExecutePageHierarchy()
at System.Web.WebPages.StartPage.RunPage()
at System.Web.WebPages.StartPage.ExecutePageHierarchy()
at System.Web.WebPages.WebPageBase.ExecutePageHierarchy(WebPageContext pageContext, TextWriter writer, WebPageRenderingBase startPage)
at System.Web.Mvc.RazorView.RenderView(ViewContext viewContext, TextWriter writer, Object instance)
at System.Web.Mvc.BuildManagerCompiledView.Render(ViewContext viewContext, TextWriter writer)
at System.Web.Mvc.ViewResultBase.ExecuteResult(ControllerContext context)
at System.Web.Mvc.ControllerActionInvoker.InvokeActionResult(ControllerContext controllerContext, ActionResult actionResult)
at System.Web.Mvc.ControllerActionInvoker.<>c__DisplayClass1c.<InvokeActionResultWithFilters>b__19()
at System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilter(IResultFilter filter, ResultExecutingContext preContext, Func`1 continuation)
InnerException:
You may try the following:
#Code
Dim grid = New WebGrid(Model.failEmList)
End Code
<div id="grid">
#grid.GetHtml(
tableStyle:= "grid",
headerStyle:= "head",
alternatingRowStyle:= "alt",
columns:= grid.Columns(
grid.Column(format:= Function(item) item, header:= "Email List")
)
)
</div>
Try this
#grid.GetHtml(
columns: new[] {
grid.Column(format: (item) => item)
}
)
In case it helps someone, in my case I made a copy/paste error, and forgot to change the source when declaring the grid! Once I corrected the first column with the suggestions above, the second column threw the same error.
Dim grid = New WebGrid(Model.WasTheWrongNameHere)
We have windows appfabric cache server on win2k8 server and have installed “Windows Server 2003 Distributed Cache Client” on win2k3 web server from this link .
We are getting below exception while getting the cache object from cache factory.Can anybody help us to understand the cause of exception and its solution? Please note that below exception is not thrown while adding or getting cache data.
Our main purpose is to get & put cache data to windows appfabric server(win2k8) from win2k3 webserver client.
Exception:-
System.Runtime.Serialization.SerializationException: There was an error deserializing the object . Input string was not in a correct format. ---> System.FormatException: Input string was not in a correct format.
at System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal)
at System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info)
at System.String.System.IConvertible.ToInt32(IFormatProvider provider)
at System.Convert.ToInt32(Object value, IFormatProvider provider)
at System.Runtime.Serialization.FormatterConverter.ToInt32(Object value)
at System.Runtime.Serialization.SerializationInfo.GetInt32(String name)
at Microsoft.ApplicationServer.Caching.EvictionConfig..ctor(SerializationInfo info, StreamingContext context)
at ReadEvictionConfigFromXml(XmlReaderDelegator , XmlObjectSerializerReadContext , XmlDictionaryString[] , XmlDictionaryString[] )
at System.Runtime.Serialization.ClassDataContract.ReadXmlValue(XmlReaderDelegator xmlReader, XmlObjectSerializerReadContext context)
at System.Runtime.Serialization.XmlObjectSerializerReadContext.ReadDataContractValue(DataContract dataContract, XmlReaderDelegator reader)
at System.Runtime.Serialization.XmlObjectSerializerReadContextComplex.InternalDeserializeInSharedTypeMode(XmlReaderDelegator xmlReader, Int32 declaredTypeID, Type declaredType, String name, String ns)
at System.Runtime.Serialization.XmlObjectSerializerReadContextComplex.InternalDeserialize(XmlReaderDelegator xmlReader, Type declaredType, String name, String ns)
at System.Runtime.Serialization.XmlObjectSerializerReadContext.ReadSerializationInfo(XmlReaderDelegator xmlReader, Type type)
at ReadPolicyConfigFromXml(XmlReaderDelegator , XmlObjectSerializerReadContext , XmlDictionaryString[] , XmlDictionaryString[] )
at System.Runtime.Serialization.ClassDataContract.ReadXmlValue(XmlReaderDelegator xmlReader, XmlObjectSerializerReadContext context)
at System.Runtime.Serialization.XmlObjectSerializerReadContext.ReadDataContractValue(DataContract dataContract, XmlReaderDelegator reader)
at System.Runtime.Serialization.XmlObjectSerializerReadContextComplex.InternalDeserializeInSharedTypeMode(XmlReaderDelegator xmlReader, Int32 declaredTypeID, Type declaredType, String name, String ns)
at System.Runtime.Serialization.XmlObjectSerializerReadContextComplex.InternalDeserialize(XmlReaderDelegator xmlReader, Type declaredType, String name, String ns)
at System.Runtime.Serialization.XmlObjectSerializerReadContext.ReadSerializationInfo(XmlReaderDelegator xmlReader, Type type)
at ReadNamedCacheConfigurationFromXml(XmlReaderDelegator , XmlObjectSerializerReadContext , XmlDictionaryString[] , XmlDictionaryString[] )
at System.Runtime.Serialization.ClassDataContract.ReadXmlValue(XmlReaderDelegator xmlReader, XmlObjectSerializerReadContext context)
at System.Runtime.Serialization.XmlObjectSerializerReadContext.ReadDataContractValue(DataContract dataContract, XmlReaderDelegator reader)
at System.Runtime.Serialization.XmlObjectSerializerReadContextComplex.InternalDeserializeInSharedTypeMode(XmlReaderDelegator xmlReader, Int32 declaredTypeID, Type declaredType, String name, String ns)
at System.Runtime.Serialization.XmlObjectSerializerReadContextComplex.InternalDeserialize(XmlReaderDelegator xmlReader, Type declaredType, String name, String ns)
at System.Runtime.Serialization.NetDataContractSerializer.InternalReadObject(XmlReaderDelegator xmlReader, Boolean verifyObjectName)
at System.Runtime.Serialization.XmlObjectSerializer.ReadObjectHandleExceptions(XmlReaderDelegator reader, Boolean verifyObjectName)
--- End of inner exception stack trace ---
at System.Runtime.Serialization.XmlObjectSerializer.ReadObjectHandleExceptions(XmlReaderDelegator reader, Boolean verifyObjectName)
at System.Runtime.Serialization.XmlObjectSerializer.ReadObject(XmlDictionaryReader reader)
at Microsoft.ApplicationServer.Caching.Utility.Deserialize(Byte[][] buffers, Boolean checkTypeToLoad)
at Microsoft.ApplicationServer.Caching.RoutingClient.GetCacheProperties()
at Microsoft.ApplicationServer.Caching.DataCacheFactory.GetCache(String cacheName)
Here is the code snippet :-
DataCacheFactoryConfiguration configuration = new DataCacheFactoryConfiguration();
List<DataCacheServerEndpoint> servers = new List<DataCacheServerEndpoint>(1);
servers.Add(new DataCacheServerEndpoint("localhost", 22233));
configuration.Servers = servers;
DataCacheSecurity security = new DataCacheSecurity(DataCacheSecurityMode.None, DataCacheProtectionLevel.None);
configuration.SecurityProperties = security;
DataCacheFactory factory = new DataCacheFactory(configuration);
DataCache cache = factory.GetCache("default"); // above exception is thrown here