Posts

Showing posts from May, 2010

javascript - Ajax request with prototype - what is transport if not only responseText? -

यह प्रोटोटाइप साइट से एक उदाहरण कोड है। var url = '/ proxy ? Url = '+ encodeurIComponent (' http://www.google.com/search?q=Prototype '); // समान उत्पत्ति नीति को दरकिनार करने के लिए प्रॉक्सी का उपयोग नोटिस नया Ajax.Request (url, {method: 'get', onSuccess: function (transport) {var notice = $ ('notice'); अगर (transport.responseText.match (/ href = "http: \ / \ / prototypejs .org /)) notice.update ('हाँ! आप शीर्ष 10 में हैं!') SetStyle ({background: '#dfd'}); else notice.update ('अरे! आप # 10 से परे हैं ... ') .setStyle ({background:' #fdd '});}}); एजेक्स अनुरोध से प्राप्त डेटा परिवहन पर उपलब्ध है। प्रतिक्रिया पाठ, लेकिन परिवहन क्या है न केवल responseText? असल में, यह एक वस्तु है। लिंक किए गए पृष्ठ सभी अन्य गुणों को सूचीबद्ध करता है। वास्तविक XMLHttpRequest ऑब्जेक्ट के आस-पास आवरण।

html - RSS on the root of my domain -

I have added an RSS feed to my website, but I can not get Google readers and others only give it to me The root domain (www.example.com) wants the full address from the RSS feed. How can I raise my feed without the need to add my full RSS feed address to my users? I've added the meta tag below but it does not seem to work thanks tom Your default document (i.e. example that you see on the example.com) is & lt; Head & gt; There should be something inside the section: & lt; Link rel = "alternate" type = "application / atom + xml" title = "RSS" href = "/ feeds / questions / 1037523" & gt;

Open port in linux with java application -

I have a Java application that socketsurwer in port I test my application in a window machine, and right By the way, but when I test it in a Linux machine, the port is not listening. Is there any way to open the port especially in Linux machine? I run the 'netstat' command, and the port I use in my application does not appear. It does not throw any exceptions I am trying to connect to the application from another machine, and the connection has been denied. Honestly, I do not know why it did not ... Help Please Thank you, David To open the port number you are trying to use? If it is below 1024, only root users can open it or access it.

Why the following Scala code does not compile unless explicit type parameters are added? -

ऑब्जेक्ट टेस्ट अनुप्रयोग को विस्तारित करता है {// compiles: मानचित्र [int, value] (0 - & gt; ज्ञात टाइप (classOf) [ऑब्जेक्ट]), 1 - & gt; अज्ञातवेला ()) // संकलित नहीं करता है: मानचित्र (0 - & gt; ज्ञात टाइप (कक्षा [उद्देश्य]), 1 - & gt; अज्ञातवेल्व ())} सील विशेषता मान {डीआरटी टाइपटिप: विकल्प [वर्ग [_]] = कोई नहीं} मामला वर्ग ज्ञात टाइप (टाइप: वर्ग [_] [वर्ग [_]] = कोई नहीं} ]) मूल्य बढ़ाता है {def getType = कुछ (typ)} संकलित करने के लिए ऊपर कोड विफल रहता है। कंपाइलर का त्रुटि संदेश है: Experiment.scala: 10: त्रुटि: प्रकार बेमेल; पाया गया: (इंट, ज्ञात टाइप) की आवश्यकता: (इंट, उत्पाद के साथ मान {def getType: विकल्प [java.lang.Class [_ $ 2]]}) जहां प्रकार _ $ 2 0 -> ज्ञात टाइप (कक्षा [उद्देश्य]), ^ एक त्रुटि मिली अगर मैं अज्ञातमान के लिए def getType: विकल्प [वर्ग [_]] = कोई नहीं की विधि घोषणापत्र बदलता हूं, तब भी मानचित्र ( ) टाइप मापदंडों के बिना। क्यों? हम्म, यह अजीब है मुझे एक बग की तरह दिखता है। एक तरह से आप इसे ठीक कर सकते हैं वैल्यू getTy

sql server 2005 - SQL Pivot based on value between two columns -

I have a table in which I have two columns, among other things, for a start date and the other end date for. I have to write a question which will return a column for each month of the year and the value of that column is 1 if the month is between 0. PIVOT statement What I see here, but best I can tell PIVOT section is looking to match values, do not check that the value is between the other two or not Whether the PIBT clause is constructed correctly Or do I need to break and write details of 12 cases and then add them? I think there are three basic steps I get here: Get a date in every 12 months Check whether this date is between start and end date The result of PIVOT < P> To get 12 dates, one for each month, I have a few recursive with a statement to create a temporary table with 1 column of 12 dates Used as the date (date) as the date (date) of the month (date) (select date) Unius Select date from all months (month, 1, date) where the data (month, date, Date)

What is the most efficient way to create an order count summary by hour, day, month in SQL Server 2005? -

एक तालिका को देखते हुए: तालिका #orders बनाएं (ऑर्डिड इंट, ऑर्डरडेट टाइमडेटाक) < / कोड> एसक्यूएल को वर्तमान और पिछले 24 घंटों से चालू होने वाले आदेशों की संख्या और पिछले 7 दिनों के लिए कुल ऑर्डर और पिछले 7 दिनों के लिए ऑर्डर की रिपोर्ट करने के लिए सबसे अच्छा तरीका क्या है वर्तमान सप्ताह और पिछले 4 सप्ताह, और महीनों और पिछले 6 महीनों के लिए कुल आदेश? मैं सोच रहा हूं कि यह विश्लेषणात्मक कार्यों का उपयोग करके एक एकल एसक्यूएल में कुशलतापूर्वक लुढ़का जा सकता है, या यदि 4 sql बयान पैदा करते हैं डेटा के 4 समूह एकमात्र (या सर्वोत्तम) तरीका है। इसके अलावा, प्रति घंटा / दिन / सप्ताह समूहीकरण दिया जाता है, एक एसक्यूएल सर्वर में ऐसा कैसे होगा? डीटेटमुम्स गधे में दर्द होने लगते हैं, मुझे उनके साथ ऐसा कुछ करना है ... विचार? SSAS क्यूब में रखें और वहां से हो सकता है? चुनें DATEPART (महीना, ऑर्डर डेट टाइम ), DatePart (सप्ताह, orderdatetime), DatePart (दिन, orderdatetime), COUNT (*) #orders ग्रुप से DatePart (महीने, orderdatetime), DatePart (सप्ताह, orderdatetime) द्वारा, Date

asp.net - How to preserve value of dynamic created gridview column -

I have made all the gridview columns dynamic and the column also exists checkbox. The problem with Gridview does not preserve this dynamic-built column value. For example if I have selected some line through the checkbox column and clicked on the button to get all the selected row IDs, the page becomes empty as the grid is not empty with the data value. Any help would be highly appreciated. Thanks, Alvin This probably happens when you are creating dynamic columns Are there. If the column is created in the page_load event, or after the page event process, the viewstate will not be able to populate your columns on a postback. If possible, try to create your dynamic columns in the Page_Init event, this will allow the viewsto to properly load the column.

NHibernate Passing Session to the Repository -

How do I go about passing a session for a repository class? We say that I have two projects 1) TestSite 2) Business Objects The Republican Business Objects Project is included in the project. The NHibernate session has been opened in the test site project. Now, I want to use the same session because the test site initiates the transaction on that session. Currently, I am using the following: var repository = New Customer Resor (_session); Of course, it looks ugly! I'm thinking in some way that a dependency injection frame can be tilted and I can be provided without entering the repository with the ejection object. In our WCF service, we actually use a unitofwork that wraps an operation and stores ISSN for that operation. . The repositories know how they are receiving a hint from the current unit of work under which they are running In case of testing we have a base test class, Those who are included in any test class, who touch the test database, we then control t

