Posts

Showing posts from April, 2011

Django form redirect using HttpResponseRedirect -

So it can not be very difficult but I can not understand it ... I To upload the file, I want my form in the dynamic (located at / file_upload / ), add it to the database, and then redirect to a new page where the parameter is the id of the field ( Is located in / file / 163 / ). I have set up the URLs so that / file / 163 / works fine if you navigate directly there, but I do not know / File / upload / My code is: def add (request): If request.method == 'POST': # If the form is submitted ... form = UploadFile Form (Request.POST, request.FILES) If Form Is_valid (): #DooStuff & amp; Add to database my_file = FileField.objects.create () Returns HttpResponseRedirect (reverse ('/ file /', args = [my_file.id])) I can not use it because I do not know that the field ID is going to happen until I manage the form in view.py, so the redirect should be in views.py. I guess Any thoughts? Your view should appear something like this: Def add (request...

php - Phar archive outputs jibberish -

I created my first four collection with the following code: $ phar = new Phar ('myphar.phar'); $ Phar- & gt; AddFile ("index.php"); $ Phar- & gt; Set stub ($ phar- & gt; build stub ('index.php', 'index.php')); The index.php outlined only one output: echo "I'm in a PHP collection!"; When I run the code above, myphar.phar is created and when I run on cli, the output is "I'm in a PHP collection!" However, when I call myphar.phar from a webbrover, it prints some strange characters like ???? ??? ? , instead of my index.php content and an error. I have added the following archive to add archive to my apache httpd.conf: AddType application / x-httpd-php .phar Does anyone know why it works on the clear, but not in the browser? Answer This problem is in detect_unicode setting. There is currently a bug in PHP () which __halt_compiler () does not work correctly if detect_unicode is enab...

internet explorer 8 - IE8 - How can I remove extra padding from an image? -

See this image: A clear understanding of what's happening Graphic for graphite I have added an orange banner to the interconnected solution around the world through a customized Joomla module; I made it easy to edit and update. But this resulted in adding extra padding at the top in IE8 - it fell and is OK in IE 7 How do I remove this extra? Padding? I have tried many CSS, but nothing seems to indicate anything to the problem. # header-bots .moduletableisw .isw {float: right; Margin head: 0px ;; Important 'padding-top: 0 pixels ;; Important '} I have got the most problems with CSS, but this one is me. Hope that would be a simple solution? Your CSS is invalid for beginner, it should be: # Header-bots .moduletableisw .isw {float: right; Margin-top: 0 px! Important; Padding-Top: 0px! Important; } (You can remove px when the size is zero.) Also check the margin / padding on the original element Do (S) like .moduletableisw and any spacing...

version control - Saving time in SVN post-commit hooks? -

At our workplace, we have begun applying appropriate SVN hooks, "proper" means "checking too many policies". At present, Pearl :: Reviewer Pearl :: Free Checking is enabled in our policy. However, especially in the latter it takes a lot of time that many files are sealed and the SVN post-commit will not return until the hook is over. Is there any way, I can save some time in the post-cut hook without sacrificing the policy check? If you only need some reports of errors) then you use the system to post some committed actions Can do for you. This system allows you to take any action after the changes made to your source control system. Example Scenario: Commit to some SVN repository After some time CC found this change and runs the script: Get the latest version from SVN Pearl :: Critics and Pearl :: Dexterity Run checks like if any fails Detailed error report Send me an email notification if necessary There are several good continuou...

dojo - Capturing Keyboard Events in Dojox GFX -

Is it possible to capture keyboard events in the diagram using Dojox.GFX? We have a simple graphical application that includes some of the shapes drawn on the surface, we want to add some simple keyboard interactions, e.g. Use "Ctrl + A" to remove the shape and to select all the shapes by using the deleted key. I tried to encrypt the size for "dokey.connect" and "size", but "onkeyup" did not seem to trigger that we were already capturing mouse events And they are working fine. David does not point to keyboard events They are essentially global, you can call them document or body . A handler should be attached worldwide.

Javascript: attaching OOP methods to events and the 'this' keyword -

I'm new to OOP Javascript and I'm having trouble with keywords in this . What I am trying to achieve: I have many dom objects and not only want to pose a common event to them, but a global container (to increase runtime performance) Keep some data about So what I do is basically this: function class hasdodops something () {/ * This keeps node ID for processing in the INIT. Nodes = new array (); / * Process node data for faster access * / this.nodeData = new array (); This.sthAddNodes = function (/ * id * /) {/ * Add node ID for local variant (this.nodeData) * /} function init () {/ * collects data from all nodes which was added before And stores it in .nodeData * / / * Here, surprisingly, it references' window element * / addEvent (window, 'scroll', this.scroll); } Function Scroll () {/ * Does the user do stuff while scrolling the page * / / * 'This' also reference the window element here * /} addEvent (window, 'load', this, etc.); } L...

SQL Server Express: REPLACE problem in SQL Server Mgmt Studio Express -

I have a major problem with the SQL function again in the Microsoft SQL Server Management Studio Express. Select (select 'Article number', 'S302', 'IX 2020') Select (select 'Article number') SELECT REPLACE ('ArticleNumber', 'S401', 'I0010') Select REPLACE ('paragraph number', 'S305', 'I 0050') Selection slots ('paragraph number', 'S306', 'S303' , 'I0030') Selecting place ('paragraph number', 'S304', 'I0040') 'I0060') From Tbl.Products Then with that selection, the Studio Express response Was not recognized. Depends on what I'm doing ... You need a nested place ... Change the location of the place Change Change Place Place (Article number, 'S401', 'IX 1010 '3030', 'I 3030', '3030', 'I 40040'), 'S305', 'I 20050', 'S306' 'I 0060'). .. or Multi...

iphone - NSDateFormatter dateFromString will not parse a particular date string -

Good day, I have an NSDateFormatter that does not like any particular string to convert I'm trying this special example 2009-10-16T09: 42: 24.999605 All my other dates are formatted and parsed can be done. / P> Here is the code that converts strings into NSDate. NSDateFormatter * dateFormatter = [[NSDateFormatter alloc] init]; [DateFormatter setDateFormat: @ "yyyy-MM-dd'THH: mm: ssssssss"]; [Set setModifiedAtDate: [dateFormatter dateFromString: [orderDataDictionary Price ForKey: @ "ModifiedAt"]]]; order.ModifiedAtDate is zero since the date FromString call. In any other case where their dates can not be converted into NSDates? Thank you, I remove the subsecond field from the formatter and get the date of the parse Was able to: NSString * test = @ "2009-10-16T0 9: 42: 24.999605"; NSDateFormatter * dateFormatter = [[NSDateFormatter alloc] init]; [DateFormatter setDateFormat: @ "yyyy-MM-dd'H'HH: mm: SS...

