instruction stringlengths 0 30k ⌀ |
|---|
As far as I know, it is not easy to get just Data and data-bind the repeater on the client side. But, you might want to [check this out][1].
[1]: http://dotnetslackers.com/articles/ajax/ASPNETRepeater.aspx |
I feel the eye candy demos are targeted mostly towards designers. Having said that, there is a huge potential in improving usability of LOB apps using WPF. [Check this article about the potential of Silverlight][1].
*Line-of-business applications have a notorious reputation for being all business and no pleasure. Th... |
if you want to abstract memory management, Java comes to my mind instantly. |
A friend of mine used WPF for some darn cool tree (as in tree-view) rendering where it did a little better than showing a simple sliding view. I might be able to talk him into putting it into the public domain or somedthing. |
I am member of a Danish architecture group in which many of the members are focused solely on building WinForms app (I'm a web guy myself). During our meetings the topic of building Windows apps in Winforms vs. WPF has come up a number of times and each time after much the discussion the conclusion is that whiæe WPF do... |
Web Control Properties |
|c#|asp.net| |
I would like to make my web control more readable in design mode, basically I want the tag declaration to look like:
<cc1:Ctrl ID="Value1" runat="server">
<Values>string value 1</Value>
<Values>string value 2</Value>
</cc1:Ctrl>
Lets say I have a private variable in the co... |
You shouldn't have too many probles. As other's have mentioned, there's many .Net PostgreSQL data providers available. One thing you may want to look out for is that features like Linq will probably not be able to be used. |
You shouldn't have too many problems. As others have mentioned, there's many .Net PostgreSQL data providers available. One thing you may want to look out for is that features like Linq will probably not be able to be used. |
I get the same message when I process a cube, but if I wait for a few seconds the trace information arrives. Are you dealing with a very large quantity of data or a very complex cube? Maybe this is a silly question, but have you tried waiting a few minutes? |
Putting `freetexttable(TblB, *, 'query')` into a temp table may help if it's getting called repeatedly in the execution plan. |
LINQ to SQL Mapping From Money to Double |
|linq-to-sql| |
I'm working with LINQ for the first time and wanted to get the Mapping to work when I have a money type in SQL, but my domain object property is of type double. How can I express this in the XML file, or in code so that the mapping does not throw the usual "invalid cast" exception? |
|linq|linq-to-sql|orm| |
Checklist for Web Site Programming Vunerabilities |
|security|defensive-programming| |
Watching SO come online has been quite an education for me. I'd like to make a checklist of various vunerabilities and exploits used against web sites, and what programming techniques can be used to defend against them.
- What categories of vunerabilities?
- crashing site
- breaking into server
- break... |
Watching SO come online has been quite an education for me. I'd like to make a checklist of various vunerabilities and exploits used against web sites, and what programming techniques can be used to defend against them.
- What categories of vunerabilities?
- crashing site
- breaking into server
- break... |
|security|defensive-programming|needs-editing| |
|security|defensive-programming| |
Watching SO come online has been quite an education for me. I'd like to make a checklist of various vunerabilities and exploits used against web sites, and what programming techniques can be used to defend against them.
- What categories of vunerabilities?
- crashing site
- breaking into server
- break... |
Have you used Rhino Igloo? |
|asp.net-mvc|model-view-controller| |
Has anyone used [Rhino igloo](http://www.ayende.com/Blog/archive/2007/09/03/Rhino-Igloo-ndash-MVC-Framework-for-Web-Forms.aspx) in a non-trivial project? I am curious if it's worth, what are its drawbacks, does it enhance testability a lot, is it easy to use. How would you compare it to a pure MVC framework (ASP.NET MV... |
The keywords you are looking for are "class var" - this starts a block of class variables in your class declaration. You need to end the block with "var" if you wish to include other fields after it (otherwise the block may be ended by a "private", "public", "procedure" etc specifier). Eg (please note the following is ... |
The keywords you are looking for are "class var" - this starts a block of class variables in your class declaration. You need to end the block with "var" if you wish to include other fields after it (otherwise the block may be ended by a "private", "public", "procedure" etc specifier). Eg
type
TMySharedO... |
I'm trying to verify when the OAB (Offline Address Book) root folder for a new OAB is created with powershell. Is there a WMI class that exposes this? I'm using powershell, but any examples or links will do. |
Definitely agree with Chris on the "Stick to memory (and other scarce resource) management in -dealloc and -finalize..." comment. A lot of times I'll see people try to invalidate NSTimer objects in their dealloc functions. The problem is, NSTimer retains it's targets. So, if the target of that NSTimer is self, deall... |
Without knowing more details about the nature of the seventy tables and their conceptual relations it isn't really possible to give a good answer. Are these legacy tables or have you designed this from scratch?
Are the tables related by some kind of inheritance pattern or could they be? Rails can do a limited form ... |
PDF support is a little buggy in ImageMagick - but it's by far the best OS way for ruby. There's also a google summer of code project for pure Ruby PDF support.
I've read stuff about using OpenOffice without the GUI to transform .doc files - but it'll be complicated at best. |
track down file handle |
|java|jakarta-ee|logging|file| |
I have a huge ear that uses log4j and there is a single config file that is used to set it up. In this config file there is no mention of certain log files but, additional files apart from those specified in the config file get generated in the logs folder. I've searched for other combinations of (logger|log4j|log).(pr... |
|java|logging|file|jakarta-ee|websphere| |
You can use Firefox or XULRunner with some fairly simple XUL to create thumbnails as PNG dataURLs (that you could then write to file if needed). Robert O'Callahan has some excellent information on it here:
[http://weblogs.mozillazine.org/roc/archives/2005/05/rendering_web_p.html][1]
[1]: http://weblogs.mozill... |
CMM and CMMI both offer some benefits if your organization takes the lessions it tries to teach at heart. The problem is that getting to the higher levels is very difficult and expensive, and the only time I have seen an organization go through the effort is because their customers won't let them bid on contracts unti... |
Getting EPG info from DVB-T |
|epg| |
I'm interested in grabbing the EPG data from DVB-T streams. Does anyone know of any C libraries or an alternative means of getting the data? |
Log your 404's. |
The Linq to SQL features, well really pretty much the Linq Extensions in general are well worth the upgrade.
As for your worries about HD space and install time, IMO these are not relevant on most modern systems for the newer frameworks. The newer versions of the frameworks (3.0 and 3.5) are really just "refreshes"... |
3.5 framework has had it's first Service Pack release, so it's more stable than it was after release, but bear in mind it is far easier to upgrade code from 2.0 to 3.5 than it is to go back to 3.5 if for whatever reason you encounter a show stopper.
The [wiki article](http://en.wikipedia.org/wiki/Microsoft_.NET#.NET... |
You should distribute your app with whatever version of .Net is the version you've done the most testing against. If you've been doing all your developing and testing in .Net 2.0, then ship with 2.0.
But you may owe it to your customers to test against 3.5 and ship with that, instead, for the sake of any bugs that h... |
How to connect to PostgreSQL from .NET using TLS with both client and server authentication? |
|.net|postgresql|database-connection|ssl| |
I want to connect a C# .NET application to a PostgreSQL database, using TLS with client _and_ server authentication: in other words, if the certificate from the client can not be verified against the certificate of the server, the client should get access denied, and if the client can not verify the certificate of the ... |
I always use the most up-to-date version of the Framework. This may be a small up-front burden on users, but the app has a much longer life between upgrades. That may or may not be important to you, but consider:
If you had shipped an application in 2005 using .NET 1.1, the framework your app runs on is now out of ... |
The keywords you are looking for are "class var" - this starts a block of class variables in your class declaration. You need to end the block with "var" if you wish to include other fields after it (otherwise the block may be ended by a "private", "public", "procedure" etc specifier). Eg
(Edit: I re-read the quest... |
One possible approach is to set up your project as follows.
Your directory structure is as follows:
<pre>./project Your project files
./project/t/*.t Your unit test scripts
./project/t/scripts/* Auxiliary scripts used by your unit tests</pre>
Your ./project/Makefile contains the followin... |
Pick a constant to scale the coordinates by so that 1 unit describes an acceptably small box and yet the integer part of the largest component by magnitude will fit into a 32-bit integer; convert the X, Y and Z components of the result to integers and hash them together. Use that as a hash function for a map or hashtab... |
Custom controls are only supported by the designer when building the control **or** when building the page that uses the control, but not both. |
Scheduled Tasks for Web Applications |
|common-tasks| |
What are the different approaches for creating scheduled tasks for web applications, with or without a separate web/desktop application? |
|common-tasks|job|schedule|recurring| |
|jobs|schedule|common-tasks|recurring| |
|jobs|schedule|common-tasks| |
You can somewhat replicate what ClickOnce does, just adjust it for your needs.
1. Create a lightweight executable that checks a network/web location for updates.
2. If there are updates, it copies them locally and replaces the "real" application files.
3. It runs the "real" application.
The location for the ap... |
Writing code that has no value is always a bad idea. Since the proposed test adds no value to your project (or very close to it). Then your are wasting valuable time that you could spend writing code that actually brings value. |
Numbers can be useful as described by other answers, but consider how they can also be rather meaningless... Sun, you know SUN, java: 1.2, 1.3, 1.4 1.5 or 5 then 6.
In the good old Apple II version numbers Meant Something. Nowadays, people are giving up on version numbers and going with silly names like "Feisty fig" (... |
In the more general case, a secret (in this application, a decryption key for the data) can be split into shares such that some threshold number of these shares is required to recover the secret. This is known as secret sharing or with n shares and a threshold of t, a (t,n)-threshold scheme.
One way this can be don... |
This really depends on the state of the codebase... are there massive classes? one class with mega-methods? Are the classes tightly coupled? is configuration a burden?
Considering this, I suggest reading [Working Effectively with Legacy Code][1], picking out your problems, and applying the recommendations.
[1... |
This is a performance run by Maximilian Beller. According to him, LINQ is much much slower.
[Read his comprehensive study][1]
[1]: http://www.mbeller.de/2007/12/performance-comparison-between-linq.html |
1. Like mentioned before: Take care that you close all open handlers.
2. Sometimes the indexing service of Microsoft blocks files. Exclude your directory |
What you want isn't possible directly but you can use Expressions in C# 3.0:
public string ExampleFunction(Expression<Func<string, string>> f) {
Console.WriteLine(f.Parameters[0]);
}
ExampleFunction(WhatIsMyName => WhatIsMyName); |
What you want isn't possible directly but you can use Expressions in C# 3.0:
public void ExampleFunction(Expression<Func<string, string>> f) {
Console.WriteLine((f.Body as MemberExpression).Member.Name);
}
ExampleFunction(x => WhatIsMyName);
/EDIT: This code works now. |
Well I don't agree with your comment on replication. You can start a replication by creating a database from scratch, and you can control either the updates will be done by updating the available client database or simply recreating the database.
Automated replication will ease your work by automatically managing k... |
Entities and Value Objects in Web Applications |
|architecture|web-applications|domain-driven-design| |
We have a simple domain model: Contact, TelephoneNumber and ContactRepository. Contact is entity, it has an identity field. TelephoneNumber is typical value object: hasn't any identity and couldn't be loaded separately from the Contact instance.
From other side we have web application for manipulating the contacts. ... |
Use any unique transformation of your 3D coordinates and store only the list of the results.
Example:
md5('X, Y, Z') is unique and you can store only the resulting string.
The hash is not a performant idea but you get the concept. Find any methematic unique transformation and you have it.
/Vey |
ls -trd */ | head --lines=-4 | xargs rm -rf
**Edit:** Sorry, there was a typo in my first answer. The argument to 'head' is lines=-4 (show all but the last four lines), not lines=4 (show the first four lines).
|
Well, in this case, if you can't use Memoization, you're rather restricted since you can really only use the stack as your cache: You've got no way to declare a new variable at the scope you'll need. All I can think of (and I'm not claiming it will be pretty) that will do what you want but retain the composability you ... |
LispMe works on a Palm Pilot, take it anywhere, and scheme on the go. GREAT way to learn scheme.
|
It could be the source of your problem though!
Check out "quirks mode" as that depends on doctype settings.
Further study : http://www.quirksmode.org/
explanation: you can toggle your browser into (mostly IE) strict standards compilant mode, and loose mode. This will greatly affect rendering. TAM's setting could hav... |
If you want everything and the kitchen sink plus clustering/scaling support, I'd say [Plone][1]. Very big community, written in Python, uses the Zope stack so it has a built in application server. Etc, etc. I suggest taking a look at it.
[1]: http://plone.org/ |
A few years ago, I discovered the **p*** commands or get information about processes: **ptree**, **pgrep**, **pkill**, and **pfiles**. Of course, the mother of them all is **ps**, but you need to pipe the output into **less**, **grep** and/or **awk** to make sense of the output under heavy load. **top** (and variants... |
Yes. The [HTML 4.01 Specification](http://www.w3.org/TR/REC-html40/) requires that the [doctypes be at the start of the document](http://www.w3.org/TR/REC-html40/struct/global.html#h-7.2). |
You cannot overwrite "this". It points to the current object instance. |
http://www.maatkit.org/ has mk-archiver
> archives or purges rows from a table to another table and/or a file. It is designed to efficiently “nibble” data in very small chunks without interfering with critical online transaction processing (OLTP) queries. It accomplishes this with a non-backtracking query plan that ke... |
At school, I was taught: CMM is a good Idea, but lacking certification (anyone can say they are level 5 / level 4) it ends up being a marketing tool for offshore shops. So, yeah, the idea is sound, but how do you prove adherence? |
1. I try to **avoid using code to print HTML "directly"**. It is difficult to maintain, edit, add styles and etc. Some cases like generating an HTML email in the code, I create a text file or HTML file with markers like, [name], [verification code] and etc. I load this from the code and replace those markers. This way... |
yes and no.
You can't do:
insert into foo (c1, c2, c3)
values ("v1a", "v2a", "v3a"),
("v1b", "v2b", "v3b"),
("v1c", "v2c", "v3c")
but you can do
insert into foo (c1, c2, c3)
select (v1, v2, v3) from bar
What does that get you if you don't already have the dat... |
yes and no.
You can't do:
insert into foo (c1, c2, c3)
values ("v1a", "v2a", "v3a"),
("v1b", "v2b", "v3b"),
("v1c", "v2c", "v3c")
but you can do
insert into foo (c1, c2, c3)
select (v1, v2, v3) from bar
What does that get you if you don't already have the dat... |
While we discussing it, smart guys are building amazing apps:
[Lawson Smart Office brings WPF goodness to the enterprise][1]
[1]: http://channel9.msdn.com/shows/Continuum/LawsonSmartOffice/ |
While we discussing it, smart guys are building amazing apps:
[Lawson Smart Office brings WPF goodness to the enterprise][1]
[IGT’s Next-Generation UI with WPF][2]
[Billy Hollis on Getting Smart with WPF][3]
[WPF in LOB][4]
[1]: http://channel9.msdn.com/shows/Continuum/LawsonSmartOffice/
[2]: http... |
We have started using it in peripherals to the main application, sort of as a POC as well as a learning opportiunity.
It's looking OK, but we only have 1 graphic artist here who is overworked, and without him, WPF apps still look graphically like developer designed apps.
As well as us coders not being graphical... |
We have started using it in peripherals to the main application, sort of as a POC as well as a learning opportiunity. We consult externally and sell software, as well as do internal development, so we do have some luxury of trying for a decent looking User Experience.
It's looking OK, but we only have 1 graphic arti... |
We have started using it in peripherals to the main application, sort of as a POC as well as a learning opportiunity.
It's looking OK, but we only have 1 graphic artist here who is overworked, and without him, WPF apps still look graphically like developer designed apps.
As well as us coders not being graphical... |
We had a very similar problem recently where the subquery was returning null values sometimes. Then, the in statement treats null in a weird way, I think always matching the value, so if you change your query to:
select j.email
from jobseeker j
where j.email not in (select email from aspnet_Membershi... |
I agree with [EBGreen][1] and [Chris][2], but I want to add that you might want to consider testing your application against the newer versions of the framework and allow your application to run against those versions you deem to work well against (this can be done using some configuration trick, but unfortunately, I c... |
An inheritor of a base class should have an "is a" relationship. Interface represents An "implements a" relationship.
So only use a base class when your inheritors will maintain the is a relationship. |
You could have a lot of duplicates out there. I'm not seeing the query error off the top of my head, but you might try writing it this way:
SELECT j.email
FROM jobseeker j
LEFT JOIN aspnet_Membership m ON m.email = j.email
WHERE m.email IS NULL
You might also through a GROUP BY or DISTINCT in ... |
You could have a lot of duplicates out there. I'm not seeing the query error off the top of my head, but you might try writing it this way:
SELECT j.email
FROM jobseeker j
LEFT JOIN aspnet_Membership m ON m.email = j.email
WHERE m.email IS NULL
You might also throw a GROUP BY or DISTINCT in th... |
How to keep ReadDirectoryChangesW from missing file changes |
|readdirectorychangesw| |
There are many posts on the internet about the ReadDirectoryChangesW API function missing files when there is a lot of file activity. Most blame the speed at which the ReadDirectoryChangesW function loop is called. This is an incorrect assumption. The best explanation I have seen is in the following post, the commen... |
ls -atrd */ | head --lines=-4 | xargs rm -rf
**Edit:** added 'a' argument to ls |