sqlite - How to display blob value using x'abc' binary string literal syntax? -

You can easily enter a blob value using the x'abc syntax, but display it like this Is there a way too? Using the synthesis in a string, as is shown below, does not work directly, or displays the trash (Windows DOS prompt here). sqlite & gt; Create Table Blobs (UID Blob); SQLite & gt; Insert Blob values ​​(x'0123456789abcdef0123456789abcdef '); SQLite & gt; Choose * from blobs; ☺ # ed. Eighths # eighthsqlite & gt; Choose from Blobs '' UID; I want to choose to display: x'0123456789abcdef0123456789abcdef ' Thanks, --DD choose quote (uid) from blobs Returns: X'0123456789 ABCDEF 0123456789 ABCDEF ' And if you really want it in lowercase, you can You can use it: Choose Blobs (citation (UID))

asp.net - jQuery AJAX slow in Firefox, fast in IE -

I used jQuery to post a ASP.NET Web service to implement a custom auto-full function I am here. This code works great even though it's slow in Firefox (it does not go faster than 1 second). IE is fast ignited - Great works I'm seeing posts in Firefox using firebug. Here is the service code: & lt; ScriptService (), _WebService (Namespace: = "http: // tempuri.org./"), _Windows binding (Conffooto: = WsiProfiles.BasicProfile1_1), _ Toolboxime (false) & gt; _ Public Class Test WebSvc System. Web Services. WebSwire & lt; WebMethod (), _ Script mode (Response format: Script services.Response format.Jason, Use HTPT: = True) & gt; _ Public Function GetAccounts (Byval q string) as the object 'code extracted out for simplicity returns end result function end class and jQuery's AJAX call: $ AJAX ({Before: Function (Reic) {req.setRequestHeader ("Content Type", "Application / Jason");}, Content Type: "Application / Jas

java - Detect type of object in ArrayList -

I am trying to create a class that will change the Arrayialists of objects into ArrayLists of other objects. I.e. Arreelist & lt; Foo & gt; Convert (Arreelist & lt; times> Input) {// Conversion Argument} ArrayList & lt; Bars & gt; Convert (Arreelist & lt; Foo & gt; Input) {// Conversion Argument} Unfortunately Java does not want to do two functions with the same name and it has the same input and output Believe in I am trying to go to a different route. Instead of many tasks with the same name, I want to create a function that accepts an ArrayList, determines what type of object is inside, makes appropriate conversions, and gives an ArrayList: ArrayList Convert Is such a thing possible? About how about an interface: public class converter & Lt; From, to & gt; {List & lt; To & gt; Convert (list & gt; input & gt; input); } and after that you want as many implementations for example: Personal Static Ult

emacs - How to automatically evaluate certain lisp code after starting an emacsclient? -

इमैक शुरू करते समय, init.el (या .emacs.el) का मूल्यांकन किया जाता है। हालांकि, जब emacsclient शुरू करने के लिए, कोई समान lisp कोड का मूल्यांकन नहीं किया जाता है। मैं एक नया emacsclient खोलने के लिए हर बार मूल्यांकन करने के लिए एक lisp फ़ाइल कैसे प्राप्त कर सकता हूं? (यह आसान होगा फ्रेम विशिष्ट अनुकूलन के लिए।) मुझे लगता है कि जवाब कुछ हुक का उपयोग करना है, लेकिन मुझे लगता है कि उपयोग करने के लिए सही हुक नहीं मिल सकता है। मैं आपके उत्तर की आशा करता हूं । आप हुक 'server-visit-hook , जो हर बार सर्वर को बुलाया जाता है (हर बार जब आप emacsclient कहते हैं)।

excel - Appending html files in VBA -

I have an Excel report with a bunch of sheets, with each table of data. I need to create a button that will create an HTML page containing tables, one after the other. I do not know much about HTML, so my first method was going to be a macro which makes another worksheet, with tables on it, and then using the active magazine, that letter as HTML Saves. PublishObjects. The problem is that I do not want column width to be equally distributed for all the tables in the exported files. I think the solution is to set the column width on each sheet and export the sheet individually to html, then add them all to an HTML file. Is this an easy way to accomplish this? , Or do I have to type the code to go to every HTML file and choose the related section? In the June 2001 issue of VBPJ, I wrote a column that might be a good initial for you Will work as the point. How it is shown again through a range, it is converted into an HTML table, which was then placed to paste something else on

.net - Rhino mocks - assert method was called with given parameter -

मेरी परीक्षा पद्धति इस तरह दिखती है: [टेस्ट] सार्वजनिक शून्य उत्पन्न हुआ है स्ट्रिंग उत्पन्न सीज़नम्बर = _sut.NextCaseNumber (); } _sut ऑब्जेक्ट प्रकार IPropertiesManager प्रकार के मक्खन के लिए एक निर्भरता है। विधि _sut.NextCaseNumber () अद्वितीय CaseNumber उत्पन्न करना चाहिए, इसे आईपीप्रोटीज मैनेजर में (UpdateLastCaseNumber () विधि का उपयोग करके) और उसके बाद जनरेट किया CaseNumber। IPropertiesManager प्रकार और एक ही पैरामीटर में उत्तीर्ण किया गया है जो इसे फिर से NextCaseNumber () के कॉलर पर वापस कर दिया गया? जोड़ना इस तरह से कुछ काम करना चाहिए। का उपयोग (mocks.Record ()) {Expect.On (mockObj)। कॉल (mockObj.UpdateLastCaseNumber (परम))। वापसी (परम); } (Mocks.Playback ()) का उपयोग कर {var अपेक्षित = परम; Var वास्तविक = _sut.NextCaseNumber (परम); असाधारण। (अपेक्षित, वास्तविक); } (मोज़े = नया मॉक रिपोजिटरी, मॉक ओबज = आईपीप्रोटीज़ मैनेजर)

c# - ProcessExit vs DomainUnload -

I am working on a bug where the code does not always execute before the application closes. The code was in a handler for the AppDomain.CurrentDomain.DomainUnload event. I got a post from someone with the same problem getting this advice "The domain U-load event is for your default app domain, executed by your code What you can do with the processed event on the default appdomain. " This works for me, but I would like to know why I am either of these events or between the two More on the differences of G I could not find. I am also thinking that I need to subscribe to both or process is sufficient. EDIT: I want to add more information to make it a little more useful. I came to know that the new threads were being created in their own AppDomain because I had to run this code not only when the original process was done, but whenever every thread ended, To handle the event at the end of the unit, it is necessary to subscribe to the DomainUnload event and to catch

java - Prevent system tray icon from stealing focus when clicked -

I am writing an application in Java which keeps an icon in the system tray (through). When this icon is clicked, I want it to automatically type some keys (through the class), any text field can be done in the focus while clicking (in any window ). Unfortunately, clicking on the system tray icon focus is removed from the first focused window, leading to the key stroke stolen. Is there a way to type the text in the first focused window? Probably not, at least not easily

c# - How do I configure log4net such that properties of an object can be mapped to the log output? -

By offering a SOAP web service, trying to provide an instrument for logging errors in our Flex client I am having a single parameter which is a log message object public class log message {public string message {get; Set; } Public string exception {get; Set; } Public string version {get; Set; } Public string user {get; Set; }} This object is populated by the Flex client, the client side should be the error surface and log client error is applied, which logs the error via log 4 net. Webmaster (Webmaster): Public Zero Log Client Error (Log Message Message) {rollinglogger.Error (Message); } At present, this prints a fully qualified name of the log message class, so my current assumption is that the log4net bus just calls. Toasting on the object that has been passed from inside. However, what I really want to be able to do, map every property in a pattern in the log message class so that log4net can write the desired information correctly. I would like to do this in a way t

iphone - Refreshing the UITableView from UITableViewCell -

Is there an easy way to trigger [UITableView reloadData] from within a UITableViewCell? I'm loading remote images that appear after the initial table display, and updating the image with self.image = newImage does not refresh the table by resetting the text value of the cell The table is fresh, but it looks muddy. MyTableViewCell.h @interface MyTableViewCell: UITableViewCell {} - (Zero) Image Byfered: (ImageData *) New Picture; MyTableViewCell.m @implementation MyTableViewCell - (Zero) Image Byfered: (UIImage *) newImageData {self.image = newImage; // does not refresh the table / wants to call [self.tableView reloadData] here, // but self.tableView does not exist / instead I use the bottom line self.text = self.text; // refresh table} @ and I tried to do the exact thing you did . The thing you are looking for is needsLayout for intelligence (this is a notification supervisor on my UitTable Weixel subclass): - (zero) reload image : (NsNetification *) Noti

deployment - How to Deploy a Drupal Site on a Web Farm? -

I would like to know how should I deploy on a Drupal site when I am using three servers? Is it possible to deploy with a Drupal module or some things? If it is, how does it work? Thank you. Update: I want to know about the deployment of files and the configuration of the server You should consider using it. Other useful things (Update Automatic Updates and Modules) There is a RCIN wrapper that lets you synchronize files between host (./drush sync) Also Used by the project, which is a set of modules for "Drupal, which helps you maintain many of the Drupal sites."

<operator missing when iterating through c++ map -

निम्न कोड संकलन नहीं करना चाहता। शामिल त्रुटि संदेश देखें। कोड: #include & lt; नक्शा & gt; #include & lt; vector & gt; # शामिल करें & lt; iostream & gt; कक्षा नक्शाहोल्डर {सार्वजनिक: std :: map & lt; std :: vector & lt; std :: स्ट्रिंग & gt ;, MapHolder & gt; m_map; Void walk_through_map () {std :: map & lt; std :: vector & lt; std :: स्ट्रिंग & gt;, MapHolder & gt; :: iterator; के लिए (यह = m_map.begin (); यह & lt; m_map.end (); ++ यह) {it- & gt; दूसरा.प्रिंट (); }} शून्य प्रिंट () {std :: cout & lt; & lt; "हे" & lt; & lt; std :: endl; }}; Int main (int argc, char * argv []) {मानचित्रहोल्डर m; m.walk_through_map (); } त्रुटि: $ g ++ test.cc- ओ टेस्ट टेस्ट। सीसी: सदस्य फ़ंक्शन में 'शून्य मैपहोल्डर :: वॉल्ट_थ्रू_मैप ()': परीक्षण .cc: 12: त्रुटि: 'ऑपरेटर और लेफ्टिनेंट;' के लिए कोई भी मैच नहीं में 'यह & lt; ((MapHolder *) this) - & gt; MapHolder :: m_map.std

Migrating svn 1.4 repo's to 1.6, populating node origins -

I have just advanced from SVN 1.6.1 to 1.4, and in various docs, to run and compile the svnadmin upgrade Svn-populate-node-origins-index.c is recommended and run on a repository to create a node-generation record that is faster in svn-log processing. The svnadmin upgrade has been fine and fast, H over has trouble compiling it (FC11) Do I give any indication before chasing a wild swan? svn-populate-node-origins-index: interpretation -Devel install RPM packages. Configure to create the CRDline and start the CDDline (see below for what I found). Once you have that you can cancel the compilation, to do this, I had to install socket-devail which is not included in any kind of demolition-devail. (Different configurations of backend?) Not doing this, you probably will get stuck on some off 64_t problem. (Possibly below- DOLARGEFILE64_SOURCE) Library to test and add error based on header names in the source file. FC starts to supplement libraries with header and 1, whic

javascript - Form Validations Using Prototype.js and Scriptaculous.js -

I only implement the assumptions like email, phone number etc. on my farm field using prototype js and scriptwriter.js Want to Is there any tutorial available? I do not want to use libraries such as jquery, zapatec etc. I want to use only two files Prototype Js and Scriptaculous.js. Please help. Prototype and / or scriptwriter "There is no validation" but you have to do that on the basis of those scripts Can make some helpful take a look at .

oracle - Websphere connections problem -

We run your application Websphere 6.1 and we hit an Oracle 10g database. In the past few days we have seen the following errors in our log J2CA0045E:. Connection is not available, while resource JDBC / applicable law createOrWaitForConnection for xxxxx hanging applications and then to the right after 20 minutes. Our connection pool currently allows 50 connections and our database has 1200 sessions allowed. We are unable to reproduce it in our QA environment. Does anyone have any idea how we can make this problem again, or have any idea about how we can solve it in our production environment? Thanks Damon Well, if you replicate the issue in quality assurance Eid differences can begin to identify the environment, and changing QAs to reflect the prod if possible. Which server are you using? You can copy it WTE (if you are running?) Do the same for both versions of the server that you are sure ... You said 6.1 ... but look around first look like something? ************ sta

gcc - how can i print the variable names that are used in a C program -

I want to print the variables used in my C code. It has a 19 KB file, it is used in so many variables. I know that it is not so easy .. my compiler did not tell this description .. (Debug info? ..) I am working in GCC ( Running on your sources, Then read the output tag file. It will be a list of all visible identifiers (and possibly static ones, depending on the ctags option), the files they are defining, and the location within the file This is not an indicator of local variables.

Is it possible to run multiple DDL statements inside a transaction (within SQL Server)? -

I am thinking that it is possible to run many DDL details within the transaction. I am particularly interested in SQL Server, though it may also be interesting with other databases (at least, Oracle, Postgrow). I am creating a "CREATE TABLE" and "CREATE VIEW" table inside a transaction and some discrepancies, and I am thinking that DDL should not be made within the transaction. .. I can probably move DDL out of transactions but I want to get some context for this. MSDN page clearly states that a clear under running snapshot isolation DDL operations in transactions What sanctions can be imposed - but I'm not using snapshot isolation, and it should result in an error. This can be done in such a way that the operation of DDL can be presented in a clear transaction under different isolation levels? Indicates that only one DDL statement for Oracle: In any deal it can be executed It is said that Oracle is committed to the statement of DDL? (Even

Get numbers from string with regex -

I am trying to write a regex to get numbers from such strings: Javascript: Showpage ('600 9', blank, empty, weak, empty, null, null, zero) Javascript: block link ('2146', empty, null, empty) I am Cheers IEF try it : (\ d +) Which languages ​​are you using to parse these stars are doing? If you tell me that I can help you with a code that uses this regular expression.

php - A simple explanation of common design patterns for non-native English speakers -

I am often facing design patterns, and I find it hard enough to understand that I do not understand most articles I speak English well. Or, if you have any links, I would appreciate it that someone can explain the following design patterns: Builder, Prototype, Bridge, Composite, Decorator, Foreweight, Proxy and Observer for Bus and Basic English. For good resources, I am ready to spend time trying to understand it. High, highly recommend the book. This is a good lookup tool for design patterns, although it may be difficult to read that you are not fluent in English. A list of design patterns with examples of PHP, you can see it:

wcf client - The right way to create WCF service references? -

I have a host of TCP based WCF services. Now I am creating a project that consumes that service, But there are at least two ways to add context to the service in terms of a project and both produce wildly different proxies. At first I used "add service reference" from the project menu, but it made some big files And the core of the core XML Schema net type. Then I tried SvcUtil which creates only two files, a proxy and a configuration file that holds the service reference and binding criteria, it is much better but ... In both cases V.S. Re-generating tools Definitions of type Although I have provided a reference to the assembly in which it contains the service and uses all kinds. For example, some of my service methods come back to the usual collection of unit squares. All institution classes are defined within an assembly which I have referred directly to the consumer project, then why should those types be redefined? If some body can give some advice on consuming W

asp.net - Designer.cs file creates errors automatically -

I'm flawed as, I have received some unnecessary help in creating errors in Visual Studio 2008 as a .designer I appreciate this .cs file, maybe it is due to my default or error - but I will use this excuse that I am an ASP.NET developer in reality, so I am still learning. Solution Explorer will look like this: / prototype / Project01.Master - Project01.Master.cs - Project01.Master.designer.cs /SampleApplication.aspx - SampleApplication .aspx.cs - SampleApplication Aspx.designer.cs I'm not completely sure which files are included to include in the question, so I'll try and guess that I can do as well Can i Both .Master.cs and SampleApplication.aspx.cs include themselves within the Project01.Prototypes namespace (although I am not precious about that, it is something that was added to the auto and worked and I think about it While not needed). The following is the top of SampleApplication.aspx (In order to enable access to some properties, the master page is disp

How to get git-status of a single subfolder? -

When I position GIT in the subfolder of my repository, it also includes the status of the parent folders. Is there any way to distribute the git-status only in a particular folder? git status. Will show the status of the current directory and subdirectory. For example, the files (numbers) given in this tree: sub-directory "b", git status from the show / 1A / 2B / 3B / 4B / C / 5B / C / 6 New files in whole tree: % git Status # Branch Master # # Initial commitment # # Changes to change: # ("git rm --cached & lt; file & gt;.") # # New file: ../a/1 # New file:. ./a/2 # new file: 3 # new file: 4 # new file: c / 5 # new file: c / 6 # but git status. Just shows "B" and the file below. % git position # # # new file: # # new file: # # # # new file: # # new file: # # new file: # # new file: # # new File: # (# git rm --cached & lt; file & gt; C / 5 # New file: c / 6 # Just this subdirectory, not below < P>

EVAL in SCHEME -

Peter Norwich in PEP says: In modern lisps ... Evil is often used (in fact, if you find yourself using a scheme, then you are probably doing the wrong thing. " What is the reason for using Evil in the scheme? Is there a case where eval is absolutely necessary? In such cases where eval is required, but they always have advanced programs Do things like dynamically loading D. (eg, servlet in web server), the way to "restrain" to use it - it depends on the real problem you are trying to solve, < There is no magic solution to avoid code> eval ... eval . (My guess is that PAIP was written before, before < Code> eval was added to the scheme report.)

Does Visual C++ 2010 Beta 1 have unique_ptr, and if not, where can I get a C++0x reference implementation? -

I know: It was not in CTP < I want to play with it This is in the same header as the shared_ptr: #include & lt; Memory & gt;

asp.net mvc - How do I get the current user in an MVC Application? -

संभव डुप्लिकेट: मैंने विभिन्न चीजों का एक झुंड लगाया है, मुझे पता है मैंने वेबफॉर्म का इस्तेमाल करते समय पहले किया है, लेकिन मुझे यह पता नहीं लग सकता कि यह एमवीसी में कैसे करना है। टी काम उपयोगकर्ता मुझे एक आईपी्रीनसिफ्ट या कुछ उपयोगकर्ता देता है। Identity मुझे एक ही प्रकार का चर देता है ... किसी को भी पता है? क्या कोई गेटक्रोरेंट उपयोगकर्ता () विधि या कुछ समान है? मेहरदद का जवाब यहां देखें: < P> वह बताता है कि आप User.Identity // कंट्रोलर में HttpContext.User.Identity // में नियंत्रक System.Web.HttpContext.Current.User.Identity // में उपयोग कर सकते हैं। कहीं भी

javascript - Firefox: Get mouse coordinates of top-left corner of viewport -

Good day all. I am working on a Firefox extension, and I have a tooltip on a fixed offset with a mouse cursor, however, the problem occurs when the offset goes out of the viewport, but it is displayed to the user There you have to scroll over. I hope to increase this by moving tooltip pop-ups to the current viewport. However, a problem arises because I have only a clue where I am in the document, the mouse-position is to calculate the partial solution that the tooltip's width / height and coordinate of the current window + tooltip width / Height indicates how much it takes the tool tip, to see if it is more than window. WinnerHight or Window Winner However, I realized that if this was a long document and the user used to scroll down a fair bit, then the mouse coordinate would have a very large Wi value. So, I can not completely trust the window. The winner to see if I am now in the viewport, has a person found a way to locate the mouse coordinate of the upper left corner

How do I share variables between different .c files? -

इस सवाल का पहले से ही एक उत्तर है: < 14 जवाब सी घोषणा के बारे में शुरुआती प्रश्न: / p> एक। सी फ़ाइल में, किसी अन्य। सी फाइल में परिभाषित चर का कैसे उपयोग करें? फ़ाइल ए में: int myGlobal = 0; में fileA.h extern int myGlobal; में fileB.c: #include "fileA.h" myGlobal = 1; तो यह कैसे काम करता है: fileA.c में चर रहता है fileA.h दुनिया को बताता है कि यह मौजूद है, और इसका क्या प्रकार है ( int ) fileB.c में fileA.h भी शामिल है, ताकि कंपाइलर myBlobal के बारे में जानता है इससे पहले कि fileB.c इसका उपयोग करने की कोशिश करता है।

php - Return Data and Type of mysql_fetch_array() -

निम्न 3 मानक कथन पर विचार करें $ queryString = "कुछ एसक्यूएल का चयन करें"; $ QueryResult = mysql_query ($ queryString); $ QueryArray = mysql_fetch_array ($ queryResult); सवाल है: यदि क्वेरी का परिणाम सेट रिक्त है, तो परिणामस्वरूप डेटाटाइप और $ queryArray के बाद क्या होगा सभी तीन बयान निष्पादित हैं? से: एक अंतिम वापसी मूल्य होगा।

installer - Should I worry about redistributing .NET runtime with my application? -

If possible, with my application. I would like to refrain from redistribution to the NET runtime because it will increase the size of the app, download time, time of development & amp; Will potentially implement several deployment errors? Does Microsoft Force users run .net runtime through updated Windows Update? If not, what are some options to redistribute the NET Runtime? Has Microsoft made it easy to redistribute runtime again? Besides, is the NIT runtime guaranteed to be backward compatible? I'm just summarizing the answers here. It seems that we must have bootstrapper at least check for the existence of .NET run time. The alternative option is to run a runtime and if it does not exist it is to deploy it. There are many options for packaging & amp; There is also other packaging options like InnoSetup, WIX etc. (not sure which option is better and free) with reboot required for runtime installation and the selected installation option Should restart the applicatio

Adding unit testing to an existing asp.net web forms application -

I have an existing asp.net webforms application that I would like to add some unit tests to but actually make sure that How to go about it This application is a functionality-driven database that I think you can compare with the advanced forum. How should I test? How do I handle databases and test data? Is any tool recommended to help in this? The first thing you need to decide is: Em> Unit tests to add your What is inspiration? There are many excellent reasons for being a unit test (I'm practicing TDD strictly), but knowing that what is your main motivation power is the matter to you. You should help to make sure which test will first be written. In most cases, you should consider writing unit tests for areas of your application, which is causing you the most pain in the past. A lot of experience has been shown that when the software was originally written without a unit test, then it may be difficult to retract unit tests later on. Provides valuable gui

Is it possible to develop DirectX 9 apps using the latest DirectX SDK? -

I know that most people have DirectX 9-capable cards but for developing DX 9 app apps, DirectX 9 SDK Is it really necessary to install or is it possible to use the latest DX SDK? The latest DirectX SDK supports DirectX 9, DirectX 10, and Preview of DX11 Includes. You can use it to develop against any of these DX versions. You need a DX SDK to develop for DirectX, as long as you are not indirectly through the library, header files, libraries etc are included in SDK. It is being said, even if you are using a library, you want to install the latest SDK - it is very difficult to debug DX applications without SDK, because SDK allows you to use the debug version . DirectX

Generate interface from solid class file in Eclipse -

Is there a plug-in in Eclipse that generates solid-square / impile class-based interface? Currently I code code interface. Just select the Remove Interface ... Select Refactor menu.

visual studio - c++ compilation error -

निम्न कोड विज़ुअल स्टूडियो 2009 में संकलन त्रुटि दे रहा है। #include & lt; iterator & gt ; #include & lt; vector & gt; टेम्पलेट & lt; वर्ग T1, वर्ग T2 & gt; वर्ग ए {सार्वजनिक: टाइप नाम Std :: vector & lt; std :: pair & lt; T1, T2 & gt; & Gt; :: इटरेटर इटरेटर; Std :: जोड़ी & lt; iterator, bool & gt; फू (कॉन्स्ट स्टडी :: जोड़ी और एलटी; टी 1, टी 2 & gt; और amp; value_in); }; क्या कोई उस पर कुछ प्रकाश डाल सकता है? यह त्रुटि है। त्रुटि C2327: 'ए & lt; T1, T2 & gt; :: इटरेटर': एक प्रकार का नाम, स्थिर, या गणक नहीं है यह घोषित करता है कि iterator एक चर (एक प्रकार नहीं): typename std :: vector & lt; std :: pair & lt; T1, T2 & gt; & Gt; :: इटरेटर इटरेटर; क्या आप इसका मतलब है? टाइप टाइप करें टाइप नाम std :: vector & lt; std :: pair & lt; T1, T2 & gt; & Gt; :: इटरेटर इटरेटर; अधिक जानकारी: यदि आप उत्सुक हैं कि क्या typename करता है, तो अंतर के बीच और गैर-निर्भर नामो

How to use dict in python? -

10 5 -1 -1 -1 1 1 2 ... यदि मैं एक फ़ाइल में प्रत्येक संख्या की संख्या की गिनती करना चाहता हूं, तो मैं इसे कैसे करने के लिए अजगर का उपयोग करूँ? यह अनुराग उन्ियाल के उत्तर में वर्णित बिल्कुल सटीक एक ही एल्गोरिथ्म है, फाइल को readline () : के बजाय इटरेटर के रूप में छोड़कर, संग्रह आयात डिफ़ॉल्ट से आज़माएं: IO आयात स्ट्रिंगियो # 2.6+, 3.x को छोड़कर आयात ईरर को छोड़कर: StringIO आयात से स्ट्रिंगआईओ # 2.5 डेटा = डिफॉल्ट डीआईसीटी (इंट) # ओपन के साथ ("फाइलनाम", "आर") एफ: # अगर स्ट्रिंगआईओ के साथ असली फाइल ("10 \ n5 \ n-1 \ n-1 \ n-1 \ n1 \ n1 \ n0 \ n2") च के रूप में: f में पंक्ति के लिए: डेटा [int (line)] + = 1 संख्या, संख्या में डेटा.iteritems (): प्रिंट संख्या, "पाया गया", गिनती, "समय"

python - Display row count from another table in Django -

class hardware node (models.Model) Ip_address = models.CharField (max_length = 15) port = models.IntegerField () location = models.CharField (max_length = 50) hostname = models.CharField (max_length = 30) def __unicode __ (self): return self.hostname class membership (Models.Model): Customer = Model. Exotic (customer) package = model. Foreign key (package) location = model Forward (hardware node) upgrade_data = model.DateimField ('renewal date') def __unicode __ (self): x = '% S% s'% (self.customer.hostname, str (self.package)) x I want to count on the number of membership on a particular hardware node and show that 10 memberships hosted on node 2 on the admin section for HardwareNode class. I am still learning about the Django and I am not sure how to complete it. Can I do it in models.py or in HTML? Thank you, -seth a When creating foreign_key , another model gets a manager who gives all examples of the first model (see) in your case, it will be name

language agnostic - How prevalent is UTF-8 really? -

How is UTF-8 used for non-English text, on WWW or otherwise? I am interested in both statistical data and status of specific countries. I know that ISO-885 9-1 (or 15) is firmly embedded in Germany - but languages ​​where you have to use multibeat anyway, encoding like Japan or China ? I know that a few years ago, Japan was still using various JIS encoding. Looking at these comments, will it also be true that UTF-8 is the most common multibyte encoding? Or would it be more correct to say that it is basically used internally only in new applications, which specifically targets an international market and / or working with multi-language texts? Is there an app nowadays which only produces UTIF-8, or hopes to keep output files in a different legacy encoding to be able to be usable by other national markets relatively other apps. Edit: I'm not asking if UTF-8 is useful or how it works. I know all this I am asking that this is actually being widely adopted and the old encodin

windows - detect client process termination from EXE COM Server -

I am writing an EXE COM server that exposes a system that locks the system resource in the normal execution client (Com executes off after a few seconds.) In unusual performance, the Client app crashes, leaving Com sec in the positive segment count with an example. The COM execution runs up to ~ 12 minutes This means that system resources have been locked during this time. Is there any way to detect client termination as a socket IPC or driver protocol? It does not seem that COM is weak compared to other IPC mechanisms. A few years ago I had only one question. I got the answer here :. In summary: No, there is no way to immediately detect client closure. Example: When a COM client terminates normally, it releases all references to its server object. When a customer ends abnormally, there may be outstanding references to server objects. There is no way to know about the Ection mechanism without garbage collaboration, the resource code allocated to the COM object in the serv

binary - What is “2's Complement”? -

I am in a computer system course and is struggling , in part, together. I want to understand it, but whatever I have read has not taken a picture for me. I have read many other articles, which include. Therefore, I want to start the Community Wiki post to determine which two are complementary, how to use it and how to use it cost (like signature Signed and vice versa), bit-wise operation and bit-shift operation during the operation can affect the numbers. What are I hoping for? A clear and concise definition which can be easily understood by a programmer. Two supplements are a clever way of storing an integer , You have to think about numbers in binary. It basically says, For zero, use all 0. For positive integer, maximum 2 (number of bits - 1) -1 Li> For the negative integer, do the same thing, but 0 And the role of 1 (instead of starting with 0000, instead of starting 1111 - this is the "complement" part.) Try it with a 4-bit mini-byte A

visual studio - What do the different scopes in WSPBuilder do? -

When creating a new WSPbuilder project or a new WSPBuilder item in Visual Studio, you must choose the scope of the item being created Web, Are sites, web applications and forms. What do various scopes do, and how does it affect the deployment? What location do you use to use? See Scope 'Feature Scope Level' feature scope determines that the functionality provided How can be used. Form: Web application: in one SharePoint farm and all its web applications, site archives and webs < Strong> In a web application and all its site collections and on the web Site: in a site collection and Web: In the same web The scope of the scope depends on which type of feature you use and you want to use it. If you want to restrict the use of a custom action feature in a particular Web, then its scope does not allow use at the web application level. Also, depending on what kind of facility you are making, every scope is not available (see this).

c# - Visual Studio: Make debugger aware that a function doesn't cause "side effects" -

I have an object that I get to see function output multiple times through the clock window. The problem is that every time I press the Fresh Button, because "This expression is the cause of the side effect and will not be evaluated" Anyone like to tag a function with something like [DoNotCauseSideEffects] The way, so every time I take action, can the clock be automatically evaluated? I'm coding in VS 2008 or 2010. Edit: The function looks and does, as you can see, there is no reason for any side effects. (X, y, z are all pairs) Public override string toasting () {return "{" + x.ToString (".00") + "," + y.ToString ( ". 00") + "," + z.ToString (". 00") + "}"; } You can add , ac to the clock expression To automatically refresh the price: x.ToString (), AC See MSDN for more information and more.

Rapidshare API question -

When I get feedback from the query, between the other variables, I .......... ... validated = 1251783433 .........., which tells me the exact end date. My question is how to change this integer in normal date time format. that number (1251783433) is known as. In most programming languages, there are ways to convert from Unix timeline to a date / time format.

javascript - jquery ajax parse response text -

OK, it really disappoints me because I have done it a hundred times earlier, and this time it is not working Has been doing. So I know that I am doing something wrong, I can not understand it. I am using jQuery. I do not want to use .load because it always replaces the element's children which I am loading content. It's mine. Request: $ (document) .ready (function () {$ .get ('info.html', {}, function (html) {// debug code console.log ( $ (Html). Find ('ul') .HTML ()); // and debug code}};}); File 'info.html' with a proper functionality There is a standard xhtml file, and the only thing in the body is a series of ul that i need to access. For some reason, the function is giving me a zero value. In firebug, the GET request is appropriate The answer is showing the text and when I console.log (html); instead of the current console. I get full information html output, just like I expected . Any ideas? You can not drag a complete

java - Checking for a Valid Path when Uploading a File Using commons-fileupload -

I am working with a code that uploads an image from a form and stores it on our servers In Internet Explorer the user can manually enter the path, and I wonder how I can see that the file exists, i.e., the user has entered a valid path. There is a file unit object that is being used to check size (for example, fileItem.getSize () if (fileItem.getSize () == 0) {// Some are wrong- invalid path. } Else {// file exists - valid path} Any suggestion is appreciated. Thanks! On the client, you can not read the text of the file upload control trustably with the script. For example IE8 and Opera 10 will lie to you and provide a common path containing "C: \ forgiveness \". This is done for privacy reasons. On the server, you can do the same way you did, just check to see that you got the file in the upload, and if so, you can check the file, set Make sure that it matches your criteria.

javascript - First sums, second doesn't -> why? -

& lt;! - पहले - & gt; & LT; स्क्रिप्ट & gt; Var कुल = 0; Var newAccumulator = function () {रिटर्न फ़ंक्शन (i) {total + = i; }; } Var foldl = function (arr, putNum) {for (var i = 0; i & lt; arr.length; ++ i) {putNum (arr [i]); }} गुनाह ([1, 2, 3, 4], नया आकस्मिक ()); Document.write ("योग:" + कुल + "& lt; br / & gt;"); & Lt; / स्क्रिप्ट & gt; & Lt;! - सेकंड - & gt; & LT; स्क्रिप्ट & gt; Var कुल = 0; Var newAccumulator = फ़ंक्शन (i) {कुल + = i; } Var foldl = function (arr, putNum) {for (var i = 0; i & lt; arr.length; ++ i) {putNum (arr [i]); }} गुनाह ([1, 2, 3, 4], नया आकस्मिक ()); Document.write ("योग:" + कुल + "& lt; br / & gt;"); & Lt; / स्क्रिप्ट & gt; कॉल में foldl आप नया एक्सेमुलेटर फ़ंक्शन: गुनाह ([1, 2, 3, 4], नयाएकुम्युलेटर ()); पहले मामले में यह एक समारोह देता है जो संक्षेप करता है: रिटर्न फ़ंक्शन (i) {total + = i; }; दूसरे मामले में newAccu

logging - Object Disposed Exception when using .Net Trace Source within VS UNit Tests -

When I tried to call TraceSource.TraceData with your VS2008 unit test project, so I got the object Exception Exception Used to be. I have included a very small code sample below, which repeatedly issues this issue. I'm seeing this after running my first unit test - but in my journey it will increase once on my website and affect me if I run with many users. This is like the underlying stream, after the first unit test, the 'overflow' gurus can be greatly assisted by the closed ones. Step: 1) VS Make 2008 Unit Test Project 2) Add a class with this code: Namespace Tracing Error {Using System.Diagnostics; Use of Microsoft Visual Studio Test Tools Unitatistics; [Test class] public class unit 1 {public status traceSource ts = new trace source ("trace test"); [TestMethod] Public Zero A () {ts.TraceEvent (TraceEventType.Information, 1, "Hello AA"); } [TestMethod] Public Zero (B) {ts.TraceEvent (TraceEventType.Information, 1, "Hello from B&qu

javascript - jQuery Cross Site Fetch -

I think this is easy, but I'm missing something ... jQuery Using, I'm trying to get a remote page (on a different server), capture the HTML content, and insert that content into the hidden divisions. However, either $. By using AJAX or $. Get results in cross-site scripting error in Firefox. Any suggestions? Code: $ Ajax ({type: 'GET', url: "http://www.remote-url.com", datatype: 'html', success: function (data) {$ ('# Put_here') empty (). Append (Data);}}); Thanks! Chad You can not do this - it prevents security reasons ( As you've found). You need it on your server that your Javascript uses the Remote Server to fetch content from its side.

Managing Implicit Type Conversion in C++ -

I'm working on code that does the closest neighbor questions. There are two simple ideas that a user can ask for the query of the search data: The nearest N points to the point given in space. Distance. In my code, the point is placed in a point list, and the point list is the task of keeping track of points near a container that has been found in search. Right now my point list object is a constructor: point list (maximum maximum unsigned); The next two constructors I want to add are: Point list (float maxdist); // # 2 point list (unsigned integer max, float maxdist); // # 3 My question is how can I ensure that my users and C ++ compilers will generate the right constructor for the pointylist and the difference between consultants 1 and 2 ? Can I execute just 3 and give the constants that defines arbitrary big values ​​for Maxwell and MaxDist? Another option could write a second system of light objects that controls the argument to add points to the list, bu

ruby - Using a duration field in a Rails model -

I am looking for the best way to use a duration field in the Rail model. I should have format HH: MM: SS (ex: 01:30:23). The database used is locally scalable and postgres in production. I would also like to work with this area so that I can see all things in the field and I can come with the total time of all the objects of that model and thus will end with something like this: / P> 30 records total 45 hours, 25 minutes and 34 seconds. > Store as an integer in your database (number of seconds, probably) Your login form will depend on the exact usage case. Dropdowns are painful; Better to use small text fields for hours in hours + minutes + seconds. Just run a SUM query on the duration column for a large total production. If you use an integer, it's easy and fast. Additionally: Use the helper to display the duration in your scenes. You can easily make an integer of ActiveSupport :: duration ( 123 with integer from database) using

sql - debug ssis package - reload InnerPackage.dtsx -

I used a wizard to create a package that ends through my tables, whatever it does It has worked for ever and now I have to change it. How can I debug this thing on the earth? When I try to run it with dialects, it opens InnerPackage.dtsx for editing and then asks me if I want to reload it (since it has changed since the last recursion of the loop) . I can not press Yes or no faster to stop the package because 'the process can not access the file because it is being used by another process' How can I keep it from opening so that I am at this point I can go that it's really failing when the server runs the package and fixes it a lot. The wizard uses some of the things behind "magic" that it actually makes debugging The harder you can do the best to re-package itself is more work, but you can debug it more easily.

intellisense - Syntax highlighting component for .NET -

I'm one. Looking for NET component which is free and includes the following features: Real-time syntax highlighting (HTML, VBScript, ..) Intellisense ( I can create my own intellisense library) Line number I got from ScintillaNET but I wonder if there is a better component? Please help me, thank you! You can use ICSHRPCD. . I do not think this is available as a separate download, but you can get it from SharDDevelop.

Change Visual Studio 2008 HTML indentation style -

Visual Studio 2008 insists on pointing to HTML like this: & lt ; H1 & gt; Title & lt; / H1> & Lt; H2 & gt; Subtitles & lt; / H2 & gt; For me, this is pretty good: & lt; H1 & gt; Title & lt; / H1> & Lt; H2 & gt; Subtitles & lt; / H2 & gt; Is there a way to tell Visual Studio 2008 to use the later version of an indentation while auto-formatting? Option, under HTML, go to "Format" and click on "Tag Specific Options" Then find the tags that you want to change (H1, H2, etc.) and uncheck indent content () The above guide is for Visual Studio 2005, so for 2008 It may be a bit different, but I'm sure you'll find it.

ruby on rails - What is a better way to check for a nil object before calling a method on it? -

I have a call to this method that I want to use ... financial_document .assets length but financial_document.assets can be zero . I could use ... financial_document.assets.nil? ? '0': financial_document.assets.length Is there a repetitive method to do this? Personally, I use or operator / Keywords: (financial_document.assets or [] By any means, say .length on an array Goes to 0 if zero .

jsf - Custom getEntityNameSelectList() fails -

Writing an ordinary JSF application I have done something in the following problem: My organizations Controller One method in the Antitenom Manager class is getEntityNameSelectList () which I can use to populate the combo box. It works and shows all the institutions, because the method of retrieving the institution does not have a section where the section was automatically created. Now I have to put a similar method, which filters options based on a variable in sessions. To do this, I copied the original method, named it anonymity for the name, the user name (user theUser) and changed the method that changed the database to the query that actually filters by UserId. However, when trying to load the page, the browser receives an error saying that the "EntityNameSelectListByUser" property does not contain the property in the controller class, because I believe that because of my new method It is believed that this one parameter can not be found. Is there any way I can

cocoa touch - disable UIViewController content animating on iPhone rotation -

मुझे अपने UIViewController subclass के व्यवहार को कार्यान्वित करने की आवश्यकता है जैसे standart iPod.app में: जब डिवाइस पोर्ट्रेट से लैंडस्केप पर घुमाया जाता है समस्या यह है कि, जब सेट - (BOOL) होना चाहिएअथोरोटेटटोइंटरफेसऑरेंटेशन: (UIInterfaceOrientation) इंटरफ़ेसओरिएन्टेशन {वापसी हाँ; } सामग्री घूर्णन कर रही है लेकिन जब सेट - (BOOL) होना चाहिएअथोरोटेटटोइंटरफेसओरिएन्टेशन: (यूआईएनपरफेसऑरियन्टेशन) इंटरफ़ेसओरिएन्टेशन {वापसी नहीं; } फ़ंक्शन - (शून्य) didRotateFromInterfaceOrientation: (UIInterfaceOrientation) से इंटरफेसऑरियन्टेशन {एनएसएलॉग (@ "इंटरफेस ओरिएंटेशन% डी घुमाएँ, इंटरफेस ऑरिएन्टेशन से)"; } नया नाम है तो, क्या आप जानते हैं कि डिवाइस को घूर्णन किए बिना डिवाइस के घूर्णन को कैसे नियंत्रित किया जा सकता है? असल में, आप नहीं चाहते कि आपके दृश्य नियंत्रक इंटरफ़ेस अभिविन्यास रोटेशन का जवाब दें। इसके बजाय, UIAccelerometer सूचनाओं का पालन करना आसान है । तब दृश्य का एक पूर्ण स्वैप करें। आप यहां ऐसा करने के लिए कोड देख सकते हैं: और

difference in C# and PHP OOP -

मेरे पास एक सामान्य OOP प्रश्न है अगर मेरे पास सी # में निम्न वर्ग हैं वर्ग अभिभावक {public string val = "parent"; सार्वजनिक शून्य getValue () {Console.WriteLine (this.val); }} वर्ग बच्चे: माता-पिता {सार्वजनिक स्ट्रिंग वैल = "बाल"; } बाल बच्चे = नया बच्चा (); child.getValue (); कोड आउटपुट 'पेरेंट' जैसा कि मैं समझता हूं क्योंकि यह माता-पिता को इंगित करता है, ठीक है? अगर मैं PHP5 में ऐसा करता हूं: class ParentClass {public $ val = 'parent'; सार्वजनिक समारोह foo () {echo $ this- & gt; val; }} क्लास चाइल्डक्लास ParentClass को बढ़ाता है {सार्वजनिक $ val = 'child'; } $ A = नया बाल क्लास (); $ एक करने के लिए & gt; foo (); इसका परिणाम 'बच्चा' होगा। यद्यपि मैं सार्वजनिक $ val = 'parent' बदलूंगा; से निजी $ val = 'parent'; तब PHP 'माता-पिता' भी दिखाएगा सी # हमेशा पब्लिक और निजी एक्सेस मॉडिफायर दोनों के साथ 'पेरेंट' लौटते हैं। क्या इसके लिए कोई कारण है? और कौन सा व्यवहार

c# - How to get Max String Length in every Column of a Datatable -

मेरे पास डेटाटाबल वस्तु है प्रत्येक कॉलम प्रकार स्ट्रिंग की है। LINQ का उपयोग करके, मैं प्रत्येक कॉलम के लिए अधिकतम स्ट्रिंग लेट कैसे प्राप्त कर सकता / सकती हूं? पूरी तालिका के लिए अधिकतम स्ट्रिंग लंबाई (कम से कम एक गैर-शून्य मान मानिए, अन्यथा, अधिकतम एक अपवाद फेंक देगा): int maxStringLength = डेटाटेबल.एस्अमेर्यूमेरेबल ()। सेलेक्टमोबाइल (पंक्ति = & gt; पंक्ति.आईटम एरा.ऑफटाइप & lt; स्ट्रिंग & gt; ())। एमएक्स (str = & gt; str.Length); यदि आप प्रत्येक कॉलम के लिए अधिकतम स्ट्रिंग लम्बाई चाहते हैं, तो आप ऐसा कर सकते हैं (प्रत्येक कॉलम में कम से कम एक गैर-रिक्त मान मानना, अन्यथा, अधिकतम एक अपवाद फेंक देगा): सूची & lt; int & gt; अधिकतम लेन्थफ़ोअर कॉलम = संख्यात्मक.रेंज (0, डेटाटबल.कॉलम.काउंट)। चयन करें (col = & gt; डेटाटैबल.एक्सएनेमरेबल ()। चयन करें (पंक्ति = & gt; पंक्ति [कोला])। OfType & lt; स्ट्रिंग & gt; () .Max (val = & Gt; val.Length))। ToList ();

Why can't I send email using Perl CGI script on CentOS? -

I am using it. CGI is working, but I can not send emails from this form CentOS Please help me Do I have to set up anything for this? Or MTA? Hm, hard to check, it commentes quite generously, unfortunately in Japanese: - /. What I can see from this, it expects you to set the variable $ server as an SMTP server that accepts outgoing mail so you will need an SMTP server.

How to display HTML using .NET in an interactive way -

What I basically want to do is take some HTML and display it in a way when you mouse Element, application I am pointing out that I can parse the HTML I want to do with the .NET Framework. Using IE is fine in my project and I basically want to edit HTML so that when I split on a table, the range of the table is bold and with a different color being formed. Edit what I'm actually doing is downloading HTML from the Internet and then processing it. I basically want a tool that can see a web page, and then when I look at the mouse on different elements, my application can parse the same HTML to do this What's the best / easiest way? This is not really a C # .NET question because it is a server-side technology. Using jquery you need to see javascript and javascript questions to get global response. Take a look at and you can write some code like this. $ ("table"). Hover (function {$ (this) .addClass ("table_border");}, function () {$ (this) .remo

ejb 3.0 - Configuring an MDB in JBOSS -

कैसे maxMessages गुण MDB को प्रभावित करता है? उदाहरण के लिए: @activationConfigProperty (propertyName = "maxmessages", propertyValue = "5") यदि अधिकतम सत्र 10 है तो यह कैसे प्रभावित होगा? इस पर थोड़ी ऊनी होती है, वे कहते हैं कि मैक्स मैसेज को के रूप में परिभाषित किया गया है सत्र की डिलीवरी करने से पहले प्रतीक्षा करने के लिए संदेश की संख्या, प्रत्येक संदेश को अभी भी एक अलग लेनदेन (डिफ़ॉल्ट 1 ) मुझे लगता है कि आप सोच रहे थे कि क्या यह एक बार में एमडीबी से गुजरने वाले थ्रेड्स या समवर्ती सत्रों की संख्या को प्रभावित करता है, लेकिन ऐसा लगता है कि यह पैरामीटर उस व्यवहार से संबंधित नहीं है, और इसलिए कोई संघर्ष नहीं है।

vb.net - I have a Tags Table. How to Bulk Insert using LINQ? -

I am using VB.NET with LINQ from MS SQL. I have two following tables, now I want to add multiple items in the tag table using LINQ, but also want to see that any tags in the tag table are present. It does not reinclude it, and in both cases, the tag is inserted (if it has been inserted or if it exists) created tab tags (tag wide built tap, tags Vertical (100) null) Videotag (Videind Blinkt is not empty, TagImit bilint is not empty) What is the best way to use LINQ? In advance thanks LINQ is an query technique , But I think we know what you mean; You want to be a bit more specific whether it is LINQ-to-SQL or Entity Framework. You can also clarify what the "bulk" means in your case ... For 10-100 records, you have 10,000 records (Where it would be best to import a staging table in SqlBulkCopy and an Archived Functional DB). For a relatively small number - just use your ORM tool to find the record - for example LINQ-to-SQL (probably spreading serialized t

MySQL + Windows VISTA / 7 = Crashes with Eclipse RCP + Datanucleus app -

मुझे माईएसक्यूएल + डेटान्यूक्लस + ​​विंडोज विस्टा / 7 के साथ एक बड़ी समस्या हो रही है। समस्या तो बहुत कुछ है, माइस्क्ल सर्वर बंद हो गया! समस्या ओक्कोर्स: डीएन 1.0.0.एम 3 + MySQL 5.1.x (लोकल) + विस्टा के साथ। किसी ऑब्जेक्ट के हटाए जाने पर, जिसकी संरचना में एक लिस्ट है (एक हटाएंपरिसेंट सभी लिस्ट का मुख्य ऑब्जेक्ट को हटाने से पहले जारी किया गया है) कोई समस्या नहीं: PostgreSQL के साथ। ऑब्जेक्ट के साथ हम यहां दर्द में हैं !!! : - \ धन्यवाद। मार्को 1 )। आप डेटा न्यूक्लियस के प्राचीन संस्करण का उपयोग कर रहे हैं। 2)। आप कोई अपवाद नहीं उद्धृत करते हैं, और यदि वे समान हैं जैसे आप डेटा न्यूक्लियस फ़ोरम में उल्लिखित हैं तो समस्या लगभग निश्चित रूप से विंडोज़ पर MySQL का विन्यास है।

winforms - C# - Partial Class in the VS2005 project -

संभव डुप्लिकेट: मैं VS2005 प्रोजेक्ट में आंशिक वर्ग कैसे जोड़ सकता हूं ताकि यह मुख्य फ़ाइल के लिए फ़ाइल के पीछे कोड के रूप में दिखाई दे? उदाहरण के लिए: मैं अपने वर्ग की संपत्तियों को नामित फ़ाइल में रखना चाहता हूं, MyClass.cs और मैं MyClass.attr.cs नाम की फ़ाइल में मेरे क्लास-एट्रिब्यूट को रखना चाहते हैं। जब मैं वीएस 2005 प्रोजेक्ट खोलता हूं, MyClass.attr.cs -फ़ाइल MyClass.cs के लिए फ़ाइल के पीछे एक कोड के रूप में दिखाई देगा, जैसे Form1.cs और फॉर्म 1। डिज़ाइनर सीएस एक विनफ़ॉर्म एप्लिकेशन में। अपने .csproj फ़ाइल में 'कक्षाओं के लिए अलग टैग देखेंगे, जैसे: & lt; संकलन शामिल करें = "MyClass.attr.cs" / & gt; & Lt; संकलन शामिल करें = "MyClass.cs" / & gt; MyClass.attr.cs के लिए प्रविष्टि को इस तरह बदलें: & lt; compile शामिल करें = "MyClass attr.cs "& gt; & LT; DependentUpon & gt; MyClass.cs & lt; / DependentUpon & gt; & Lt; / संकलित & gt;

Is there a CLR profiler that works with .NET 3.5 SP1 and WPF? -

In all my searches, I have only found out that old CLR profiler should work for .NET 2.0 .NET 3.0 Or with 3.5 applications. When I try and use the .NET 3.5 SP1 WPF application for .NET 2.0 with CLR Profiler, it starts my application well, but it throws a dialog < Em> "normal language is waiting for application to start runtime" . Since my application clearly uses CLR, I can only conclude that the new version of the CLR Profiler framework for .NET 2.0 (maybe this is just a problem with the 3.5 SP1 app is). So, does anyone know whether there is a version of CLR profiler with 3.5 SP1? If there is no version of Microsoft's profiler, then what is another free profiler I can use? > I just tried to run CLR Profiler with a WPF application, and it takes some time to start the app works fine (more than non-WPF applications, it seems), but it Works. Update: Date just to answer the answer; According to the comments given below, the solution was to run the CLR

jquery - create Javascript object to pass to wcf service call -

मेरे पास WCF webenabled सेवा में निम्नलिखित विधि है सार्वजनिक व्यक्ति AddPerson (person p); पारंपरिक asp.net अनुप्रयोग में अब मैं स्क्रिप्टमैनेजर का उपयोग कर रहा हूं और यह मुझे एजाक्स कॉल में पास करने के लिए जावास्क्रिप्ट ऑब्जेक्ट बनाने की अनुमति देता है Var व्यक्ति = व्यक्ति (); Person.name = "mamu"; फोननंबर = 911; अजाक्स सेवा। एडप्रेस (व्यक्ति, कॉलबैक (), रिक्त, रिक्त); अब मैं asp.net mvc में jquery का उपयोग कर एक ही बात की कोशिश करना चाहता हूँ। लेकिन विविध व्यक्ति = व्यक्ति (); किसी भी अधिक उपयोग नहीं किया जा सकता क्योंकि कोई स्क्रिप्ट प्रबंधक नहीं है स्क्रिप्टमैनेजर अब तक देखभाल या रूपांतरण सामग्री ले रहा है, लेकिन ऐसा लगता है कि jquery ऐसा नहीं करता है या कम से कम एक ही तरह से नहीं है। मैं इस jquery का उपयोग करने के लिए क्लाइंट-साइड जावास्क्रिप्ट पर इस व्यक्ति का ऑब्जेक्ट कैसे बना सकता हूं? एजेक्स कॉल? // व्यक्ति वस्तु बनायें, मामला संवेदनशील वरीयता वाले व्यक्ति obj = {name: "ममू", फ़ोननंबर: "911"}; // कॉलबैक फ़ंक्शन, जब पोस्ट