c# - 3 tables, 3 classes, help designing my classes effectively -

I have 3 database tables, all of them have 5 columns. They are different in that table # 2 and each of the table # 3 has another ID column. I do not want to create 3 different classes for this, but the problem is in my Database Assistant category, a method that loads classes like: public static load class 1 (SqlDataReader Reader) {Class 1C1 = New Class 1 (); C1.prop1 = (int) reader ["prop1"]} I do not have to create 3 different load supportive methods, and all of them have to copy the code to them. (I do not feel like making 3, but only each has to set different fields). Four methods: one and three others who load the main field, call the core method and Load additional fields. It will work best with a base class with core properties, and 3 subclasses. Int field2; Int field3; Int field4; Int field5; } Public square all 1: core {field 6; } ... public static zero loadcore (core c, datatelle dt) {c.field1 = dt.getField1 (); // in fact a d...

visual studio 2008 - VS2008 plugins to add regexp replace to the IDE -

Image
I'm looking for a way to search / replace VS IDE regex-aware, like regex notepad ++ . Is it possible? Click on the "+" sign to the left of "Search Options" and click "Use" Select the check box next to, and select "Regular expressions" from the drop down list. Edit:

How do I get entries in the next month from oracle sql? -

Suppose I have a table that has "user_id, date, score", and every user has exactly one score per month, but not always the same day. I want a query that contains "user_id, date, score_delta", where the score_data is, how much will change between "date" and next month? Will I have to lame for some time (to_char (date, ...? here in a way (Score is as an exercise for the reader): create table score (user_id VARCHAR2 (32), test_date DATE, score number); Score value (IN 'U1' , INSERT ('U1', SYSDATE-31, 89) in the values ​​of digits, INSERT ('U1', SYSDATE, 92) in the values ​​of digits; INSERT ('U2' SYSDATE-61, 65); INSERT ('U2', SYSDATE-31, 89) in the properties of numbers; INSERT ('U2', SYSDATE, 84) in the values ​​of numbers; D; SELECT s1.user_id, s1.test_date, s2.score-s1 (score: score by score) at s2 (s1.user_id = s2.user_id and trunc (plus_memo (s1.test_date, 1), 'mm' ) = S2.test_date); USER...

sharepoint - PerformancePoint Dashboard Designer Error when creating a Filter - No Filter Data Retrieved -

I am trying to create a filter using PerformancePoint's Dashboard Designer. After going through the wizard, the "Confirmation" page displays the following message: No filter data has been retrieved WARNING 1: Filters created But no data was retrieved. To resolve the problem, follow the steps below. 1. Verify that the data source for this filter is properly configured. 2. Check the server event log. Additional information about this problem may have been recorded. The data source is ok ... I used the data source to create the report that the filter is considered filtering ... no problems with the report. For logs, the only disturbing place is when the call is made from the DisplayPoint server (SharePoint group part) on the SQL Server - Performance Viewer on the Performance Viewer has a long message in which the important part is "Remote Connection has been forced to close an existing connection. " Does anyone else have problems with the filter in ...

concurrency - Can you lock on a local object in Java? -

I have a snippet of this code personal templates recovery (string name) {TemplatesWrapper T = XlCache.get (name); Synchronize (t) {if (! T.isValid ()) {xlCache.remove (name); Return tap; }} Return t.getTemplate (); } xlCache is a concurrent hashpe ; My reason for syncing on t is that 2 threads can be televised where Thread 1 is verified that Verdet Thread 2 has already removed the object from the map and then A NullPointerException be thrown is my belief correct because I know that concurrency is one of the more difficult things to think about it and then for my basic question , Can i t Can lock me, even if it's local? And this is also the private method that makes a call from the public method, does it make a difference? Edit: My basic premise is that NullPointerException has been thrown because remove () returns boolean Synchronization was making profits; However, my question was locking on the local object. Answer Concurrent HShap (and...

objective c - It's Possible To Develop Using Cocoa In Windows And Linux -

I am starting to learn objective-and I do not have Mac (and I do not have a plan). But as I saw that cocoa is a very good framework for developing in the objective, I want to know: Is it possible to use cocoa in Windows and Linux? Thank you. I think your best bet is to get Mac if you want to use cocoa. You really will not regret it GNUSTEP is a clean solution, but it is impractical to distribute the applications built using GNUSTAP, because (as far as I know), the client must run the runtime to work. . Cocotron is a wonderful project, right, and in the future, it can be useful for you if you want simple applications to run on both Mac OS and Windows, but you still have to use it Mac will be needed. If you are interested in using Objective-C with a framework like Coco, but do not want to make Mac, why do not you try with web application development? Objective-J is an implementation of the Objcective-C-like language in Javascript, and Cappuccino Objective-J has a very good c...

multithreading - Opening multiple sessions simultaneously in NHibernate -

Finally, I thought what is wrong with my code, but I'm not sure how to fix it. I have some background processes Those that are running on a separate thread do some database maintenance tasks. Here's an example of what's happening: // An example example of both processes is fascingitry / but open different gestures // it is running on its thread, Public Zero Short Rints () {(Var Session = _sessionFactory.OpenSession ()) {// Some quick sessions here Update (MyCard); }} // This is the public running on another thread LongRunningTask () ({var session = _sessionFactory.OpenSession ()) {// Do some time here}} We say First of all, let's start the longing task , although this is going on, I start the ShortRunningTask on the second thread. Shortcutting Task ends and closes its sessions once the LongRunningTask ends, something to do with it, but there is an error This session has already been closed. Obviously this is happening that ISessionFactory.OpenSession ...

ADO.NET (Sql Compact + MySQL + IBM db2 expressC) -

I am developing an app in which a central database user can add entries, the database should be on a server, but I want users to add entries offline. When the connection is available, the app will be synchronized with the main DB. So, I think I need 2 databases - a small app on the cabinet for windows in C # on each client machine to use the main cell (preferably Linux) on the server and as a buffer when offline Will be coded. I am having difficulty in deciding whether to use the database and whether I can take advantage of any replication technique to make it easier. Besides, I do not want to pay for anything;) So I think my questions are ... Do I have ADO P> I recently dubbed IBM's DB 2 has searched for Express C, but I'm not sure that it is server-free as well as the server is installed. Do anyone know Can firebird be server-server or server-can I repeat between them? Is server mode able to use heavily? Just two questions your question; I do ...

Hosting requirement: What does WCF need to work? -

I plan to start development with WCF this weekend. Before I get far away, I would like to know what I want from my web host? What is the need to run our server to enable WCF? Is this standard ASP.NET 3.5 SP1 stuff? Does the host need to do anything in our IIS configuration? I am currently hosting our ASP.Net App, Company Website etc. With the third party hosting service Due to our size, cost etc. we are using a shared hosting plan and getting some limited access to the channel IIS. I hope we have no problem which limits our ability to use WCF. If you want to host your WCF service in IIS, you need IIS6 (Win Server 2003) or preferably The ability to create IIS7 (Win Server 2008), .NET 3.0 (or preferably: .NET 3.5 SP1) framework, and virtual directory is required. IIS (So, you need at least some degree IIS configuration) This is it! :-) Mark

MySql variables and php -

I am getting an error with php in order to format mysql_query () in php to format this string What is the right way? SELECT SELECT SELECT (*) Agents @AgentCount; User_Agent_English, User_Angent_Oursal, US.___Gent_Aginal, COUNT (User_Agent_Percade) ACC, COUNT (*) / (AgentCount) Percentage by agents user_agent_preser order DEC limit limit 50; In PHP, how am i setting $ query $ query = "SELECT count (*) agents @ agentcount; SELECT user_agent_parsed, User_agent_original , COUNT (user_agent_parsed) ascount, COUNT (*) / (@AgentCount) as a percentage by user_agent_parced by URI date DESC limit 50 "; This exact query will work properly if I put it in MySQL directly through a command line session. Do I need to release two separate php calls from mysql_query () and store the results first? I get the following error: There is an error in your SQL syntax; Instead of using a sub-selection and instead of using the 'SELECT user_agent_parsed, user_agent_original, ne...

c++ - Call pure virtual function from parent class -

I am very new to c ++, but I think I understand what's going on. Parents are trying to call the pure virtual member function in class guardian class. I thought that by overriding the virtual function in the child class, it would be named instead. What am I doing wrong? For me in my parents. class parents {public: virtual zero run (=); Protected: / ** Function for starter routine and it will call * run () defined by the appropriate child class * Starter Function * for / static zero * init (zero * arg) for @arum arg argues; }; I'm trying to do this in parent.cpp zero * guardian :: init (zero * arg) {run (); } In my child. I have this: Category: Public Generator {Public: // ... Virtual Zero Run (); // ...}; And I have child.cpp in: zero hair :: run () {sleep (10); } The function in parent.cpp is init, where it fails to compile. How do I call the derivative function from the original class? All my googleing has turned notes on just calling the virtua...

How to instruct linq to sql to update table columns to their default values on UpdateOnSubmit/SubmitChanges? -

I have a link for the SQL unit, which emits the following two SQL statements: UPDATE [address type] SET [name] = @ P4 WHERE ([surrogate] = @ P) and ([name] = @ P1) and ([last updated] = @ P2) and ( [Last updated] = @ P3) - @ P: Input unique identifier (size = 0; prede = 0; scale = 0) [b0cf44d9-c6ba-de11-b194-001e37f334ea] - @ P1: input warcur (size) = 11; PRESE = 0; scale = 0) [Residencial] - @ P2: Input DateTime (size = 0; PREC = 0; scale = 0) [16/10/2009 23:43:28] - @ P3: Input NVarChar (size = 23; Prec = 0; scale = 0) [Luciano-Nacobiu Lucino] - @ P4: Input Worker (size = 4; prep = 0; scale = 0) [Home] - References: SQL ProvWwder (Sql2008) Model: Attributed Metadald Build: 3.5 .30729.1 UPDATE [IDECT]. [Address type] SET [name] = @ P4 WHERE ([surrogate] = @ P) and ([name] = @ P1) and ([last update] = @ P2) and ([last update] = @ P3) - @ P: Input Unique Identifier (size = 0; PRECI = 0; scale = 0) [B1 CF-44D9-C6B-DE11-B194-001e37f334ea] - @ P1: Input VarChar ( Size = 9; Prec = 0;...

what's the mechanism of sizeof() in C/C++? -

It seems that sizeof is not a real work? For example, if you type: / P> int i = 0; Printf ("% d \ n", size (++ i)); Printf ("% d \ n", i); You may be like the output: 4 and when you gather the code , You will get 'sth like this: movl $ 4,% esi leaq lc0 (% rip),% rdi xorl% eax,% eax call _printf Therefore, the compiler has directly placed the "4" as the parameter of print-aided. Then what does the shape do? You know, why there is a reason; C99, volume 6.5.3.4, §2: sizeof operator generates in the size (bytes) of its operand, which can be an expression or parentheses The name can be a type of shape determined by the type of operand the result is an integer if the type of operand is a variable length array type, the operand is evaluated; Otherwise, Operand is not evaluated and its result is an integer constant . In response to the iPad's comment, here is an example for C99 variable length array case: #includ...

Best photo app for Django to sell photos online -

I have a client who is an event photographer and they want to be able to sell online pictures, the main difference from personalized photo apps One needs to upload 100 photos at a time The ability to tag photos in batches with the event name (before uploading or after uploading) Integration with PayPal Is there an existing app that is suitable to know? If not, do you think I should try to do something like photologues or start from scratch? not an app can be a mix of different apps For best navigation - Help with photos

java - JiBX binding - root object extends an object -

Is it possible to pair root objects with super fields? I have a very complex unit (institutions). I've already lost it): This is my code status: public class CoreRestWrapper {Private integer page; Private integer per page; } Public class UserWrapper CoreRestWrapper Extended {Private Collection & lt; UserCVO & gt; Users; } Public class UserCVO {Personal UserVO userVO; Private map & lt; String, Usmata & gt; Meta; } The public class extends up to the UserVO baseview {// nothing here} public square bsebio {private integer ID; Private string nomenclature; } Public class UserMeta Meta {// nothing here} Public class meta {Private string key; Private object value; Private string type; // string, integer, boolean, date} UserWrapper is my root object. I want to see my response XML like this: Or maybe & lt; User page = "1" perPage = "2" & gt; And then just the user tag ... Is it also possible (to handle the beginner in GBX)? ...

c# - How to remove elements from a generic list while iterating over it? -

I better pattern to work with a list Looking for the elements of which each process is processed and then removed from the list based on the result You can not use . > Remove inside foreach (Miscellaneous Elements) (because it was the result in the collection; the calculation process may not be executed. exception) ... for you (int i = 0; i & lt; Elements. Count.); I ++) and . Remove (i) because it disrupts your current status in the collection related to i . Is there a great way to do this? Reverse your list with the loop: for (Int i = secure padding list calculation - 1; i> = 0; i--) {// some code // secure pending list. Outgoing (i); } Example: var list = new list & lt; Int & gt; (Enumerable.Range (1, 10)); (Int i = list.Count - 1; i> = 0; i--) {if (list [i]> 5) list.RemoveAt (i); } List.ForEach (i => console. WriteLine (i)); Alternatively, you can use it to test against a WordTech: safePendingList.RemoveAll (item =...

Start tracking branches/tags on a git-svn repo that was tracking only trunk -

I have started tracking a svn repository with git by cloning my trunk directory. Now I want to track other stuff, but I do not want to clone it again because it takes a lot of time to use - stdlayout and I already have most code local level On. How do I change the repository layout to match the svn trunk / branches / tags without cloning again? old .git / config : [ Svn-remote "svn"] url = svn: // host / project / trunk fetch =: refs / remotes / git-svn new .git / config : [svn-remote "svn"] url = svn: // host / project fetch = trunk : refs / remotes / git-svn branches = branches * *: refs / remotes / * tags = tags / *: Refs / remotes / tags / * now run git svn reset -r1 -p; GIT SVN Fetch; Git svn rebase . No, this is not very different from cloning a git svn again - adding branches means that git see more merge which means That the content git tracking has changed, so the git-svn needs to be rebuilt.

Best YouTube gem for Ruby? -

Is there a definite gem for the YouTube API? I'm trying to use youtube_g, but it starts breaking some basic stuff. Found a list of alternative Gitob clients, they probably do better: Source:

Visual Studio, Intel Visual Fortran, and Visual C/C++ mixed-language compile -

With Windows Fortran Compiler v11 on Windows 7 x64, working with Visual Studio 2008 Pro. I is an Intel Visual Fortran project set up with all foreign source files, I gradually want to replace all these sub-routines with C-C ++ (in fact the plus-bonus issue). Just click on the source file in Solution Explorer and add one to the "Add existing item" list. CPP or. C or cuda file ... but it never gets compiled. Thus any interface for the C code written in Fortran code always fails in the link phase. How does one get mixed language projects like this? Google has failed me, and what I find is a description of the actual interface code, in which instructions for implementing the Visual Studio Build system are not given. Thanks in advance. A visual studio project can contain code elements from only one language C ++, CUDA and FORTRAN You must install a visual studio solution to mix. Then you are free to integrate many languages. A useful guide for installing a CUDA m...

Combining Audio Files as One Properly on iPhone with NSData -

I am using AVAudioRecorder by recording the recording of an audio file every 15 seconds, which is the first recorder file By adding an NSMutableData object and using the appendData method. Then I record it again in the same method so that the recording is "continuous". The problem is that as soon as you [stop the recorder], it saves / closes the audio file on the specified URL. This is fine because I can fill an NSData object with it and add it to my NSMutableObject and then I can write on the same file URL. The problem should be incorrect with some header information because its first part of the audio only My question is how do I combine files properly, even adding two audio files and seeing AVAudioPlayer as a file in simple form. Any thoughts? one The audio file has a header that specifies how many samples are in the file and how long it should be part of the data. Any data added to an existing file will be ignored. This is the reason that you only li...

How do websites post to Twitter, on my behalf? Is this OAuth? -

I want to allow my website to post (authorized user) for Twitter (eg update status). How do such websites do this? like. TwitPic, etc.? I know that source website -> twitter -> had to authenticate me at one point with my twitter account, just like I used to openID -> log in to open id. Is this OAuth / Twitter's OAuth API? If so, then I believe that Twitter has sent me some secret tokens or some things that I have stored in the database against the current user (which is actually an OpenId auth'd user). No password in my DB!) I have used basic authentication using exactly the Twitter API. Finally, if it is OAuth, then there is any NIT Tutorial (or .NET MVC tutors) in it and Twitter? Thanks guys! Yes, it's oyoth. Here is their

css - jQuery - dynamic div height equal to the height of the whole window -

मैं यहां पाया कोड का उपयोग कर रहा हूं & lt; script type = 'text / javascript '& gt; $ (फ़ंक्शन () {$ ('# center')। सीएसएस ({'ऊंचाई': (($ (खिड़की)। हाइट ()) - 162) + 'पीएक्स'}); $ (विंडो)। Reset (फ़ंक्शन () {$ ('# Center')। सीएसएस ({'ऊंचाई': (($ (खिड़की)। हाइट ()) - 162) + 'पीएक्स'});});}); & Lt; / स्क्रिप्ट & gt; अब जब आप खिड़की का आकार बदलते हैं तो ऊंचाई परिवर्तन ठीक होता है, लेकिन अगर आपकी ऊंचाई नीचे स्क्रॉल नहीं होती है, तो इसका अर्थ है विंडो की संपत्ति में ब्राउज़र विंडो के आकार से परे चीज़ों को शामिल नहीं किया गया है इसलिए यदि आप नीचे स्क्रॉल करते हैं तो ऊँचाई बढ़ती नहीं है तो मैं क्या जोड़ूंगा कि वह संपूर्ण सामग्री का आकार खिड़की के आकार का नहीं होगा जवाब विंडो के बजाय दस्तावेज़ का उपयोग करें & lt; script type = 'text / javascript' & gt; $ (फ़ंक्शन () {$ ('# center')। सीएसएस ({'ऊंचाई': (($ (दस्तावेज़)। हाइट ()) - 162) + 'पीएक्स'}); $ (विंडो)। Reset (फ़ं...

domain driven design - Can Aggregate root entity calls Repository -

My question is Is the method of the only root unit in which it will call a repository? I know that Eric's book is clearly not saying anything, but it should not be confirmed. ( One more thing is where can I get a unit test example for domain driven design? It is a bit of a religious question. Some do not see any problem with it, while others may believe it is a heresy to do so. As always, I keep away my repository from my domain model (and there was an upstream service object deal with the repository), I had a project that had "required" available stores from the domain model. Because of this domain object, there was a need to retrieve specific data based on the usage of trade logic => specification objects / linch to filter the data Responsibility and knowledge were related to that domain object) and / or for demonstration reasons. There is a warning around doing this that the domain is in the object How to get the reference of the positories - In t...

c# - Using bitwise operators -

I am studying C # and running on land familiar to my old work in C ++. I never understood the cause of bitwise operators in a real application. I have never used them and they never had the reason to use it. I am reading how they work; The example shift below shows the bitwise operator. What does Bitwise operators mean, their use and how they work? Maybe I'm missing something in some wrong logic. byte bit comp = 15; // bitcomp = 15 = 00001111b byte bracelt = (byte) ~ bitComp; // bresult = 240 = 11110000b Here is an example for a complementary bitwise operator: byte bit comp = 15; // bitcomp = 15 = 00001111b byte bracelt = (byte) ~ bitComp; // bresult = 240 = 11110000b Add a specific use bits that represent mutually exclusive 'flag'. Example from MSDN: day code 2 {none = 0x0, Sunday = 0x1, Monday = 0x2, Tuesday = 0x4, Wednesday = 0x8, Thursday = 0x10, Friday = 0x20, Saturday = 0x40} Class Mylanes {day 2 meeting day = day 2. todewar | Days2.Thursday; Day...

c++ - Problems communicating with external editor in Qt4 -

I'm writing command line QT4 script (using QCore application) on Mac OS X. Using C ++ programming code optimized with QT4, Second Edition P. 313: QTemporaryFile Outfile; If return! (OutFile.open ()); Qustring filename = outfile.philname (); QTextStream Out (and Outfile); Outside & lt; & Lt; Initial_text; OutFile.close (); QProcess :: execute (editor, QStringList () When run with the editor set to "/ usr / bin / vim" above, "Wim: Warning: does not have input terminal" is printed, then vim With initial text (string initial_text); However, I am unable to edit or quit because the blue print by pressing Escape is done. [In the case of cursor, equal to every other key. When the editor is set to "/ user / jason / bin" / met "(textmat command-line utility), textmat launch, without initial text document Edit and save, and when I leave, the application reads in the initial lesson (which should have been overwritten). I'm worr...

io - programs running in parallel, read/writing in C -

I'm considering a set of 4 programs: (Prog 1, Prog 2, Projection 3, Project 4) Interacting with 4 files (File A, Prog2: A reads and writes the file Proof 3: reads file A, and writes file A (append) Program 4: Reads file B, and writes the file to AD (Append) Or maybe Prag 1, also read on startup, And write consistently to say filex. Now all 4 programs will run simultaneously (possibly on the network, but this should not make any difference). Will this work? I need to set a "strawbos" or "busy" signal (I can say that with MKDIR and RMDIR)? I think you need some kind of real fifo structure, which is also called pipe The Ta. can be found a few examples of Linux, named pipes under Windows

programming languages - What programs should I learn to be able to do computational modeling? -

I have received some free time and I want to learn programming language or two that I can use for computational modeling. I am (I am in cognitive science and psychology). I'm not sure if I'll finish the nerve trap, machine learning, AI or some other way, then I'm just looking for a good, broad base, like a nudge in the right direction. I just know that there is a little bit, so I have a way. Can you recommend any programming language which is commonly used in computational working labs? I am hoping to use what I learn in undergraduate training in a few years. I also need to take a little more math, like differential equations and basic linear algebra do you think I needed something else? Thank you very much. FORTRAN is still very common in scientific applications. LISP is a great choice (especially for AI) These days, Python are very trendy in academic circles. Used to be. TL; Dr. Lysp Know you will not regret it.

Game programming with Java in Linux -

Recently I have been craving some sports programming. I mainly use Linux, and wondered if there is a good graphics library for Java development on Linux? Google did not change very useful information on this topic In addition, will any other language be better? I would like to use Python - Ruby and Java are my two favorite languages ​​Unfortunately Linux does not have much talk about game programming. Any suggestions / resources? Easy portability or cross-platform functionality will also be great. Oh, and I like 2D graphics. : What is the API mentioned in the API. The topics are divided into three sections: Java 3D API, non-standard input devices for playing games, and joggle. Java 3D is a high level 3D graphics API, and Jojiel is a low-level Java wrapper around the popular OpenGL graphics API. You will see three non-standard input devices : Webcams, Game Pad, and P5 Data Gloves. Anyway, you'll be using several other game-related libraries : JInput, JOAL, JMF...

c# 3.0 - Dependency injection with Unity and ASP.NET MVC -

I am trying to use unity as my IoC container, which "works" a bit. From Snip Global.asax: Secure void Application_Start () {// ...) Left / Out of Settlement with Microsoft Unity Dependency Injection () dependency injection; } Private Zero Dependence Injection () {var Container = New Unity Container (); Container. Registration Type & lt; ITimeregEntities, TimeregEntities & gt; (). Configure & Lt; Injectmen & gt; () .ConfigureInjectionFor & lt; TimeregEntities & gt; (New injection signature) ();) Container. Registration Type & lt; Timestridge controller IHelloWorld, Timelargestring Controller. Marie Sheld World & gt; (); // ### The problem here ### Container Registration Type & lt; ITIMEregistreringerRepository, Timeline Respository & gt; (); // ### END- Problem ### var Factory = New Unity Controller Feature (Container); ControllerBuilder.Current.SetControllerFactory (factory); } This dependency has been imposed on my 'tim...

python - How to generate random 'greenish' colors -

Anyone have any suggestions for making random colors that are all green? Right now I am creating color by: color = (RANDIN (100, 200), RANDIN (120, 255), RANDIN (100, 200)) It mostly works, but I get lots of brown color. Simple solution: Use color space instead of RGB RGB later If you need it). Inter Tupal means: Where values ​​in HSL for RGB red, green and blue, H color (for example, green 120 degrees or 0.33) and S. is for V for saturation and brightness. Then put H at a fixed price (or you can add it to a random random number by adding / randomizing it for more random colors) and make S and V random. See the article.

java - eclipse 3.4 can't start -

Tomorrow, I try to start eclipse.exe (in the eclipse folder) by clicking on eclipse 3.4, and the normal form I'll run from Then last night, I update the windows. Today, when I try to run Eclipse 3.4, there is an error in the error message that you can get here I use Windows XP SP2 and Java 1.5 update 14. I do not know how to fix this, so I uninstalled my jdk1 5.14 then installed jdk1.5.21 The problem still exists if I use the bat file (eclipse.bat) with the contents of the file as follows: eclipse -vmargs -Xmx256M It will run normally. But when I change to- Xmx512M or (> = 512M), it will display an error like a screenshot. The same problem occurs when I start with Eclipse 3.5. But when I start with eclipse 3.3, eclipse 3.3 starts normally (I think that eclipse 3.3 uses 3.4 less memory than the above, & lt; = 512M is tested only, but How much memory eclipsed by eclipse 3.3) I think the problem is with my windows. I really appreciate it if someone can help wi...

c++ - Load multiple copies of dll in same process -

I have a DLL built by a third party that has some type of internal data structure which limits it to the size of X elements. is. So basically, there is a line in the form of X in it. From now on I have learned that the process of DLL is copy, but is it possible to load DLL more than once? Maybe every thread? In C # Or in C ++ / CLI? I am trying to load the original C ++ DL. Unfortunately, the NT core of a public interface to leave the pool of preloaded DLLs Does not disclose As such, you have been left with some choice: Use copy, hardlink, silicink, and / or retrieval points to fool the loader into many different DLLs. . Use multiple processes, and load one process per DLL. Write a new DLL loader (not too much for the unconscious heart!) Explain the DLL vendor to fix it (a DLL loader is more likely to be harder than typing :)

JavaScript performance benchmark in handling events at parent for all child elements -

It is common for parents to handle incidents for child elements in the bubbling stage on the node. However, I'm not sure there is any display problem in it. For example, consider the following structure: & lt; Div id = "parent" & gt; & Lt; Div & gt; Child1 & lt; / Div & gt; & Lt; Div & gt; Child2 & lt; / Div & gt; & Lt; Div & gt; Child3 & lt; / Div & gt; & Lt; / Div & gt; Now if I want to handle onclick on every child, I can attach every child div or just one handler to the headliner because the event is going to be bubble is . So what was the best practice if you were curious? Are there any performance concerns in two perspectives? If you have a large number of children, then I would recommend to go for you. With experience, I can tell you by adding performance handlers, memory leaks and browser locks (mainly IE), by adding event handlers to the number of very large elements. The event...

openUrl in landscape mode in iphone -

I am trying to open urls via Safari in landscape mode. But still the following code is not able to do this. [[UIApplication shared application] OpenRel: [NSL URL URL with string: @ ""]]; [[UIApplication shared applicant] setStatusBarOrientation: UIInterfaceOrientationLandscapeRight Animated: Yes]; Landscape mode depends on device orientation Mobile Safari One There is a third party (actually Apple is) and you can not set landscape mode in an application that you did not develop. In fact, even if you set orientation on your application, as soon as the Mobile Safari is launched, the setting is very much.

PHP: Send Email via cronjob and set amount of email send per mins -

I have a program that the group uses to send email, I set up this program for every minute. I am executing / minutes per second, and check whether the time schedule in DB matches my scheduled schedule. If it is correct then the program can run the email and send it, otherwise ... The problem is that I want to set the quantity of sending the user per minute per minute, to send me to say 10000 There are emails, and I want to send 3 emails per minute, something like that, but the way I searched while using Cronzab, (set cookie? Can you record the current email for DB?), The Onki I also know that if I use the sleep do, it will cause Php execute limit error ... How is it that no one can tell me? Or are you using another method to schedule the schedule? Pear? If using other methods, how can it show up briefly to use? Please feel free to set this configuration at the application level instead of the cron job level. Please feel free to use this configuration at the application level. ...

email - Which symmetrical encryption algorithm to use to encrypt e-mail address(short message)? -

Which identical encryption algorithm is used to encrypt an e-mail address (short message)? I would like to keep the ciphertext comparable in the length of the perestext. Symmetrical block ciphers produce the same length as the input, in multiples of the block size (usually But 8 bytes or 16 bytes for AES). Because the output is always many of the block size (in fact the input is always the same shape as the input and input should be multiple of the block size) so you can not know the basic size of the plain text. Common encryption schemes solve this by adding a padding scheme, such as PKCS, ISO 10126 or ANSI X923, provide information about the length of the original clear text in the last block. If the size of the explicit text is greater than one of the 8 (16 AES), then another block is added to the encrypted text if the original size is not multiple of the block size, then the encrypted size is next multiple Round up to block size will be rounded. For this you should add...

Vitual Studio Design view working asp.net with CSS -

I am using external CSS to control the performance of my control. And when I see the page in the design view of VS 2008, it looks messy. So whenever I change a value in my CSS, instead of checking it in Design view, I should be forced to run a web page, just launch my browser to see the changes I made Please. Personally I'm using the firebug with your CSS running your application only by you stylesheet With the happy changes being saved back to the right thing? Not even in debug mode

reporting services - Is there a way to put subreports in headers in SSRS? -

I would like to use a sub-report, because it is used on many reports, in the title. However, sub reports will not go to the top nor will they display values. However, the parameters will be cured only. Any suggestions or references to how to bypass it? I approve it on the other side. Created a report that included headers and footers in bus . We have just created a sub-report. I know that this is not right anywhere. But it works for our reports. Another option is to create an assembly that pumps the data into a field in the title. If none is graphical at the top, then works fine ...

.net - Visual Studio - Runtime impact of conditional and disabled breakpoints -

Spending a bit of time thinking that why my app was running a special scenario with the attached debugger, I came to know Due to this being a conditional breakpoint (whose position was never found) it seems reasonable because the CPU will indicate the breakpoint and will need to evaluate the situation before allowing VS to continue. These infections should be expensive. I think a breakpoint has not been implemented in the code path, there is no runtime effect. So my question is doubled: > Is there a resource that can quantify the cost associated with conditional breakpoint, and if so anybody What can you do to reduce your runtime evaluation costs? Is there a 'disabled' breakpoint? By the handicapped I mean that VS Displays the breakpop marker in the drain with a hollow cycle. Of course if I do not mean anything mentioned above, please point me to the right direction. The cost of conditional breakpoint is difficult to assess. Assessment of expression in co...

reflection - Scala: set a field value reflectively from field name -

I am learning Scala and can not find out how: I use Scala Objects and Google There is a mapper between the appenzin entities, so if I have such a class: class student {var id: long var name: string} I need to make an example of that square, in Java, I'll get the field by its name and then field.set (value, value) but I do not know that Areas to look at scala. I can not use Java's reflection because the area of ​​the student is seen as private and field. The set throws an error due to that reason. Thanks Scala gets converted into a private area, an eater and a setter is. So by using a string to identify / set it to get a var, you have to use the Java Reflection to find the gateter / setter methods. Below is a code snippet that does this, please note that this code runs under Scala 2.8.0 and there is no existence by the name and errors of the duplicated method. class student {var id: long = _ var name: string = _} implicit def reflector (ref: AnyRef) = ne...

css - Float and Height -

I have a div named footerWrap, in which there are 3 unordered lists, I left all unchanged lists. My intention was to raise the footprint in height according to the height of the Anarchold inventory. However ... in all browsers (IE6 exept) ... unordered lists passed on div ... like they had z-index subscriptions! I tried to place a div in the end, with clear: Everyone, and I also tried to float: none on div # footer wrap This is my docotype Is: & lt ;! DOCTYPE html public "- // W3C / / DTT XHTML 1.0 Transcription // N" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> This is my complete CSS code: div # footerwrap {height: 180px; Background color: # 5c5c5c; Background Image: URL ('../../img/bgFooter.png'); Background repeat: repeat-x; Background position: top; Padded-top: 20px; Padding-left: 15px; Margin Top: 20px; } / * Menu Footer * / div # Open footer # Main menu, div # footer wall ul # My menu, div # Footer wall ul # Oth...

What does it mean when someone says that Perl is an "expressive language"? -

What is an expressive language? What does this mean when someone says that Pearl is an expression language? An "expressive" language is a language that makes you easy to logical concepts in code Allows to express from People often say Pearl is meaningful because it allows you to use many different ways to express a specific concept, so it is very flexible in this regard (There is a lot of debate about whether this is a good thing or not, though ...)

nhibernate - Advice re. Windows Forms application - "local" and "network" modes -

I have started creating a windows form application, this application will work in two different modes: Local (1 user, open and save files like Microsoft Office applications) Networks (many users, all shared databases in another host of one network) For local mode I am planning to use a SQLite embedded database, I have some tests There are new and it has worked very well networked mode I'm thinking about SQL Server Express are both solutions free. Now I am concerned about the best practices of architecture for this app. I usually split my application layers in 3: presentation, service (or business logic) and data access. In your opinion, what are the "best practices" architecture for this kind of application, especially data access layer in those 2 modes (local and network)? For example, should I create a DAL class for the local and a DAL class for the network and create a factory for them? Do you think nHibernate will work for this scenario (then I could...

vba word 2007 - protect document but enable toolbars -

I have a document with sections that are safe and unsafe. The formatting was enabled with the 2003 class unsafe - especially bullet and numbering now with Word 2007, even if the same category is unsafe, bullet and numbering are disabled. Is this way capable? I tried to play with the commanders but nothing worked. Like applications Commands ("formatting"). Enabled = true There is a great chance that any code written by you will be re-released in Office 2003, 2007 Is going to behave differently, as far as things like "commandbars" are run I am currently using thumb rule is that if Office 2007 uses a different UI to handle it, So the API also changes for the function. I try, not the CommandBurs object EnforceStyleLock parameter that can be helpful.

sql server - Backup and Restore through the Entity Framework -

I am working with about 50 tables with a SQL Server database and there is a lot of relation between those tables Already has a backup and function restored which will receive all the data from the model, it will export it to XML which can re-import it again in the clean database, but when there are some major structural changes in the unit model, this import / Maintain the export A lot of work. I want a more dynamic solution. Is there a more dynamic solution for exporting data from an entity model and importing it back into a clean database? Oh, before I forget ... I do not have direct access to the database, not its connection. I can get everyone and use all this unit frame object ... I'm passing it back to my server support team to data app to an app developer There seems to be a little strange to worry about restoration.

WPF Popup tab key bug -

I have a WPF popup control with a list box and a button. When I click on the button, it should be disabled. The problem is that, when I disable the button, then the tab pops out of the popup. I have the isEnabled to wrong, tried to set the focus on the listbox, but if that was not working, how can I set tab focus to ListBox inside popup control? This is my code. Window1.xaml: & lt; Window x: orbit = "wpfApplication5.Window1" xmlns = "http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns: x = "http://schemas.microsoft.com/winfx/ 2006 / Xaml "title =" window 1 "height =" 300 "width =" 300 "& gt; & Lt; StackPanel & gt; & Lt; Button name = "open button" content = "open" /> & Lt; Popup name = "popup" placement = "center" & gt; & Lt; StackPanel & gt; & Lt; List Box Name = "List Box" / & gt; & Lt; Button name ...

c# - Storing a short date in a DateTime object -

मैं एक छोटी तारीख की तारीख (मिमी / दिन / yyyy) को डेटटाइम ऑब्जेक्ट में संग्रहित करने की कोशिश कर रहा हूं। नीचे दिया गया निम्न कोड मैं वर्तमान में करने की कोशिश कर रहा हूं; इसमें समय (12:00:00 पूर्वाह्न) शामिल है जो मुझे नहीं चाहिए: ( दिनांकटाइम अच्छाडेटाल्डर = कन्वर्ट.ToDateTime (DateTime.Now.ToShortDateString ()); परिणाम 10/19/2009 12:00:00 पूर्वाह्न डेटटाइम एक पूर्णांक है जो कि डेटटाइम के दोनों भागों का प्रतिनिधित्व करने के लिए समझा गया है (यानी: तिथि और समय)। आपके पास हमेशा दिनांकटाइम में दोनों तिथि और समय होगा। क्षमा करें, आप कुछ भी नहीं कर सकते इसके बारे में। आप उपयोग कर सकते हैं। तारीख के समय प्राप्त करने के लिए दिनांक। इन मामलों में, समय हमेशा 12:00 रहेगा लेकिन अगर आप इसे नहीं चाहते हैं, तो आप उस भाग की अनदेखी कर सकते हैं।

Members only based plugin for Wordpress -

Can someone recommend me a good member-only plugin? If users are not signed in, then I want to hide the page (and their tabs). I have yet found: 'subscriber access' which is not hidden tab' 'wp-members' which is 2.8.4 'User Access Manager' which was very complex clunky to be useful There should be something fundamental for what I need, but so far There is no luck. A WordPress heavy (popular theme framework) is written, recently released a comprehensive user management plugin Among other things, your blog can only be changed to a logged-in location: Personal Blog: Allows you to create a personal blog that loggers Users can only be logged in (redirects them to the login page). But I get the impression that you are trying to keep some users available to registered users only for public users and other parts. You can also use this plugin to restrict some areas of your blog, screenshot example here: It is a challenging part to hide...

c# - Need help setting up SMTP -

I am having a strange problem and I'm not sure why. I have this in my webconfig & lt; Add Key = "SMTP" value = "mail.reliablesite.net" /> & Lt; Add key = "email" value = "email" /> & Lt; Add Key = "EMAIL_PASSWORD" Value = "Password" /> & Lt; Add Key = "FROM_PORT" value = "2525" /> Now when I test SMTP through a local host, it's all right and sends my SMTP and everything. I upload my webconfig plus all my other files and I try to test my SMTP and no message is sent. Perfect code and everything. So I do not know why this does not work. This is like a short version of my code. Public class MyTestController: Controller {// // GET: / MyTest / public void index () {Mail Message Mail = New MailMessage (); similarity. From = new mail address ("to"); Mail.To.Add ("for"); Mail.Subject = "Topic"; Mail.IsBodyHtml = True; similarity. Bo...

parameters - Calling Client-Side WCF Service With Type List<Of T> -

I am creating a multi-file upload service which also shows upload progress for each file. If I wanted to design my WCF method as a SOP contract, I do something like this: var request = IService.UploadMethod (list & lt; Upload & gt; request); However, how can I type the parameter request "" type " list & lt; upload & gt; " when I call the method from the customer ( .upload.svc/ Upload Image / Request "")? Thank you for the help, thanks. You are using SOAP as you say - which means, Can not fetch from the URL URL (REST-style), as the second part of your posting (../upload.svc/ upload upload / "request") will be notified. What you need to do in SOAP You have created your client-side proxy by using Visual Studio or svcutil : // Create client-side proxy, read URI from config service client client proxy = new service client (); & Lt; Upload & gt; _list = new list & lt; Upload & gt; (); // Add you...

java - Running a jar from shell script -

I have a jar file named umar.jar in the root / umar / bin directory. I have a shell script file run.sh in the same directory. The following is the contents of the. #! / Bin / bash "$ JAVA_HOME" / bin / java -jar /root/umar/bin/umar.jar Now when I run the shell script, I get the following error Exceptions in thread "main" java.lang.UnsupportedClassVersionError: Bad version number in the .class file Now it is strange, if I run this command directly on the shell java -jar umar.jar Works perfectly fine. If the jar was compiled with a later version of JDK compared to my JRE, then it should not have gone from the shell too. What do you suggest? Comparison "Java-version" and "$ JAVA_HOME" / bin / java -version " You have multiple JVM installed

c++ - Conversion from unsigned to signed type safety? -

Is it safe to say a unsigned char * to sign a is? Four * * (or just a four * ? Access is well defined, you are allowed to use an object through an indicator for a signed or unsigned type corresponding to the dynamic type (3.10 / 15) of the object. Additionally, The signed letter is guaranteed to not have any trap value and as such you can use the signed four pointer You can safely read the value of the original unsigned char You can certainly expect that the value you read through one pointer is through the other. EDIT: Regarding the comments of SalesBitz, this is what is called 3.9.1 / 1. A four, A signed four, and an unsigned four storage Mr. took amount capture and participate in the same alignment requirements (3. 9); that is, representing them all bits of the value of the character types that object representation, object representation. For unsigned character types, values ​​represent all possible bit pattern numbers of representation. It seems tha...

Regex match question -

अगर मेरे पास स्ट्रिंग है जैसे lotsofcrap "somethingimportant" अधिकotherस्टफ़ क्या Regex को मिलान करने के लिए संभव है, जो "" उद्धरण चिह्नों को छोड़कर के बीच में है। तो यह पता लगाने का तरीका "। *" जैसा कुछ होगा, लेकिन वह सिर्फ शुद्ध कुछ महत्वहीन के बजाय "महत्वहीन" P> "। (। *)" आप उपयोग कर सकते हैं एक कैप्चरिंग समूह बनाने के लिए मापदंड आप इसका उपयोग कैसे करते हैं यह उस भाषा / लाइब्रेरी पर निर्भर करता है जो आप उपयोग कर रहे हैं - आम तौर पर कैप्चर समूह प्रील-जैसे भाषाओं में $ 1 या \ 1 के रूप में उपलब्ध हैं उदाहरण के लिए, पर्ल में: 'हैलो' विश्व "!!!" = ~ /"(.*)"/; प्रिंट करें "$ 1 \ n";

Files needed to deploy delphi 2010 dbxpress application -

I'm having trouble planning my Delphi application, it uses DBXpress to access the mysql 5.1 database . When I run an application from another computer, an error occurs. I have already added midaslib.dll to my application and copied dbxmys.dll and libmysql.dll to the same folder as my application. Hope someone can help you. Do you ping command? Can you make yourself a connection to the database? Simply with the command prompt. Not with Delphi Perhaps a firewall is blocking or remote user is not authorized.

php - PayPal doesn't send me all fields to return url -

I subscribed to the form for Setup PayPal. ... & lt; Input type = "hidden" name = "return" value = "http://mysite.com/success/" & gt; & Lt; Input type = "hidden" name = "rm" value = "2" & gt; ... Then I pay in the PP sandbox and click on the "Return to" button. I hope: In all $ _ POST , such transaction data, such as txn_type and so on I'm getting: [merchantReturn_x] => Return to Merchant [auth] = & gt; QQJeJB06AAvD3o1Q5_7MOb6oCrg7OLBbQnYJOLBn0x4xAjnRwG4wORijts5Bo5gYPGMAid1eC3R9m9FYDD2 [form_charset] = & gt; UTF-8 What's wrong? Be the poster of that URL will not be the data ... Manual for IPN (Quick Payment Information) Find out Basically there is a script that gets those parameters.

Group by date with LINQ to NHibernate -

In the LINQ implementation of NHibernate, there is a problem with an unsupported feature (this is firing a QueryException >:" Property can not be solved: created: date: example comment "). Looking at the unit below, I am compiling the comments per day and the amount of comments : public class comment {public virtual date time { Get (usually have additional properties and correct mapping, written in Fluent NHibernate) set; }} My LINQ query appears below (query works fine if LINQ is executed for SQL reference). var commentsPerDay = (in the session. Linak () Select new in Group {New} in {c.CreatedOn.Date} by Group C {date = g.Key. Date, Count = g.Count ()}; The appropriate solution will have to contribute to the project and fix this issue. On the other side, let me know (LINQ to) NHibernate has an extensibility point, where I inject this behavior. I know that I can probably create a custom type and date of creation time I can mapping the second asset i...

Xslt transform on special characters -

I have an XML document that contains an '& amp; in this. It is called for a web service from .NET and the correct encoding & amp; Amp; Comes to the wire with . T & amp; Amp; O I need to use XSLT to make a change again, but SQL needs to be queryed without encoding through SQL to go to T & O DB like ampersand Will happen. (Note that all this is to be done through XSLT, at this point I have the option of using .NET encoding) Cheers Cheers If you have to use .NET So you can convert between HTML-encoded and regular string (this code is the system.): string HTML encoded text = system. Web. HTTPITY.HTMLMode ("T & O"); String text = system. Web. HTTTY Html code (html encoded text); Update Because you have to do this in plain XSLT, you can use xsl: value-of To decode HTML encoding: & lt; Xsl: variable name = "test" & gt; & Lt; Xsl: Select Value = "'T & amp; O'" /> & Lt; ...