Posts

Showing posts from April, 2014

html - jQuery .blur doesn't work -

I have 3 Blur and only the first thing works for some reason here is jquery code: & lt; Script type = 'text / javascript' & gt; $ (Document) .ready (function () {$ ("# user_name"). Blur (function () {if ($ (this) .val (). Length> 4) {$ ("# usernamecheckbox") Html ("& lt; img src = 'images / checkmark.png' alt = '' / & gt;");} and {$ ("# user nameshexbox"). Html ("& lt; img src = 'image / Xmark.png 'alt =' '/ /) "$ (" #pass "). Blurring (function () {if ($ (this) .val () Length & lt; 4) {$ ("# Html (img src = 'images / xmark.png' alt = '' / /" ");}}); $ (" #backpass "). Blur (function () { If ($ (this) .val ()! = $ ("# Pass"). Val ()) {$ ("#passcheckbox") .html ("& lt; img src = 'images / xmark.png' alt = '' / / Gt; ");} Other {$ (" #passcheckbox "). Html ...

asp.net - What is the state of the art Web Application framework? -

I want to develop a web application, what is the current state of the art to do this? Google Web Toolkit? Preferred languages: C #, Java, Python. If I think that ASP.Net, Spring, and DJenco are correct in the right way? In addition to this there is also the train. Am I just calling the general purpose? Suppose you had a version of MSPaint that you wanted to keep as a web app, what would you use? If you want to attract many people to the same canvas ... if you want to make Photoshop as a webpad. For example, have you seen people VMWire server for Linux, the whole thing is a web interface. What was written ?? What is the best thing to do in writing this? HTML + CSS Without this the result will be unhappy. When seriously, there are many structures behind many different ideologies, they have their advantages and drawbacks, they can not talk about them all, but generally a good programming language on the server side To develop the web application in opposition to ...

c# - UserControl cannot be displayed in Designer - null object reference -

I have created a user control with a compartment in it. This Cambodia has a XML population, when it does not exist, this resource The file is loaded from. It works fine in the program, but it can not be displayed in the designer - it says: "Object references are not set to be an example of an object." Load the list from xml Zero reference check in the responsible square is lost due to reasons beyond my understanding ... public sortedDictionary & lt; String, string & gt; Country {Receive (if object.ReferenceEquals (countries, empty)) {GetCountryList ();} Countries of return;}} The population of the combo box is as follows: / P> comboBoxCountry.DataSource = new binding source (program languages, blank); programmable language But it does not help the designer. The question is, how do I (combo box) to display my control in the designer? How to compile the combobox (= from XML to load list). If possible, you can Do you want to check for this....

mysql - Why Django does not "really" support automatic table update? -

Recently I am trying to learn web development in Django and I am very happy about it ... But, one thing is really upset - especially when you get ideas about 'simplicity' philosophy behind the desensgo. It is that updating a table in the Django is really far from simplicity because I am just experienced For example, like my actual case, I enter the beginning Skipping a slug field for the titles left but after some time, I wanted to add a slug column to the table, just like everyone else - which can expect a cheater in the deeggo, I created the python manage.py syncdb Command cord And of course it does not work ... After a little search I found "I need to manually add a new column" in the debash shell command line ("mysql is using the database"). I do not know why, but I think that this is really a fun thing I have never expected, when I saw how easy it is to create a web site in the DJ. Think? Or If you have any other solution or anything else,...

Example of nhibernate winform application -

I am looking for any type of document, an open source nineteen Winform application that I can study, Or better Winform / Nibernate Framework I saw it a little bit in Nibburnt Disbab and Anh Edines, but it's all there is a lot about the web but why is it so little about Winform? The article by Oren Wee is the best example of applying the desktop I saw This description of Windows applications design patterns and best practices should apply to either WinForms or WPF \ Silverlight applications.

accessing windows taskbar icons in c++ -

I'm exploring a way to get the current taskbar icon (system tray) not available for each program in the program. I have no luck with MSDN or Google, because all the results are related to the system tray. Any suggestions or hints would be helpful. > Edit: I tried the idea of ​​Keegan Hernandez but I think I might have done something wrong code is down (c ++). #include & lt; Iostream & gt; # Include & lt; Vector & gt; #include & lt; Windows.h & gt; # Include & lt; Sstream & gt; using namespace std; Of vector & lt; String & gt; Xxx; Bool EnumWindowsProc (HWND hwnd, int ll) {if (ll = 0) {// ... if (IsWindowVisible (hwnd) == true) {char tyty [12 9]; GetWindowText (hWnd, Tyty, 128); Stringstream LLMM; Lmlm & lt; & Lt; Tyty; Xxx.push_back (lmlm.str ()); Return TRUE; }}} Int main () {EnumWindows ((WNDENUMPROC) EnumWindowsProc, 0); Vector & lt; String & gt; :: Iterator; (This = xxx.begin (); this is & lt; xxx.end ()...

Large loops hang in R? -

Suppose I want to do a simulation using the following functions: fn1 & Lt; - Function (n) {RES & lt; - for c () (i 1: N) {x & lt; - rnorm (2) res & lt; - c (res, x [2] -x [1])} res} For the large N , the countdown appears dropdown. Are there better ways to do this? (By inspiration :) The efficiency of the ends is essential in the work of R Those who implement tasks that essentially process the whole vector of data at once, instead of looping through them. For the loop shown above, there are two basic functions during each recurrence: # A random vector of two random numbers is generated; - rnorm (2) # The difference between those numbers is calculated by x [2] - x [1] In this case, the appropriate action will be sapply () . sapply () operates on the list of objects, such as the vector generated by the loop statement 1: N and gives a vector of result: sapply (1: n, function (i) {x note That index value is available during the i functi...

c - How to interpret "error C2018: unknown character '0x40'? -

कुछ कोड संकलित करते समय मुझे निम्नलिखित प्राप्त होता है: "त्रुटि C2018: अज्ञात वर्ण '0x40' मुझे आश्चर्य है कि कैसे इस तरह के मुद्दे को हल करने के लिए? यहाँ मैं कहाँ शुरू होगा : क्या आपने कोई गैर-मानक शामिल फ़ाइलें शामिल की हैं? यदि हां, तो त्रुटियों के लिए उन लोगों की जांच करें। क्या आपने कहीं एक अर्ध-बृहदान्त्र खो दिया है? क्या आपने अकस्मात वस्तु का इस्तेमाल किया है > डेटा के बजाय ऑब्जेक्ट -> डेटा कहीं भी आपके कोड में है? क्या आपने कोड को एक मशीन (ओएस) से दूसरी में कॉपी किया है, जिससे एन्कोडिंग समस्याएं हो रही हैं?

Bug with Python UTF-16 output and Windows line endings? -

इस कोड के साथ: test.py import sys आयात कोडक sys.stdout = codecs.getwriter ('utf-16') (sys.stdout) प्रिंट "test1" प्रिंट "test2" फिर मैं चला इसे: test.py & gt; Test.txt Windows 2000 में पायथन 2.6 में, मुझे पता चल रहा है कि बाइट अनुक्रम \ x0D \ x0A \ x00 पोस्ट-पाठ "itemprop =" text "> इसे आज़माएं: import sys कोडेक आयात करें यदि sys.platform ==" win32 ": import os, msvcrt msvcrt.setmode (sys। Stdout.fileno (), osOININARY) वर्ग CRLFWrapper (ऑब्जेक्ट): def __init __ (स्वयं, आउटपुट): self.output = output def लिखना (स्वयं, s): self.output.write (s.replace ("\ n "," \ R \ n ")) def __getattr __ (आत्म, कुंजी): वापसी getattr (self.output, कुंजी) sys.stdout = CRLFWrapper (codecs.getwriter ('utf-16') (sys.stdout)) प्रिंट "Test1" प्रिंट "test2"

iPhone SDK NSUserDefaults not saving correct values -

I can use some help. There are consecutive lines of code here: NSLog (@ "StartTimer (after a few frustrating days of testing and error), I have NSUserDefaults writing results incompatible. ): End time defaults:% f \ n ", [Default floatio: kentthemake]); NSLog (@ "Start Timer (New: End Time:% f \ n", Endime); [Default Set Flame: Endime Farke: Kandtmeke]; [Synchronize default]; NSLog (@ "Start Timer (): Archived Endtime:% F \ n", [Default Floatio: KandTameKey]); kEndTimeKey is a constant string. If I can see the current value log for the key, then I think the value I want to store is logged, synchronize, then read the stored value again seems easy for me, But here's the Debugger output: 2009-07-22 22: 05: 43.263 TimerTest3 [1584: 207] startTimer (): End time defaults: .0,00,000 2009-07- 22 22: 05: 43.266 TimerTest3 [1584: 207] startTimer (): New End Time: 270018630.9 16571 2009-07-22 22: 05: 43.287 TimerTest3 [1584: 207] startTimer (): A...

criteria - Is there an NHibernate criterion which does actually nothing? -

I am looking for a NHibernate criterion which adds no restrictions for the criteria. The reason for this is that I have a method that converts some input parameters into a criterion that is added to the criteria. The constellation of the input parameter is where no restriction has been applied. So I want to return some types of dummy criteria. What is something like this in NHibernate? Best regards, Oliver Hanapi Can do something like. ISNTONAL ("ID") if 'ID' is the primary key (and therefore can never be blank). Anyone who evaluates a reasonable restriction can be used depending on your needs.

pdf - Internet explorer and serving files with asp.net httphandlers -

So ... I have an HTM handler that serves documents. The response contentType is set correctly, but the handler URL does not have an extension in i.e. Pdf It looks like this: When I come to this URL in Firefox / Chrome etc (i.e. decent browsers), then all is fine ( Browser selects correctly a plugin (such as Acrobat Reader) to render the file in the browser. If I look at this URL in Internet Explorer 7, then it's OK for the first time. If I refresh or go to the URL again without closing the browser, I get a dialog that asks "Do you want to open this file or save it" !!!! If I click open, nothing happens! Next I have created a redirect page ... so I redirect this page to the original URL and still mentioned above . It is not that the same problem occurs when a plugin needs to be filmed, i.e. files that are using TIFF files, PDF using optional PDF - these are all the same problem is! Thoughts ?? I did something like that, sadly that it was last yea...

php - can we avoid browser's "remember password" when a user tries to log in to the system? -

I know that this feature is meant to increase the user experience (not every time their details are rewritten) and users Can change your browser settings, but is it possible to send some "headers" etc. (or any method, I mean control over server side), when users try to log in to my site, then they It's "Do You Keep IE / Firefox Remember Your Password Ahte are? " Hint? I'm not sure this is possible? What will you say? Thank you. "autocomplete =" close "'in the input tag of the field it works in IE and Firefox , But this is not part of the HTML standard, so you will end up with invalid markup.

flex - How can I load my own custom component into an AIR application? -

I have created separate canvas component for home page, contact page, rule page etc. In my main application it has a link button like Home, Contact, Rule in Application Controller (Child State). & lt ;? Xml version = "1.0" encoding = "UTF-8"? & Gt; & Lt; Mx: canvas xmlns: mx = "http://www.adobe.com/2006/maxml" width = "903" height = "508" background image = "@ embed (source = 'picture / main background page')" & Gt; & Lt; Mx: label x = "483" y = "166" label = "Welcome to our site" / & gt; & Lt; Mx: select date x = "229" y = "166" /> Show the home page canvas if you click the Home button How can I apply? Or between script tags Public static institution house: number = 0; Public fixed contract contact: number = 1; You can use a view-stack to display different views and MyStack. The selected index is just a number, but ...

jquery - Using jqGrid on IIS7 -

I have jqGrid running locally in VS 2008 as an ASP.NET MVC project. When I upload the project to the server (W2008, IIS7) I get an error in IE 8, the object does not support calling this property or method to call jqGrid in firebug - the jqGrid function is not there. All other jQuery plugins (before uploading and after uploading) work fine Any ideas that might be due to this? I found that the problem was in jquery with var pathtojsfiles JqGrid.js file / script / js / Works fine locally, but I had to use the full path on the server "

c# - process.start() hangs when called from VS Addin -

I am playing with Edin in Visual Studio 2005, which calls the external process. When I run code outside of Edin - that means it works fine in a standalone project. However, when I call it as part of an addin process. Start () is called, but then nothing happens, the next line of code never reaches. I have tried to run VS with standard and high privileges but get the same effect. The code is below - it's called when clicking on the custom menu item: string document path = @ "C: \ TestCoda \ test-test". " String folder = path.gate directory name (@ "c: \ testcoda \ test app"); System.Diagnostics.Process p = new System.Diagnostics.Process (); P.StartInfo.FileName = "notepad.exe"; P.StartInfo.Arguments = documentPath; P.StartInfo.UseShellExecute = True; P.StartInfo.RedirectStandardOutput = true; P.Start (); String output = p.StandardOutput.ReadToEnd (); I have tried various executives, but it does not make any difference whether I am ...

Entering information into the Notes section of a PowerPoint slide using VBA -

I am trying to figure out how to write VBA to enter a text box in a slide, Also entering text I am also trying to find Vba to enter text in the notes section of Power Point Slide. Any help would be greatly appreciated. I have tried to find this site specifically, but are not able to do this text Entering is similar to entering the Note section in a PPT slide. You have to start with a slide object reference, which shows the slide you are adding; And you add a text box shape to the collection of slides' shapes. Example: Ex addTextBoxToSlide () Dim oDestSlide as PowerPoint.Slide set oDestSlide = ActivePresentation.Slides (1) Dim SlideWidth Single Slide Width as Single Slide Slide = Odysslides.Paint. Page Set Up Slide slide towards slide Lightweight = oDestSlide.Parent.PageSetup.SlideHeight dim octbox as PowerPoint.Shape set oTextBox = oDestSlide.Shapes.AddTextbox (_orientation: = MSOtextororientation, _length: = 0, _ upper: = 0, _ width: = slideout, _ Height: = slides...

Asp.net MVC Show specific items in Gridview/table depending on textbox -

Is it possible to capture specific elements from a database through the unit structure and after clicking on the 'Find' button Can the page be displayed? Assume that there is a text box and you have to enter a number. After entering a certain number, the column of a certain database table will be searched for that number and all instances will be returned (every match line), but instead of displaying each column in the table, only 3 or 4 columns will be displayed . Is this possible? I have tried to achieve some success. In addition to this, with my old site, I had a gridview and clicked a mouseover / javascript event which was done with a mouseover / outside and click it in the table and / or MVC with Gridview. can go? It's great about MVC, you can actually do anything. For your first question, seems like a simple Ajax. & lt; Div id = "mygrid" & gt; & Lt; / Div & gt; & Lt;% (Ajax.BeginForm ("/ path / to / action /", bl...

MySQL duplicate entry error when no duplicate exists -

EDIT: I get an error putting me down, at every time, no matter what I try to insert Was my table corrupted or something? Anyway, my question is: I have a MySQL table create table 'ACPCinfig' (`nsssiid`t (11) tap default '0',` Seepi_aidi `int (11) nOT NULL default '0',` run_date` nOT NULL default '0000-00-00', `hw_5_threshold` tinyint (1) not NULL default '0',` stp_on` tinyint (1) not on NULL default '0', `sort_on` tinyint (1) not NULL default '0',` afcs_ocr_message_format` tinyint (1) not NULL default '0', `use_hw` tinyint (1) not NULL default '0',` test_mode `Tinyint (1) not NULL default '0',` afcs_version` varchar (255) not null Ifolt ', `acp_build` varchar (255) NOT NULL default',` Id` int (11) NOT NULL auto_increment, `swstp_in_acp_rack` int (11) NOT NULL default '0', `acplookup_id` int (11) NOT NULL default '0', `bfind_cksum` varchar (255) not NULL default ',` tz_ck...

What do you consider to be the current benchmark for ASP.Net skills? -

I have a planned plan of upgrading on a friend who is getting off of VS2005 and Sql Server 2000 that a job He is worried that his skills can come back even if the user participates in group meetings and tries to cover different subjects at his personal time. My thoughts: My thoughts: My thoughts: My thoughts: My thoughts: ASP.Net MVC Playful behavior ASP.Net MVC Net 3.5 features (Linq, Linq-to-SQL, ef, lambdas, etc.) / Li> Test induced growth or at least unit testing and joke ability Solid CSS Web Criteria for Cross Browser Compatibility SSIS Sure there are other people; However, it is eager to know that others are eager to know what will be recommended to learn a developer. Whatever you mentioned, I would like to add the following two things to the list. Ajax (not ASP.NET AJAX) Security

c++ - Writing a Firefox Extension that uses XPCOM components? -

I'm trying to write a Firefox extension that writes Firefox's history in Windows system history, which should be useful for people. When working, IE and work to use Firefox. It is easy to add pages to IE history (should do this). However, my experience with Firefox Extensions is limited to small Chrome hacks packed together in XPi. From my initial reading, it appears that I have to create an XPCOM component that will put the URL in history, I'm not sure that this JavaScript can be used, and I can use XPOM components There is not much experience in typing extensions. Could anyone be familiar with Firefox extension development? Please point to any tutorial about writing extensions that use XPCOM components, especially using those written C ++? Or are there open-source extensions that use components that I can see to learn more about it? The best you can do this.

compiler warnings - Visual Studio: Warn on Missing XML Documentation for Private and Internal Members -

I am using Visual Studio 2005 (VS.8.0) and I am looking to apply the requirement that Members of all classes should not only be public people, documents. In order to warn public, protected or internal protected members, there are no documents when Visual Studio is set to set up, I am exploring a way to throw a single warning to private and internal members. Any suggestions? Note: I am using Warning Level 4, treating warnings as errors, and XML XML set set. Unfortunately, Visual Studio 2005 does not offer a way to implement XML documents on private or internal members and types. I recommend trying, but it does not support Visual Studio 2005 (in fact, it still does not support Visual Studio 2008, unfortunately). However, all members should be setup to implement the documents. May be. But now all of the open source are not lost, so you can get the source code and use it to inspire your add-on for Visual Studio 2005, Campaign copies.

javascript - Select all DIV text with single mouse click -

How to highlight / select the contents of the DIV tag when clicking on the user div ... The idea is that all the text Highlight / selection is made, so the user does not need to manually highlight the text with the mouse and possibly miss a bit of the text For example, we have a DIV Found: & lt; Div id = "selectable" & gt; Http: //example.com/page.htm< / Div & gt; ... and when the user clicks on that URL, the entire URL text is highlighted so that they can easily drag selected text into the browser, or copy the entire URL together. Click OK. Thank you! script type = "text / javascript" & gt; Function selectText (containerid) {if (document.selection) {var category = document.body.createTextRange (); Range.moveToElementText (document.getElementById (containerid)); Range.select (); } And if (window selection) {var range = document.createRange (); Range.selectNode (document.getElementById (containerid)); Window.getSelection () remo...

windows - AVI files play locally using WMP but not off my website WMP ActiveX -

I have a web page that allows the client to play uploaded videos. Many avi files have recently been uploaded which use WMP to play locally well but fails to use WMP ActiveX playback on the web and the browser is hanging. AVI codecs are videos: MJPG, Audio: PCM GSPT says that all codecs are installed on my Windows Vista OS, but it seems that WPM Active X has access to them Can not find ... Any help is extremely irrelevant. Greg When you say that they play okay at the local level, But not on the web, are you talking about the same machine? The ability to play a given AVA depends primarily on the right codec available on the machine running the file. If the browser is hanging, it may be that the full file has not been downloaded yet. If the file is not streamable, the whole thing has to be downloaded before the playback starts, and it can appear that the browser is locked, when in fact this file is in the process of downloading. I try to paste the URL of the video in a ...

configuration - iPhone app: SDK 3.0 : Button Selected State: Can't get working! -

Trying to perform simple button functionality. Button A. There are 3 states in: Default, Highlight, Selected. Should the United Nations be clicked again for my life, I can not even get the functionality of a simple 3 state Highlight (on the press) is built ("stock" blue). I have used the button properties to load the image for the selected state ... with control / content, trying to find the right combo by clicking on Placed, Highlight and Selected ... I thought that I want to select the state in the 'D' dropdown which I want to edit ... and it will register my edits for that situation ... the images have been loaded / changed color / Etc .... No Oh !!! What am I missing? What are you trying to set the picture or title to different states? For this you can only use methods such as state (UIC Contolstate) for the image: (Zero) set image: (UIImage *); or - (zero) setTitle: (NSString *) title forState: (UIControlState) state; This is what you ar...

ruby on rails - Stop redirecting to sessions/new? -

I use before_filter: login_required on a controller, and treats everything like that - A user login is bumped to the sessions / new but seeing that I am doing it on the root URL, I refrain from having a real redirect (not showing / session / new) in the user's browser bar Want to How would I tweak? Determine where your login_required method is from, and change the location to redirect_to there if you are restful_authentication If you are using, I believe the login_required method is defined in /lib/authenticated_system.rb .

language agnostic - How to interpret unprintable characters in the timestamp sent by the Lotus Notes POP3 server? -

I wrote a program to recover mail from POP3 server. + Ok Lotus Notes POP3 server version X2. One of its users has to face the following problem ... Greeting continues when its mail server connects to my program: 0 ready & Lt; Printable Chater Shoppers with Unacceptable & gt; Participation in the angle bracket for APP authorization is a so-called challenge. The challenge (and all other strings in the POP3 protocol) are usually only ASCII characters. But this time the challenge is made up of two parts - the other has non-printable characters. The pattern is low: first 0x5, then some non-ASCII characters. Looks like this. When I remove the challenge and use it for APOP authentication the server declines. After reading carefully, I can get it at LMBSC. 0x5 is a prefix to a so-called signal. Each character is actually a Win-1251 character but is prepared by 0x5. With this, I just leave all the legal ASCII and non-printable Win-1251 and only the general APOP auth...

How to reference proper non-generic overload in c#? -

I instead To select the appropriate surcharge? using the system; Using System.Collections.Generic; Namespace Console Application 2 {Class A {} class B: A {} class C: A {} class program {static zero main (string [] arg) {var l1 = new list & lt; C & gt; (); Var l2 = new list & lt; C & gt; (); Comparator & lt; C & gt; (L1, L2, ???????); } Compare to zero (ca, cb) {} compare zero (ba, bb) {} compare zero & gt; T & gt; (IiLIT & lt; T & gt; A, ILIST & lt; T & gt; B, Action & lt; T, T & gt; comparator) for (int i = 0; i & lt; a.Count; i ++) comparator (A [i], b [ii]); }}}} You need to make the statics static and correct the name of the method is. You can use the type concept on the initial call compare : Fixed wide men (string [] AGR) {var l1 = new list & lt; C & gt; (); Var l2 = new list & lt; C & gt; (); Compare (L1, L2, compare); } Constant zero comparison (Si, cb) {} Constant zero comparison (BA, ...

perl - How do I modify the destination MAC address in a packet? -

I have a question about a very basic thing in Perl, but I can not find an efficient solution. / P> Here is a bit of context before I use etc and when I am in my function which process packets (used by pcap_loop ), then I The $ packet scalar is available in which my entire packet (Ethernet header + IP header + Tcp / udp header + payload). What do I want to do to replace the first 6 bytes of this $ packet (Ethernet Destination) $ packet that I Pcap_sendpacket by using a user defined destination MAC address (passed as a command line argument for example), such as 00:11: 22: 33: 44: 55 . Therefore, I can split the user defined address (using split ) to get every 6 parts of a destination defined address, and call it hex I can change the hex using the function, but now I want to modify the first bytes of my packet to replace it with these hex ed bytes. How should I proceed? I thought using some combination (.) I think this solution is dirty. I was thinking in C (...

iphone - CGLayer appearing the wrong way around -

I have found a UIView subclass that is 100 width 200 width, and I try to attract it Pixel by pixel In this case, I am trying to draw a horizontal blue line which exceeds 75%. Instead, I get two vertical blue lines (one on the edge, one in the middle), which is 75% above. It seems that the CGLayer I used has been rotated 90 degrees and 50% has shrunk. What can I do to fix this? At the top of the .m file: #define WORLD_WIDTH 200 #define WORLD_HEIGHT 100 # Defined ABGRB 4 4 Implementation TraceView Int theImage [WORLD_WIDTH] [WORLD_HEIGHT]; Overriding direct: - (zero) direct: (CGRTact) shortcut {CGContextRef theViewContext = UIGraphicsGetCurrentContext (); CGLayerRef theCGLayer = CGLayerCreateWithContext (theViewContext, rect.size, void); CGContextRef theCGLayerContext = CGLayerGetContext (theCGLayer); CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB (); CGContextRef bitmapContext = CGBitmapContextCreate (IIMAG, World_Width, World_Hyate, 8, World_Width * ABGRBITES, ...

asp.net - attaching an entity with a related entity to a new entity framework context -

When I want to update the unit, then to attach a unit to an entity in a new context, I have been trying to bring the head. I have a person table (generalized for personnel), which has a language-bound field, this field is the second table through EF through EF, Along with the primary key (1-M) as the language. I need to update the language preference of a particular person, however, this relation is associated with the old context, as I think the references to a "object should not be referenced on the given line with many examples of event change tracker. Could "error. What is the way to engage the language unit in the new context in relation to the Personnel (Person) unit ??? The institutions use the one which is not separated into the original gupperson () method. To return the preferred language, add the () method Navigation on the preferred language person table is the name of the property ... Public Static Zero Update User (Personnel Original User, Personnel...

How should I start with OAuth server at PHP -

The following example of the OAuth server was found but this is not clear to me 1. How should I do Generate certificates How should I specify access tokens / access token secret / request token / request token secret, should they be stored in the database? Should each item be reproduced? Where should I apply the access token verification? Please advise generate a certificate To do this, you need to create a CSR (Certificate Signature Request) If you have access to cPanel, you can easily generate a CSR if you do not do this, You will need to download some software to generate. After your CSR, you can proceed for a free certificate. However, warn: All modern browsers do not trust CACECT, so you can get warnings. If you do not want this, you will have to pay for a certificate from a professional provider like VeriSign.

php - using stripslashes() discriminately -

my php application uses stripslash () to deal with magic_quotes, but I only want the magic_quotes slash to be used. Remove, because the user is allowed to supply \ "with their input. Strips lash does not remove the slash indiscriminately. If the magic quote is on, it will be saved from slash, '\' will replace with '\\' , and strip slashes must be reversed by running magic quotes in the right way, to withdraw the user on which the entered '\\' should replace '\' . I think you might want something like this: Manual (http://us3.php.net/manual/en/function.get) -magic-quotes -gpc.php) if (get_magic_quotes_gpc ()) {$ lastname = stripslashes ($ _ POST [' Lastname ']);} and {$ lastname = $ _POST [' last name ']; } At the end of the code, there should be no slash except the user $ last name . On another note, magic quotes are a security problem, and have been demoted in new versions of PHP (see).

perl - How can I set the Cache-Control header for every response in Catalyst? -

It seems that the catalyst does not output by default cache-control: , etc. Header I know that I can output them to a given control method: $ c-> feedback-> headers-> Final_dated (time); $ C- & gt; Feedback-> header-> Ends (time + $ self-> cache_time}); $ C- & gt; Feedback-> header-> Header (cache_trol = & gt; "public, maximum-age = $ self-> gt; {cache_time}"); It was very painful, though, by all means! What I like: A default group of headers (now finished, now has been modified last time, cash-control: no-cache, programmable: no-cache) Override one method, per-line, default. Is this a good way to accomplish this? Dorobert: Great question I did for a catalyst Advent calendar at one Covered. Actually you create a stash variable that defines your cache time for the given operation, and then you process it in the root route routine. See the article for all the details. JK

perl - How can I not send a cookie when I use the Cache-Control header in Catalyst? -

After the I am using the session in my catalytic application via the session , Session :: Store :: DBIC , and Session :: State :: Cookie . I have to send some controllers and methods out of data with a cache-control: public header, so it is important that the set-cookie: header not go out with those reactions (otherwise, it will be cached and the other will be sent to the customers, leading to possible security issues). I do not have any good way to accomplish this. How can I not send sessions or session :: state :: cookie in response to a given request cookie? A little RTFS, Session.pm override catalyst the finalize_headers method and a rather sets there cookie through deep Call series: finalize_header ⇒ _save_session_expires ⇒ session_expires ⇒ _extended_session_expires ⇒ extend_session_id (...: : Session :: state :: cookie) update_session_cookie (... :: session :: state :: cookie) ⇒ It does not seem to be from. Cookie.pm cookie_is_rejecting is ...

ajax - Call a javascript function from outside its object -

I can do some simple JavaScript that far I have not but tell should work. The code is below var presenter = new practice. Web. // This Ajax.Net function is a class generated by GetLetters () {var GetLettersParams = new object (); GetLettersParams.TemplateType = $ ('# LetterTypes'). Val (); Var letter = ajaxCall (presenter, Gatoreller, Gail Letterpers); CreateOptions ('template', letter, 'id', 'name', true); } Function Ajaxcol (Ajax method, parameters) {var response = AJAX symbol (parameter); // If the message fails here (response.error! = Null) {Warning ('An error has occurred; r \ n' + response.error.Message); Return; } Return response value; } this creates part of the class Ajax.Net Practicum.Web.TEI.StudentPlacement2009.CreateLetter_class = function ({} ;; Object.extend (Practicum.Web.TEI.StudentPlacement2009.CreateLetter_class.prototype, Object.extend (new AjaxPro.AjaxClass (), {GetLetterTypes: function () {this.GetLetterTypes ...

c# - How can I make DataContractJsonSerializer serialize an object as a string? -

I have a straight in C #, which wraps up a grid. I am using the DataContractJsonSerializer to sort the object that contains the frequency of that class. When I was directly using a guide, it was sorted as a plain string, but now it is sorted in the form of a name / value pair here, there is a NUnit test and support code that shows the problem: Private Static String ToJson & lt; T & gt; (T data) {DataContractJsonSerializer serializer = New data editing JSONSerializer (typeof (T)); (MemoryStream MS = New MemoryStream ()) Using {serializer.WriteObject (MS, Data); Return encoding. Default.GetString (MS. Toure ()); }} [Serialable] Private class ID {Private Gide _ value; Return Public Static Clear Operator ID (Guide ID) {new id {_value = id}; } Public static clear operator Gid {ID} {return id._value; }} [Test] Public Zero IDShouldSerializeLikeGuid () {guide guid = Guid.NewGuid (); ID ID = (ID) guide; Notice. That (ToJson (id), Is.EqualTo (ToJson (guid)); } and test runner o...

javascript - Accessing a MooTools Class Method from outside the class -

I have a method inside the MooTools class that I want to access after uploading files with AJAX (iFrame) . Javascript which runs the iframe page, when it loads, the class must call the method, but I am unable to use it anyhow: class name: was started in the main class class: myMain parent.window.mymain.myMethod parent.window.Main.myMethod Is this also possible? If so, how do I do this? I like the syntax: var MyClass = new orbit ( {/ * List regular non-static manner as usual); MyClass.staticMethod = function () {/ body of stable work}; You have the advantage: You call the static code through MyClass.staticMethod () inside and out It is not possible to accidentally use this pointer as it is not available To access a static method in an internal frame use window.parent.MyClass.staticMethod ();

Calling a FoxPro Report from .Net -

Does anyone have the experience of calling the Visual FoxPro report from an actual FoxPost? They both want to see the report and want to print it. Let me know the FoxPro application. And the client wants to keep a FoxPro database + report, but a new one . They have a detailed Fox report that they want to keep, have anybody tried to do this? I have not tried to do it personally; Although Windows Projects have the ability to compile FoxPro (at least v.7.0) as a COM object, which can be useful in this situation. In addition, in version 9.0 they have added the capacity of the report listener, which allows you to have more control over the reports. Between these two capabilities, you should be able to make a report call from the net. And as far as access to Fox Table, Microsoft offers OLE methods to interact with them. Sorry not my answer but hopefully the link will help.

php - Difference in efficiency of retrieving all rows in one query, or each row individually? -

I have a database in which nearly 200 rows of data need to be recovered. How important I am, if everything is the same In the query, there is a difference in skill when retrieving them all at once, then individually each row in different questions? The question is usually done through a socket, so executing 200 questions instead of 1 Demonstrates too much overhead, as well as RDBMS is optimized to get multiple rows for a query. Instead of 1, initialize RDBMS dataset to 200 questions, parse query, get a line, populate datasets and send results 200 times instead of 1 time. It is much better to execute only one query

reporting services - Exporting Reports from SSRS Report Manager -

I have several SSRs reports that have a text box with a link to a privacy notice page. Excel will export in the workbook or Word document. When users export reports, the reporting engine not contains links to the office documents. When exported as a PDF or HTML, the notice link is also exported as expected, to include the links of notices to the office documents I have a way to configure or stress and it is also ensured that it is also exported? While exporting to Excel, text box with the is link in the body section.

.net - Format currency without rounding -

I need to format a decimal number in the form of currency, but for any rounds in the process Do not want. / P> For example (example culture is N-US) slow money = 1234.556789 D money. Towestring ("C") 'yields $ 1,234.56 (goling and layoff notice) money. Toastring ("C 99") 'Yield $ 1,234.556789000000000000 .... 0 - Near but not complete, those indexed zeros are unwanted.' I want something that should be the result ... money. Toastring ("??") 'yields $ 1,234.56789' Similarly .... Money = 0.1D Money Toastring ("??") 'yields $ 0.10 (note that this corresponds to the currency format of the culture at least - two decimal places) Value to all users of this application Take that "I" ??? "############################################################################################ ######################### "- But there is a problem in my stomach to complete the underlying What's the way I do? ...

php - How can I make a custom exception object evaluate to false in an if condition? -

I was just thinking that if I make my object wrong, the reason for this is that I create a custom exception class I am here. I would like to be able to do something on the lines of class dog {public function lookAround () (see dog ()) {layer of bark;} and {return sit;}} public Function seeDog () {If (object == dog) {return "hoarse";} and {return Dog_Exception (no_see);}}} I think this is a terrible silly example However, the issue is that as the object, if (see dog ()) test string "hoarse" and dog_exception both To evaluate true for the object, if possible, to evaluate the dog_exception to false , if if In such a situation, I will not have to do this like this, for example, create a code such as type (seedog) == dog_exception) etc. I suspect that this is possible, but any help would be great thanks! Why are you refusing an exception? Do not you want to throw it?

Auto-select "default" marker with Google Maps API -

I have several marker maps that are kept with addMarker / addOverlay. I should have auto-selected one of these markers, when the map loads and maps to the center around it. How can I do this? What does marker mean by "auto-selected"? Do you want to show an InfoWindow for it (this is a little bubble with text sticking to the marker)? If so, call the marker and supply the goods you want to show. I believe it will also pan the map so that the marker can be shown. If it does not pan the map as I think it should be, you can set the center of the map on the GMAP2 object.

statistics - efficiently predicting the likelihood of a user clicking a hyperlink -

संभव डुप्लिकेट: इसलिए मेरे पास वेब पेज पर हाइपरलिंक का एक गुच्छा है पिछले अवलोकन से मुझे पता है कि एक उपयोगकर्ता इन सभी हाइपरलिंक्स पर क्लिक करेगा। इसलिए मैं इन संभावनाओं के माध्य और मानक विचलन की गणना कर सकता हूं। अब मैं इस पृष्ठ पर एक नया हाइपरलिंक जोड़ रहा हूं। परीक्षण की थोड़ी मात्रा के बाद मुझे पता चलता है कि 20 उपयोगकर्ता इस हाइपरलिंक को देखते हैं, 5 उस पर क्लिक करें अन्य हाइपरलिंक्स पर क्लिक-थ्रू संभाव्यताओं के ज्ञात माध्य और मानक विचलन को ध्यान में रखते हुए (यह एक "पूर्व अपेक्षा" बनाता है), मैं किसी नए हाइपरलिंक पर क्लिक करने वाले उपयोगकर्ता की कुशलता कैसे अनुमान लगा सकता हूं ? एक भोलेदार समाधान अन्य संभावनाओं को अनदेखा करना होगा, इस स्थिति में मेरे अनुमान सिर्फ 5/20 या 0.25 हैं- हालांकि इसका मतलब है कि हम प्रासंगिक जानकारी को फेंक रहे हैं, अर्थात् क्लिक क्या है -साथ संभावना है। इसलिए मैं ऐसा फ़ंक्शन देख रहा हूं जो कुछ इस तरह दिखता है: दोहरा अनुमान (डबल पूर्वमहान, दोहरे पूर्वमान मानक विचलन, इंट क्लिक, इंट विज़ ); मैं उस से कहूंगा, क्योंकि मैं ...

MySQL stored procedure parameters -

I want to capture the X amounts of items outside the DB, I was wondering if a method of passing a list What is the number of numbers that can be used? SELECT item_id, item_directory items WHERE item_id IN (NEED_LIST_OF_IDS_HERE); Should not I use a stored procedure for this query and just create SQL in the application? Or I should call different DB for each item. I Note: The item is not the actual name of the table, so do not share the bad name for me. Please, I'm just hiding the implementation. poor unanswered questions from a year ago ... If you are not using one of these clauses, you certainly prepare / prepare the SQL within the stored procedure and execute it there. It is difficult to paramrise these segments. How about passing a list of IDs, create a temporary table within your stored procedure, and then join items on the table?

Rails eager loading of counts? -

Curious loading is good with the included attribute Post.find (: all :, I am thinking that if you can count curious loads, like I want to get the number of comments for each post, without loading all the comments. Maybe something like that post.fund (: all ,: included => gt; [: author, "count (comments)") I think I Can use count_cache columns But if this is possible then it will be really beautiful to do so in all of this. Additional bonus points if someone can show how not only can count, but also keep some conditions , As if only the counting of the posts has been approved. At least in MySQL, this Fast to do as two separate calls because you avoid joining me I know that this is the answer to your question. But it seems that you are trying to get better speed and Post.find ... then post.comments.count If you retrieve both of them in the same query, then faster and more memory efficient (for databases) than that.

python - How can I serve unbuffered CGI content from Apache 2? -

I would like to be able to see the output of a long-running GCI script because it is generated instead of the script Since the completion. However, when I explicitly flush STDOUT, the server is waiting for the script before sending the response to the client. It is on a Linux server running Apache 2.2.9. Example Python CGI: #! / Usr / bin / python Import time import system print I print for the "content-type: text / plain" category (1, 10): print i sys.stdout.flush () time.sleep (1) print "complete. " Similar example in Pearl: #! / Usr / bin / perl print "content-type: text / plain \ n \ n"; ($ I = 1; $ i & lt; = 10; $ i ++) {print "$ i \ n"; Sleep (1); } Print "done."; This link says as Apache 1.3 1.3 CGI Output should be ineffective (but it can only apply to Apache 1.x): Any ideas? Randall Schwartz Articles A Different (and Imho, Improved) Method of Viewing a Long-Term Process telling. / div>

mnesia - In Erlang, what is the best way to upgrade a distributed system? -

If I have many web servers running in ERP (load balanced) and MANICEIA used for backend database , The best way to upgrade the whole system to the new version? Although Ergon supports hot code loading, it is not necessary to use something in your case It is easy to remove a node once from the load-balancer, restart it to run the new code and put it in the load-balancer. You should also take the nodes if you want to hot-upgrade to the new Erlang / OTP release in your live system, then be prepared to do this. But the real problem that can bubble for you is those concerns that come from Mainecia. I think that you should ask with a special question what does maniaia want to do if there are no schema / table-changes, and you just want to move one node down and add it later or if you are actually in the tables New table or new columns are presenting the Mennica table gives the ability to add and remove nodes with replicas, and also mnesia: transform_table / 3,4 . also suppo...

c# - .NET equvalent of Java's NIO Selector -

I know that the network is the Net Asynchronous model for I / O, which uses the full port under the hood. But all callbacks are coming from thread pools on IO threads. Is there a .NET equivalent like Java selector that works with multiple streams in single thread? Or, thread pool callback is better than this single threaded approach? Thanks, DOD for ASINC operation An IO handle is connected to the thread pool when the async operation is completed, I believe that the callback (for each stream) can be executed using the same thread, whether an available thread pool thread processed the callback It is quite possible that the same thread can process multiple callbacks or only one runtime Callback based on practices. Hope this helps Edit: Adding an answer to Dodd's comment I am not well aware of the selector API posted on an example It seems that the selector waits till all events happen, is this true? If this is so, a collar has to wait for all the incidents, even ...

ruby on rails - Make link_to_remote Clickable Only Once -

Code> I'm using. Unfortunately, if you click on more than one link created link, then it reinstates the content I want to disable the link after first clicking. This is the code that I am currently using, & lt;% = link_to_remote ("# {user.name}",: update = & "# {User.id} _div",: url = & gt; Controller = & gt; "wishlist_ts",: verb = & gt; "load",: id = & gt; user.id},: position = & Gt; "After",: HTML = & gt; {: class = & gt; "# {user.id} _href"})%> I know that you can use : success and : full to call javascript, but to me now Not sure how to do this. Any help would be greatly appreciated. Thank you. There are a few different ways to do this, depending on how you want to do this. The specified callback (in order): : Loading: The call is made when the browser loads the remote document with the data. : Loaded: The document has been called after the br...

Nhibernate error when inserting an object with an one-to-one relationship to another object -

When I try to insert an object from one object into another object, then I have a problem. Mapping file & lt; Hibernate-mapping xmlns = "pen: nibinet-mapping -2.2" & gt; & lt; Id name = "id" column = "article_id" type = "int32" not saved-value = "0" & ​​gt; & Lt; Generator class = "parent" /> & Lt; / Id & gt; & Lt; Property name = "title" column = "title" type = "string" no-null = "true" length = "255" /> & Lt; Property Name = "Body" column = "body" type = "string" length = "1073741823" /> & Lt; Property Name = "IsEnabled" column = "is_enabled" type = "boolean" not-null = "true" /> & Lt; Many-to-one name = "parent article" class = "..." column = "parent" cascade = "all" /> & Lt; Bag ...

asp.net - setting width of silverlight application in aspnet -

I have found the most impossible case here: I have created a small silver application that is one of the remote paths Image loads. The image is very wide, so it does not fit properly on the page when I see the image in the aspnet page, for some reason the lightweight silver application is cut to fit the current width of the page. When a large part of silver on the aspnet page reveals more than a different value of the image. I can not estimate the width of the image every time! What to do? Silverlight code: & lt; Canvas x: name = "layouts" & gt; & Lt; Image name = "imgTrack" & gt; & Lt; / Image & gt; & Lt; / Canvas & gt; Aspen code: & lt; Body & gt; & Lt; Form id = "form1" runat = "server" & gt; & Lt; Div id = "silverlightControlHost" style = "overflow: auto;" & Gt; & Lt; Object Data = "Data: App / X-Silverlight-2," Type = "App / X-Silver...

.net - Access the Item bound to a DataGridView Row (WinForms) -

How do I use bound items for a custom line for a datagroup view for a custom collection? MSDN: The DataBoundItem property of DataGoundViewRow is a trick! var product = (product) _grid.SelectedRows [0] .DataBoundItem;

SQL Server Migration To Refactored MySQL w/ InnoDB Key & Constraint Issues -

I am redeveloping a web application and originally based on SQL Server 2005, ASP.NET & For a Windows 2003 LAMMP (Extra M for the Mkcch course) and since the schema is heavy rebuilt (with a great reason to do so) I should write a custom migration app The problem is the InnoDB Primary + Foreign key barriers have hindered my ability to insert data into my MySQL / InnoDB tables. I have tried to use the disable key and I already have it; By deleting the FOREIGN_KEY_CHECKS methods and temporarily removing auto-increments on the primary, it throws an error when trying to change either of these, such as the abnormal keys, because it is unsupported in the InnoDB or the primary in any column Attempting to remove key assignment throws errors in the empty table or migration app that says the record is empty when the table is empty When the key is already present, is there anything else that can be done before, except before removing all things and returning it later (which I think will g...

actionscript 3 - Flex-Ajax Bridge issue on Safari -

My Flex project uses FA Bridge, and apparently in Safari Browser, I can not call any public AS functions, which are argued I for example, I call this AS function from Javascript I can: var myButton = CreateNewButton (); MyButton.setLabel ('Click Here'); But if I try to call it this way at a time like this: var myButton = CreateNewButton ('click here'); In the above call safari, Safari throws an error # 1063 (i.e. the calculation of the mismatch) in the JavaScript console, and points to the 561 line in Fowbridge.JS. It seems that I did not get the required parameters. The above questions are now available on Safari. Both of the above methods work on IE, Firefox and Chrome browsers. Note: I am not using swfObject to embed my SDF. This would probably be better as a comment than reply ... but I do not have popularity For this I think .... I had a similar problem with bridging calls through JS. After a lot of experimentation, I found out that the HTML doc...

c# - Managing Descriptive URLs -

I've noticed that many blogs use URLs that look like this: I think this is done for search engine optimization. How is it read from the underlying data model? Are you actually searching in the database? Virtual Kamalaidi Perspective Video PortableForThemotwalker If so, how is the details managed? If this is the key, then what is the rule that it can be created without breaking the web link anytime? You are right that it is used for search engine optimization. This works best if you separate different words from dashes or underscores. These SE-friendly url parts are often called slug or url slug . A slug should be unique in your application, and generally the function that makes or checks them should be kept in mind. Just like anything else, there are several ways to implement something like this, usually you store a string of text about a database item, eg. Title of an article If you do not want to store it, you can convert it to URL slug in dynamic fo...

nhibernate - What is the CreateCriteria equiv of this line of code: -

_session.CreateQuery ("a.AuLname द्वारा लेखकों से a.AuLname चुनें।")। सूची (); मुझे यहाँ एक रिक्त चित्रण होना चाहिए ... लेकिन मैं यह नहीं समझ सकता कि सत्र के CreateCriteria विधि का प्रयोग करके अंतिम नामों की सूची कैसे वापस करनी है I अंतिम नामों की एक विशिष्ट सूची प्राप्त करना एक समस्या नहीं है क्योंकि मैं प्रक्षेपण का उपयोग कर सकता हूं। लेकिन ऐसा नहीं है कि मैं यहाँ क्या करने की कोशिश कर रहा हूं। टीआईए ... जेपी इसे आज़माएं : _session.CreateCriteria & lt; लेखक & gt; () .सेटप्रोजेक्शन (प्रोजेक्शंस। प्रॉपर्टी ("एयूएलनाम")) .ऑडऑर्डर (ऑर्डर। एएससी ("एयूएलनाम"))। लिस्ट ();

c# - Methods overloading -

When I call EntryPoint with a parameter type of TemplateA, then I always get an exception, because first Overload is always called What I expect to happen is that due to dynamic binding, the most specific method (second surcharge) will be called. Any ideas why? Private objects _obj; Public Zero EntryPoint (Object P) {myFunc (P); } // First surcharge private zero myFunc (object container) {throwing new NotImplementedException; } // second overload private zero myFunc (TemplateA template) {_obj = new ObjTypeA (template); } // Third Overload Private Zero myFunc (TemplateB Template) {_obj = New ObjTypeB (template); } If you use then you can use it in C # 4.0 Will be able to. Dynamic instead of object . Download Visual Studio 2010 Beta, if you want to give it a try, the compiler chooses exactly the same way to call the parameter based on the compile-time type. It is not clear from your question whether you know about simple single dispatch polymorphism, because it will s...

asp.net mvc - I want my MVC application to be a website -

Visual Studio creates an asp.net MVC application as a project that I would like it to be an asp.net website I want to be made, it gives me problems if I force it to do all the folders and references manually? This will probably not work at all. You can simply add code behind the files in your thoughts, but this is too much.

css - How do you prevent text from spilling over the edges of boxes when the browser's text size gets increased? -

As a web developer, how do you prevent spilling on the edges of text when the text size of the browser increases? There is nothing to do to ensure that your layout does not limit the height , So the text can still fit in the box. If you absolutely need to limit the size, then you use the overflow: Auto CSS declaration box display scrollbar To make the material is too big to fit when.

javascript - JQuery event.stopPropagation() not working -

In my HTML, I have a class drag handle gap which is embedded inside a li. & lt; Div class = 'treeView' & gt; & Lt; Ul class = 'tree' & gt; & Lt; Li & gt; & Lt; Span class = "dragHandle" & gt; & Lt; / Span & gt; Item 1 & lt; Ul & gt; & Lt; Li & gt; & Lt; Span class = "draghandle" & gt; & Lt; / Span & gt; Item 2 & lt; A href = "#" & gt; Link & lt; / A & gt; & Lt; / Li & gt; & Lt; / Ul & gt; & Lt; / Li & gt; & Lt; / Ul & gt; I add event handlers using jQuery as follows: $ (". Tree tree"). Click (function (event) {alert ("click"); Event.stopPropagation ();}); $ ("Dragheadhandle"). Mosudown (event) {warning ("down"); event.stopPropagation ();}); $ ("DragHandle"). Mousewipe (function) {warning ("up"); event.stopPropagation ();}); When I move the mouse an...

c# - Remove instances from a list by using LINQ or Lambda? -

Now I have come across a platform for getting all my data in the list of caches (objects) The next thing I have to do is to remove some examples from the list. Generally, I would like to delete: list & lt; T & gt; List; & Lt; T2 & gt; ToBeRemovedItems; // Divide foreach of two lists (broken items in T2 items) {make a condition based on {list.Remove (representative (t one) {// item // return right or wrong}};} To be more specific, I actually create or populate a list of dynamic classes (not a formal defined class) in the Barmowowight list. For example, And to remove the code like: class MyClass & Lt; C & gt; {Public String Value1 {get} Set;} Public Int Value 2 {Received; Set;} Public ObjectC {get; Set;}} .... List & lt; MyClass & lt; C An example of hard-coded code is var toBeRemovedLItems = new [] {new1 value1 = "a", Value2 = 1}, new {value2 = " X ", Value2 = 10}, ...}; // toBeRemovedItems Select from a collection forea...

sorting - The C programming language 2. ed. question -

I'm reading a well-known book "C programming language, version 2" and a practice that I'm stuck with . I can not understand what is to be done in reality, so I will explain it to anyone. Exercise 5-17: Add field-searching ability, so that the fields can be sorted within the fields, one of each field options Can be sorted by independent set. What does the input program expect from the command line; What does "independent set of options" mean? Study POSIX utility, ignoring the legacy option. Or study of the program; It has even more options than the posix sort . You need to decide between Nickel Butterworth's fixed width areas as suggested by your answers and variable-width areas. You need to decide how the character variable separates the wide-field . For each fund (string, case-to-day string, phone-book string, integer, floating point, date, etc.) as well as sort direction (forward / reverse or ascending / descending), you should su...

c# - FileHelpers-like data import/export utility for binary data? -

When I work with text data, I use the excellent filehallers library to give it a file or in-memory Allows to dump the text field with the string very easily, which represents the data. Serial data stream in me to work with a large endian microcontroller-based system. To save space on a very limited microcontroller platform, I need to write raw binary data which includes areas of various multi-byte types (essentially a straight variable dumping outside the serial port). I like the architecture of the FileHalper. I create a class that represents the data and tags it with the attributes which tells the engine to insert data into the class. I can feed a string representing the engine representing a single record and can get a deserialized representation of the data. However, this object is different from serialization because raw data has not been delimited in any way, it is a simple binary fixed record format. FileHelpers is probably not suitable for reading such binary data. I...