I'm trying to call a web service from .NET 3.5 using WCF. The error I'm getting currently is
An unsecured or incorrectly secured fault was received from the other party. See the inner FaultException for the fault code and detail.
InnerException: {"Value -2147483648 for millisOfSecond must be in the range [0,999]"}
I've narrow...
I have simple remoting API that has method similar to this:
bool FillMyList(List<string> ListToFill)
{
ListToFill.Add("something");
ListToFill.Add("more stuff");
}
But, when I call it through a proxy object, upon return, ListToFill stays as it was (in my case, empty).
What now? I must point out that rest of my methods are ca...
I'm trying to find an example of how to convert the standard login framework that ships with ASP .NET MVC 2 (the account controllers and views, etc) into a modal login dialog system, like the one at Digg.
After searching for hours, the closest tutorial I found was this: http://www.weirdlover.com/2010/05/20/mvc-render-partial-modal-pop...
I have a string that I want to extract text between comment tags, manipulate it, and replace it back. Here is what I am trying to work with:
...
<!--RegionStart url="http://domain1.com"-->
some text here
<!--RegionFinish-->
...
<!--RegionStart url="http://domain2.com"-->
some text there
<!--RegionFinish-->
...
<!--RegionSt...
I want to get a specific value from a resource programmatically. For example, I have a FileName variable which contains the resource Image name.
How to get that resource with this variable?
I try this but not working: (file is null after line 3)
public Bitmap FindImgaeFromResource(string ImageFileName)
{
Assembly thisExe;
thi...
i am going to bind a datatable to the datagrid
i just want to change the color of a particular row of datagrid based on the value on datatable row. i need c#/.net code for it
...
I have a panel being used like a subform. What I would like is to restrict the panel to some maximum size. When the form is maximized or resized, the subform is resized only to some maximum height and width. Couldn't find a property to limit the size of the panel so I did it manually by handling its resize event. That's okay because it's...
Solution setup:
DAL (class library)
BLL (class library)
Common (class library (some common functionality - enums, logging, exceptions,...))
Application1 (Windows Application)
Application2 (Windows Application)
WebApp (Web application)
...
Let's say I have a Customer entity, which is:
a table in SQL server
a CustomerDataTable in DAL...
I have a simple Application built using Mono on Ubuntu that prints out the entries of a list in sequence. The code takes about 6 ms to execute on Ubuntu, however the same code takes about 40 ms to execute on windows. Is there a reason why the same application code would run faster on Ubuntu than it would using the actual .net runtime on ...
So, I have a little problem here.
Suppose I have:
public class Repository<TEntity>
where TEntity : class
{
public abstract void Add(TEntity entity);
// ...and so on...
}
And now I want to define a contract class, like so:
public class RepositoryContracts<TEntity> : Repository<TEntity>
where TEntity : class
{
pub...
Hi,
I was wondering whether it is is possible to modify a user's password using Jabber Net. If so, is there a neat way to verify first that the old password is indeed valid before modifying it to the new one?
...
What happens when I annotate a class with serializable? Can I serialize them into json or XML? How is this done?
...
I have a lot of classes and this is a lot of work to do the XML mappings.
...
There is a table in a SQL database like below :
SampleTable :
-----------------------
id | number | price
-----------------------
1 | 3 | 300
2 | 1 | 200
3 | 5 | 100
4 | 10 | 10
5 | 30 | 30
6 | 1 | 500
-----------------------
I wanna calculate total price like below :
in each row => var SumO...
Is there a real reason to hide exceptions on a webpage? I can understand hiding to not scare users but on the site i am developing theres no concern for scaring users. I imagine if you have SQL injection holes hiding the exception wont actually matter.
So what reasons might one have to hide exceptions on a webpage from users?
...
Our application is built with VS 2008, uses Linq and has Target Framework set to .NET Framework3.5.
It works OK when only .NET 3.5 or 4 is installed on the machine.
However, on machines where both .NET 2 (or 3.0) and .NET 4 are installed, the application is loaded with .NET 2, and crashes when Linq is accessed, as it looks for the .NET...
I thought this would've been a lot simpler but at this point I'm confused and haven't progressed at all.
Basically, I need to be able to accept a password from a user in a WPF app, encrypt it then store this in a database and be able to decrypt later on. However I'm not sure how to implement this.
This is completely trivial so whether...
Dear ladies and sirs.
My headache is this - my server application exceeds the maximum open database connections while being under load. So, I figure I need a task queue (aka service bus) for write database access. A queue, that db write requests can be posted to it and the dedicate threads will read it and execute.
I was wondering if t...
I have the following extension method to serialize my class....
public static string SerializeToXml<T>(this object obj)
{
XDocument doc = new XDocument();
XmlSerializer ser = new XmlSerializer(typeof(T));
using (var writer = doc.CreateWriter())
{
...
I have a site that uses FormsAuthentication and yes, the name of the cookie is .ASPAUX :)
I can log in perfectly. The server creates a forms authentication ticket, packs it in a cookie, properly determines the expiration time (1 year ahead) and sends it to the client.
For some reason, after some time, even though the cookie is there ye...