Posts

Showing posts from March, 2013

c# - Instead of making an if() for each control type, is there a cast that will allow me to dynamically set the type of control? -

I am running through my controls on this web page again and when to modify a piece of data data I am disabling other controls on the page, such controls include textboxes, listboxes and buttons. All of these controls, so there was a way to just set its properties universal data type cast control of any kind and capable then I was thinking protected void DisableSQRcontrols (Property Control page) {foreach (Control Ctrl in Page Ctrl.Controls) if (ctrl is text box) ((text box) ctrl). Competent = false; And if (ctrl button is) ((button) ctrl). Enabled = false; And if (ctrl listbox is) ((listbox ctrl). Enabled = false; And if (ctrl.Controls.Count> 0) DisableSQRcontrols (ctrl); } I protected void disabled DisablesSQRcontrols (Control page) {foreach (page control Ctrl.Controls Ctrl) to change the top like some Want to If ((ctrl is text box) || (ctrl is button) || (ctrl is listbox)) ((universal controlcode ctrl). Competent = false; And if (ctrl.Controls.Count> 0) DisableSQRc...

security - Are passwords on modern Unix/Linux systems still limited to 8 characters? -

It was a matter of years that the Unix password was limited to 8 characters, or if you made the password more time There is no additional difference in 8 characters. Is it still on the most modern Unix / Linux system? If so, the system? Is there an easy way to tell if a given system supports the password so far and if so, then what would be the most effective (if any)? I have done something searching the web on this subject and can not really get anything definite; Whatever came up was from the early days of the 2000s, when I think the 8-character limit was still normal (or enough to adhere to that extent). Password Encryption Function can use MD5 (which can be used by the Magic Liquor prefix) in glibc2 (any modern Linux distribution) Which is then believed to be important, all input letters (see). For a simple test on your system, you can try to do something like this: $ 1 $ @@ $ '; print crypto ("> (which gives on my system) @@ nDzfhV1wWVg @@ nDzf...

c# - ASP.NET HtmlTextArea attributes and newline -

I would like to change some features of HtmlTextArea in a SharePoint web part which is developing in C #. HtmlTextArea is being used as a customized display for some SQL Server 2005 data that I am dragging and I want to change the font, color, etc. and want to do it for read-only. I think there are a few ways, such as HtmlTextArea.Attributes.Add, HtmlTextArea.Attributes.AddAttributes, and HtmlTextArea.Attributes.CssStyle, but I'm not sure how to use it properly, nor how to use them. I know that with just one ASP.NET Textaria control I can use inline CSS, so I am trying to find a way to set inline CSS inside C #. In addition to this, I would like to assist in placement, find a way to add a new line between the controls. I have put all my controls in CreateChildControls, but I do not think how I can control their placement. For example, I have something like this: protected override zero CreateChildControls () {clients = new dropdown list (); Customers.ID = "Customer...

jsf - Does rich:messages tag need to be in an a4j:region? -

I have never used a & lt; Rich: messages & gt; A & lt; Tag in the area of ​​a4j: Area & gt; Tag, sometimes I'm guessing that the message tag should be within the A4j area, but was not able to determine from the richface documents. any idea? Thanks in advance. No, there is no need Ajax area is a major AJAX component. This limiting the portion of the component tree to be processed on the server side after the AJAX request. Processing means call during decoding, validation and model update phase. The most common reasons for using an area are: Avoid repeal of JSF lifecycle processing during the validity of the unnecessary input of the given form for the given Ajax request; Showing an Individual Indicator of an Ajax Status Increasing Performance of Rendering Processing (selfRendered = "true / You can read more about this tag.

ruby on rails - Nested Has Many Through Plugin and Named Scopes -

I have a user model (: name, password, email:), and event model (: name,: etc.) and Interest Model (: Name) [> All Singles & lt;] Then I created two joining tables -> User lists and events; Each has no primary key and only includes user_id / interest_id and event_id / interest_id. [> Plural & lt;] use my model user.rb = & gt; Has_many: users_interests has_many: interests, via = & gt; : Users_interests has_many: events_interests, via = & gt; : Interests have_many: events ,: through = & gt; : Events_interests event.rb = & gt; Has_many: events_interests are_ many: interests, via = & gt; : Events_interests has_many: users_interests ,: through = & gt; : Interests have_many: users ,: through = & gt; : Users_interests interest.rb = & gt; Has_and_belongs_to_many: User has_and_belongs_to_many: events events_interests.rb = & gt; Belongs_to: Interests related: Events users_interests.rb = & gt; Related: For user related: Inter...

android - How to highlight a TextView or LinearLayout when click it? -

मेरे पास एक LinearLayout है जिसमें तीन टेक्स्ट व्यूएं हैं जब TextView पर उपयोगकर्ता क्लिक करता है तो मैं एक TextView या संपूर्ण लेआउट को हाइलाइट करना चाहता हूं। क्या यह ऐसा करने का कोई तरीका है? धन्यवाद। मैं 2 supperpose लेआउट & lt; LinearLayout xmlns: android = "http://schemas.android.com/apk/res/android" एंड्रॉइड: layout_width = "match_parent" एंड्रॉइड: layout_height = "match_parent" एंड्रॉइड : पृष्ठभूमि = "@ रंग / सफेद" & gt; & Lt; LinearLayout Android: आईडी = "@ + आईडी / रूट" एंड्रॉइड: layout_width = "match_parent" एंड्रॉइड: layout_height = "match_parent" एंड्रॉइड: पृष्ठभूमि = "? एंड्रॉइड: एटीआर / चयन करने योग्य आईटम बैकग्राउंड" एंड्रॉइड: क्लिक करने योग्य = "सच" & gt; ... & lt; / LinearLayout & gt; & Lt; / LinearLayout & gt; findViewById (R.id.root) .setOnClickListener (...);

Can I run Ubuntu Enterprise Cloud on Sun sparc servers? -

I want to deploy private cloud using Ubuntu server 9 .10. One-SPR ISO is available My question is that none of the Cloud Packages included in 9 .10 will work on Spark hardware? I know that "Commodity hardware" usually means x86, but there are spark boxes which I have more. SN's hypervisor LDOM can be used on SPARC architecture to run Solaris VMS. As you know, UEC (Ubuntu Enterprise Cloud) comes with Ubuntu Server 910 and Nilgiri 1.6. Along with Eucalyptus, only Xen / KVM is supported and even VMWare ESX to an extent as a Hypervisor. You have to see if Eucalyptus can be configured as LDOM as a hypervisor.

malloc - C: Is there something better than a FIFO Queue implementation for this requirement? -

In one of my programs, there are many clients and each customer has its buffer, in the infinite loop, I check that any The customer has data written on the disk. If this happens, then I do the same and continue. Now, because the customer writes the data that is not really under my control (some computational results), I need a dynamic buffer. So the phonemic code looks like this: // If the data is ready / append (client_id, line) add zero to append (int client_id, char * line) {if (client_id.buffer = = Null) {buffer = (four *) molk (buffers * size (four)); // duplicate line in buffer} else {// redune buffer to non indispensable location and add existing buffer to this line}} or another method is to use a simple What message queue do I add to any existing queue (wire) and then read them, is there some other better way? Maybe I could not fully understand your structure, but my understanding is that a customer will give it to you Id and a four * pass and wants you to wri...

Make a Custom Class Serializable in Objective-c/iPhone? -

How do I serialize my own custom class? I especially want to write it to a file on iPhone, just plist and you class is just a simple example class, just NSStrings and maybe an NSUrl. You would like to apply InitWithCoder to implement: and EncoderCoder: and your custom class with NSKeyedArchiver and NSKeyedUnarchiver Will work. Your initWithCoder: should look like this: - (id) initWithCoder: (NSCoder *) AdCoder {if (Self = [Super Invite]) / / This [ Super Init With Coder: ADCoder], superclass nsciding {astring = [[adcoder decode objectwork: @ "estring"] is to be maintained; Other string = [[Adicoder decode objectForcae: @ "other string"] retained]; } Healthy return; } and encoded code: - (zero) encoded codec: (encoder *) add encoder {// [Super encode codec: encoder] Superclass applies encoding [encoder encoded object: astringe fork: @ "estring"]; [Encoder encoded object: other string fork: @ "other string"]; }

linq to xml how to move one element from one xml to another -

I am facing a problem, I have two XML files. Plugins.xml & lt; SolutionProfile xmlns = "http://schemas.microsoft.com/pag/cab-profile" & gt; & Lt; Module & gt; & Lt; ModuleInfo AssemblyFile = "PluginXXX.dll" /> & Lt; / Module & gt; & Lt; / SolutionProfile & gt; .xml of profiles & lt; SolutionProfile xmlns = "http://schemas.microsoft.com/pag/cab-profile/0.0" & gt; & Lt; Section name = "Services" & gt; & Lt; Module & gt; & Lt; ModuleInfo AssemblyFile = "Module.dll" /> & Lt; / Module & gt; & Lt; / Section & gt; & Lt; Section name = "apps" & gt; & Lt; Dependency & gt; & Lt; Dependency name = "Services" /> & Lt; / Dependencies & gt; & Lt; Module & gt; & Lt; ModuleInfo AssemblyFile = "PluginABC.dll" & gt; & Lt; / Module & gt; & Lt; / Section & gt; ...

sql server - Recurring calculations in SQL 2008 MDX query -

I have an MDX query returns the following tuples: Dim1A, Dim11, Dim21, MeasurelA, Measurell, Measure2l Dim1A, Diml2, Dim22, MeasurelA, Measurel2, Measure22 Dim1A, Diml3, Dim23, MeasurelA, Measurel3, Measure23 Dim1A, Diml4, Dim24, MeasurelA, Measurel4, Measure24 .... .... Dim2A, Dimll, Dim2l, Measure2A, Measurell, Measure2l Dim2A, Diml2, Dim22, Measure2A, Measurel2, Measure22 Dim2A, Diml3, Dim23, Measure2A, Measurel3, Measure23 Dim2A, Diml4, Dim24, Measure2A, Measurel4, Measure24 Measure1A, Measure2A Dim1A, gets repeated for Dim2A and if I measure since a large set of query response time is slower one includes calculation is. My question would be that I stopped to each dim 4 times measurements to calculate the A A? So in the above example, measurement 4A is calculated 4 times and Major 2A also does. Ideally I'd like to be them counted once for each unique dim a : with member [remedy] [Measure1a] AS .... Your calculations .... SELECT ..... Your query

Custom Django Form -

I'm trying to create a custom backend for my system and I've hit a little bit of trouble .... The ability to add new users / models / series that are not already in the system through a form. I am wondering how I will go about this ... My models are given below: class creator (model. Model): MANUFACTURER_POPULARITY_CHOICES = (('1', 'Primary' ), ( '2', 'secondary'), ( '3', 'tertiary')) manufacturer = models.CharField (MAX_LENGTH = 15, empty = false) DATE_ADDED = models.DateField () manufacturer_popularity = models.CharField ( MAX_LENGTH = 1, choices = MANUFACTURER_POPULARITY_CHOICES) def __unicode __ (self): return self.manufacturer class model (models.Model): model = models.CharField (MAX_LENGTH = 20, empty = false) manufacturer = models.ForeignKey DATE_ADDED (manufacturer) = Model datefield () def __unicod E __ (self): name = '' + str (self producer) + + "+ str (self. Model) return name category series (models...

c++ - Return a const reference or a copy in a getter function? -

What's better as default , a copy (1) or reference (2) one Cathedral ceremony? square foo {public: std :: string str () {// (1) return str_; } Const std :: string & amp; Str () {// (2) return str_; } Private: std :: string str_; }; I know 2) can be sharp, but (n) is not due to RVO 1) It is safe with dangerous references, but the object is probably alive or never referenced. Is not stored. When you write a class and you do not know (yet) what is the issue of performance and lifelong problems? Additional questions: Does the game change when there is no plain string, but a vector?

go - To use package properly, how to arrange directory, file name, unit test file? -

मेरा स्रोत फाइल ट्री इस तरह है: / src / pkg / foo foo Foo_test.go जाओ अंदर foo.go: पैकेज foo func bar (n int) {...} अंदर foo_test.go: पैकेज foo func testBar (t * testing.T) {बार (10) ...} मेरा प्रश्न हैं: क्या पैकेज का नाम निर्देशिका नाम, स्रोत फ़ाइल नाम से संबंधित है? अगर पैकेज के लिए केवल एक स्रोत फाइल है, तो मुझे इसे निर्देशिका? क्या मुझे एक ही पैकेज में foo.go और foo_test.go रखा जाना चाहिए? foo_test.go में, क्योंकि यह एक ही पैकेज में है foo.go के रूप में, मैंने किया 'आयात फू' नहीं लेकिन जब मैं 6g के साथ foo_test.go संकलित करता हूं, तो यह कहते हैं कि बार () अपरिभाषित है। मुझे क्या करना चाहिए? 1 - भाषा युक्ति निम्नलिखित का कहना है: समान पैकेज नाम साझा करने वाली फ़ाइलों का एक सेट एक पैकेज के कार्यान्वयन के रूप में होता है एक कार्यान्वयन की आवश्यकता हो सकती है कि पैकेज के लिए सभी स्रोत फाइलें एक ही निर्देशिका में निवास करती हैं। ऐसा लगता है कि फाइल / निर्देशिका के नामकरण पर कोई आवश्यकता नहीं है, लेकिन यह डाल करने के लिए सुरक्षित होगा स...

Open word document from ASP.NET application -

I use the following code snippet to open a local doc file and when I press Ctrl + F5 in Visual Studio So walks fine I just click on the button and Word2007 is opened on my machine and there the docox is displayed, but after publishing the application on the production server, it did not work. After clicking on the same button, nothing happened, can anyone tell me why? What do I want to do is open a local stored DOCX from the client side's ASP.NET application in Word 2007. I do not want to use the Office COM object. My code: ProcessStartInfo psi = new ProcessStartInfo (@ "winword.exe", @ "/ test.docx"); Process.Start (psi); Many thanks. Your code is trying to open the word on the server and not the sole reason why it works in the development Does the client and server are on the same machine? You can not open Word on client due to browser security restrictions. However, if you provide a link to the file, then users may be able to download and...

mysql - Quick SQL question! Sort by most occurences of an attribute -

Item ID - Name - Category ID - DCC - Price I want a query that lists the categories sorted by most events in the items table This should do the trick: SELECT c.ID, C.Name, count (i.id) FROM CROM order CID order by group C at the LEFT JOIN item i (c.ID = i.CategoryID) group By counting (id)

cluster computing - Customize WebLogic's heartbeat message -

I am currently developing a system to ensure high performance, availability and scalability; Failure on the weblogic integration scenario- Over and crash recovery Do anyone know whether it is possible to customize the original heartbeat message of Weblogic to add additional information like current CPU usage and / or network load? The objective is to allow the load-balancing algorithms to use "custom" information, which is to avoid overloading a conflicted server with more requests. For my knowledge, this is not possible. First of all, the use of the heartbeat is done by a server installation to advertise its availability - and its availability - (By monitoring heartbeat messages, the server example in the cluster determines that when a server instance fails has gone). Second, weblogic algorithms are not plug-ins and do not use heart rate (at least not straightforward). Therefore, you can use it: Round Robin loads for HTTP requests when using the Proxy plugi...

PHP, get file name without file extension -

I have this PHP code: function ShowFileExtension ($ file path) {preg_match ('/ [^?] * /', $ File path, $ match); $ String = $ matches [0]; $ Pattern = preg_split ('/ ../', $ string, -1, PREG_SPLIT_OFFSET_CAPTURE); If (Count ($ pattern)> 1) {$ filenamepart = $ pattern [count ($ pattern) -1] [0]; Preg_match ('/ [^?] * /', $ Filenamepart, $ matches); Return Stroller ($ matches [0]); }} If I have a file named my.zip , then this function returns .zip . I want to reverse, I want to return the function without my extensions. The file is a string in only one variable. No need for everyone prefix = pathinfo ('/ Www / htdocs / index.html') Example from the manual:); $ Path_parts ['dirname'] echo, "\ n"; Echo $ path_parse ['basename'], "\ n"; Replace $ Path_parts ['Extension'], "\ n"; $ Path_parts ['filename'], "\ n"; // File name is only after PHP 5.2.0 code outp...

sqlanywhere - How to search in sql for hour/minutes? -

I have to search all the rows with a specific row and a filter with minutes. Example: 26/05/2009 - 16:00 26/05/2009 - 17:00 10/11/2009 - 09:00 10/11/11 2009 - 10:00 10/11/2009 - 11:00 10/11/2009 - 12:00 I have all the rows hour / minute "17:00" and "18: 00 "with And the date is optional fields. I do not know how to do this. I am using "SQL anywhere". View from that tab * Select where the datepart (hour, (17,18) and datepart (minutes, datemall) = 0 and datepart (second, datmall) = 0

How to set height , width to image using jquery -

Is there a way to set the height and width of the image using jquery? The following is my code var img = new image (); // image ($ img) .load (function () {imgdiv.append (this);}) Error (function () {$ ('# adsloder'). Remove ();}). Attr ({id: val.ADV_ID, src: val.ADV_SRC, title: val.ADV_TITLE, alt: val.ADV_ALT}); Thanks. You can call the senders, and: var img = New image (); // image ($ img) .load (function () {imgdiv.append (this);}) Error (function () {$ ('# adsloder'). Remove ();}). Attr ({id: val.ADV_ID, src: val.ADV_SRC, title: val.ADV_TITLE, alt: val.ADV_ALT}) height (100). Wide (100);

c# - Need help in BAL Class logic -

In my sales expansion software I want to calculate the TotalCost, discount, Nettolkast. Once recorded rate diplomacy and text box, all values ​​should be filled automatically is my program is capable of showing Kulkast and Netotikl but showing no discount value, it is always just show 0. Here is my code, any person modifies what is wrong in it .... public class salesTenity {private string custid; Private string custname; Private string product name; Private Ent Quantity; Private float rate; Private Float Total; Personal float discount; Private Names NetTotal; Public string CUSTOMERID {back {custid; } Set {custid = value; }} Public string CUSTOMERNAME {get {return custname; } Set {custname = value; }} Public string PRODUCTNAME {get {return productname; } Set {productname = value; }} Public int QUANTITY {Get the return amount; } Set {quantity = value; }} Public float rate (or rate of {return;} Get set {rate = value;}} public float of ({total return};} set {total = value;;}} public...

jquery - How can i FADE IN and OUT a list that appears (using the .bind command? -

This is the code I am using to display a list on the title of the list on mousenter The thing is that it appears and disappears very suddenly, what can I do to make it smoother? Many thanks for your time! & lt; Script type = "text / javascript" & gt; Var timeout = 0; Win cell = 0; Var ddmenuitem = 0; Function jsddm_open () {jsddm_canceltimer (); Jsddm_close (); Ddmenuitem = $ (this) .find ('ul'). CSS ('visibility', 'view');} function jsddm_close () {if (ddmenuitem) ddmenuitem.css ('visibility', 'hidden')}} function Jsddm_timer () {closetimer = window.setTimeout (jsddm_close, timeout) ;} Function jsddm_canceltimer () {if (colitimer) {window.clearTimeout (collater); Bind ('MouseSent', JSDMOpen) $ ('# JSDM & gt; Li'). Bind ('Mouseleave', jsddm_timer)}); Document.onclick = jsddm_close; & Lt; / Script & gt; Your two rows that set the visibility: Ddmenuitem = $ (this) .find ('u...

C# service location -

I have a service in C #, it uses a config.xml file for configuration. I want to display XML along with the executive service. But I can not seem to understand that where the location of the service extends at the runtime can be obtained, so that I can get / load the config. Please help. Another way is, if you are aware of one type in the entry assembly, then use it to get the reference. Assembly: typeof (program). Assembly. Location If you just need a path path, use the static method. Turn off topic: Have you built in .NET? I am not saying that it would be better in your specific case, but I think it is advisable to think before rolling up my own configuration structure.

java - Modifying a jar file -

I have a jar file that is used as an applet in an html file. I modify the content of the jar file Do and want to rebuild the jar file so that the HTML works well with the new jar file. How can i do this I had already tried to modify the source and make a new jar by using 7zip nad. But when I use it in html it shows some java.lang.Classnotfound error You can reject or rejar sections and source files you like. unjar jar -xvf abc.jar jar jar cf abc. Jar input-files

javascript - Draggable nested inside Draggable drags both when dragging child in IE -

I am applying a sit-up using jQuery. There are tables with chairs around me, which can be sitting on chairs, guests have a wrapper div in each table that is dragable. The chair inside the table is the number of devils. A guest can be sitting inside any chair. The guest is also a diva located inside the chair devel. Here is a sample for the markup of such a table. This table has 8 cheeses with two guests sitting in the first two chairs. draggable "> gt; div class =" seating-table-name "& gt; table 1 & lt; / div & gt; & lt; / div & gt; & lt; div id = "chair-1-0" class = "chair chair-pos-0 table-chair-1" & gt; & lt ; Div title = "Elaine Benis" id = "guest-2-5-2" class = "guest guest-2 UI-draggable" & gt; & lt; / div & gt; & lt; / div & gt; Lt; div id = "chair-1-1" class = "chair chair-pos-1 table-chair-1" & gt; div title = "Elaine Beni...

xcode - Problems accessing rootviewController of navcontroller iphone -

I'm closing the seismic XML iPhone instance. In that example, there are just such application representatives who are the Root WEEK controller type UITableViewController. I wanted to modify it a little bit so that I have a navigation controller and can use it as its root interpreter table view. My navigation name of my root view controller class to the controller has been named "firstLevelViewController" Sample code says it [rootViewController.tableView reloadData]; I say [navController.firstLevelViewController.tableView reloadData] say, but I am getting an error saying something " some members' request for firstLevelViewController not a structure or union " how can I find the main app reference Rutwukantrolr navigation controller delegate? There is no property in a first levelview controller a UINavigationController . Want to use Yntrk you can use UITableViewController * firstLevelViewController = navController.topViewControll...

php - Creating a session for current visitor to edit or delete blog comments -

मेरा ब्लॉग PHP और MySQL का उपयोग करता है। मैं उपयोगकर्ता को एक फीचर को संपादित करने और हटाने के लिए देना चाहता हूं टिप्पणियाँ जब वे साइट पर हैं वे उपयोगकर्ताओं में लॉग इन नहीं हैं ऐसा करने के लिए, मैं इसके बारे में कैसे जा सकता हूं? सत्र को समाप्त होने के बाद साइट को छोड़ने पर वे इसे संपादित या हटाने में समर्थ नहीं होंगे। सत्र समाप्त हो जाएगा जब उपयोगकर्ता अपने ब्राउज़र को बंद कर देगा या साइट पर निष्क्रियता की एक निश्चित अवधि (आमतौर पर 15 या 20 मिनट) के बाद यदि आप चाहते हैं कि उपयोगकर्ता को अपनी टिप्पणियों को संपादित करने के लिए और अधिक समय मिलता है तो मैं कुकी का उपयोग करूँगा। एक कुकी बनाने के बारे में और कुकीज़ कैसे पढ़ें।

Drupal timeout - how to amend timeout length? -

I am looking to create a custom module that hooks into the Drupal timeout process. A quick ping is required to fire on another server when a user bar outside - so that they are logged out of the system on other servers. It's a matter ... I'm not getting any documents about how Drupal manages it from time to time. What I can find is all related to PHP.ini. Will it surprise me that it is possible to fire an event from time to time? in / sites / default / settings.php change ini_set ('Session.cookie_lifetime', 2000000); 2000000 seconds is 23 days which is actually stupid default timeout, you can change something: 3600 (1 hour) 10800 (3 Hours) 86400 (1 day)

Execute SqlPS Scripts from Asp.net -

I would like to execute sqlps scripts from asp.net, with this I was able to run ordinary powerless commendens, but how to present SQLs Do not know, it does not. Thank you, Fahad To understand it properly, add SQL Server snapns to Runspace Was and it worked RS Space ArnsSpace Configuration.ADSPNAPIN ("SQLScMCMDLetNetNet 100", OBG Out); Raspace.Ronspace Configuration.adowsnap in ("SKLSprownoverover 100", OBG out);

java - What is a JSP tag? -

I am coming from a .NET background and am trying to learn Java. I'm looking for references to tags and tag handlers, etc. Is there a similar .net build? Yes & lt;% ...% & gt; The tag that you get for the jsp tag is similar to the tag handler RUNAT = "SERVER" attribute, you can add it to many HTML tags, except they go a lot and you Allow to create custom tags according to your needs. For example, you can create a tag named "DATETIMEHERE" when it only returns the date / time. Example & lt; Span class = "SomsCSSClass" & gt; & Lt; DATETIMEHERE / & gt; & Lt; / Span & gt; You can create custom widgets in ASP.NET MVC and do some very easily as tag handlers.

Can you call a .NET 2.0 COM object from an ASP.NET 1.1 web app? -

हमारे पास एक asp.net 1.1 वेब अनुप्रयोग है। यह एक C ++ COM ऑब्जेक्ट को आमंत्रित करता है जो बदले में एक .NET COM ऑब्जेक्ट को आमंत्रित करता है। मूल रूप से, यह .NET COM ऑब्जेक्ट एक .नेट 1.1 असेंबली थी। अब, हमें इस .NET COM ऑब्जेक्ट को संशोधित करने की आवश्यकता है और इस प्रक्रिया में अब हम विजुअल स्टूडियो 2008 का इस्तेमाल करते हैं, इसलिए यह अब एक .NET 2.0 COM ऑब्जेक्ट है। अब हम पाते हैं कि हमारे एएसपी.नेट 1.1 वेब अनुप्रयोग अभी भी सी ++ COM ऑब्जेक्ट को खोल सकता है, लेकिन सी ++ COM ऑब्जेक्ट नए .नेट 2.0 कॉम ऑब्जेक्ट पर कॉक्रेएट इंस्टेंस () को कॉल करने में असमर्थ है। जब हम .NET 2.0 फ्रेमवर्क का उपयोग करने के लिए वेब ऐप को कॉन्फ़िगर करते हैं, तो C ++ COM ऑब्जेक्ट .NET 2.0 COM ऑब्जेक्ट का उपयोग कर सकते हैं, लेकिन ऐसा करने से वेब ऐप टूट जाता है। फिलहाल, मैं इस पर योजना बना रहा हूं Visual Studio .NET 2003 का उपयोग कर .NET COM ऑब्जेक्ट को rebulding इसलिए मैं इसे एक .नेट 1.1 विधानसभा बना सकते हैं। लेकिन मैं ऐसा नहीं कर सकता यदि संभव हो तो मुझे पता है कि हमें अपने वेब एप को भी एनएटी 2.0 में भी अप...

multithreading - Manually Timing out a C# Thread -

I need to add time end to a long running thread. We have some external problems, which can sometimes hang that thread indefinitely on a certain line of code, to strengthen our process, we want to find out that the thread is now actively running / Is not voting and abrogating the thread. With this we need to clean up the resources and restart the thread. What would be the preferred way of adding this functionality? You need two things: Some other threads Monitoring and abbertext (your "monitor" thread) To see if the suspicious thread is still working In your simpler version Suspicious thread updates a shared static variable that is present with a reliable frequency with the current time. How it fits into the control flow of your thread depends on you (this is the hard part - you will usually do this, important, another thread) then just wake up a second thread and check it every time if this is recent If there is no time, then cancel the thread. // Suspec...

windows - where to store .properties file for use in c++ dll -

I have created a .properties file that contains some simple key = value pairs. Attempted to exit a sample C ++ console application using imported Java classes, and I was able to access it, no problem Now, I am trying to use it in C ++ with DLL, which is being called by another (unmanaged) C ++ project. For some reason, the file is not being used. Maybe my file location is incorrect TIA As you are mentioning "DLL", I think you are using MS Windows. Finding a file from a DLL, and logged by the user is independently restricted items. The best way is to store the file in the path that is collected from the environmental variable ALLUSERSPROFILE , this is the only place that is equal to all users and where all users are usually used to write. Your application data should remain in the private subdirectory, such as & lt; MyCompany> or & lt; MyApplicationsName> Type% ALLUSERSPROFILE% at the Windows Command-Line prompt to know the actual locati...

javascript - Help with JS and functions parameters -

Does JS support two functions with the same name and different parameters? (a, b) {// A and B numbers are} function F1 (A, B, C) {// A is string / / b and c numbers} Do I have any problems for IE7, FF, Opera? Javascript does not help you will call method overloading in other languages, But there are more than one action, such as to use objects, to see how many arguments have been applied to the function: function f1 (A, b, c) {if (Arguments.length == 2) {// f1 has been called with two arguments} and if (arguments.length == 3) {// f1 is called with three arguments}} Additionally you can You can type the logic, the number and string primitives for the typeof operator is safe to use: function F1 (A, B, C) {If (typef A == 'number' & amp; amp; typeof b == 'number') {// a and b are numbers} otherwise (if type = A 'string' & amp; ; Amp; amp; type; b == 'number' & amp; amp; amp; amp; amp; amp; amp; amp; type; {// A is a s...

What is the equivalent of php's print_r() in python? -

Or there is a better way to quickly output content of an array (multidimensional or not). Thank you. Python statement does a good job of formatting multidimesion arrays without the need to be available in php. According to the definition of print, each object is converted into a string, and printed as' simple 'by' '' by '' 'object values' by comma-linked list It will work for it, no depth and size of arrays. For example & gt; & Gt; & Gt; X = [[1,2,3], [4,5,6]] gt; & Gt; & Gt; Print X [[1, 2, 3], [4, 5, 6]] If you need more advanced formatting than this, probably the answer to that probably might be the answer is.

windows - Installing DirectX with application MSI - VS2008 -

The application supports Windows XP, Vista, and Windows 7, but requires DirectX libraries to work properly is. I have a DirectX 9.0C reassigned package and have to be created in my MSI Installer with the Visual Studio 2008 Setup project. Two-dimensional question: How do I include a DirectX 9.0C package in my MSI? Will DirectX 9.0 C package ignore Vista and Windows 7 automatically? Do not include it in your MSI package but as a custom action or by installation Perform first. Installing it in Vista or Win7 will not be a problem.

How to select a subset of a table with Excel VBA in the manner of SELECT -> FROM -> WHERE -

Sorry this is a classic newbie question, but I can not find any concrete answer. I'm completely new to Excel VBA and for programming in general. What I am trying to do is to select a subset of data from a large Excel sheet that is almost in this format: name data a data two data N --------- --- ---------------------------------------- The person is a xxx person xxx person One xxx person will be a new sheet to dry for every few days, but I do not know how many people will be listed on it or how many entries are there. Each person. My last goal (for now ...) is to take all the data for the person and copy a new sheet (in the same workbook) to a person, copy all the data For the person two, for a new sheet named person two, and so on. If my basic understanding of SQL is correct then I would be able to use the command in the form. Data from the selection table where person = person one However, I'm not looking for an easy way to do this in Excel. I can see that there ...

c# - Convert String to Date in .NET if my incoming date format is in YYYYMMDD -

What is the best way to convert from string to c # if my incoming date format YYYYMMDD Ex: 20001106 date time Use ParseExact () Something like this: string date = "20100102"; Datetime DateTime = Datetime Purse Axact (date, "YYMMMD", culture info. Inventive culture);

javascript - asp.net mvc: difference between dropdown & textbox onchange event -

If there is some pain with this incident, I have some code for the dropdown: Return Assistant Dropdown list (Data.model EntityID.To String (), Selection List, "& lt; Select & gt;", New {onChange = onChange}); Where there is a variable with the JavaScript function running onChange, it works great. However, the replacement ad with the text box version (below) is removed when the page loads (unlike dropdown list, different behaviors are upset). When the JavaScript function is called when the page is loading, I get an error: Javascript could not be found "undefined" ... (it works later) Return Helper Textbox (data.modelty.modeltext.toString (), data. Value text, new {onchange = onChange}); example JavaScript function utility check (provider ID, check ID, parent ID) {warning ("map") ; // is still still to test the error}; Should I use a text effect for a different event, or something special "What should I do? & ...

In Scala, is there a way to take convert two lists into a Map? -

I have two lists, one list [a] and list [B] ] . What I need is map [A, B] , but if I need the terminology of zip then it started: var tuplesOfAB = ListOfA zip listoff B Now I'm not sure how a map from my tuplesOfAB to a follow up As a question, I also want to overturn my map so that I map [B, A] with a map [A, B] . 2.8 Has anyone left me? What should be the type of result of the compiler to actually use CanBuildFrom functionality and using a type directive with the breakout : will also do the following: val n: map [A, B] = ( List a zip list B) (breakout) and (as predicted, below, as mentioned) toMap val O = (listA zip listB) .toMap has been added to the library as You can: val r = m.map (_ swap) (breakout): map [b, a]

.net - Linq statement to iterate through a collection and making sure each item is in the correct order? -

मुझे एक सरल IEnumerable & lt; foo & gt; Foos; यह संग्रह डीबी कॉल के कुछ परिणाम हैं। मुझे यह सुनिश्चित करना है कि सूची में प्रत्येक वस्तु का सही ढंग से आदेश दिया गया है डीबी या तो रिटर्न देता है id द्वारा क्रमबद्ध, सबसे कम से उच्चतम जैसे। 1, 2, 3, 4 ,. ... आदि बनाये गये दिनांक से आदेश दिया, कमी (सबसे हाल ही में, पहले)। क्या यह त्वरित linq कथन के साथ किया जा सकता है .. यह? उदा। आशंका.आईएसटीआरयू (.. यहां लिंक्स का कथन सम्मिलित है ..) वर्तमान में, मुझे पाशन के लिए मिला है और पिछली प्रविष्टि को याद रखना और जांचना है कि यदि उस का मान है, तो वहाँ एक मूल्य था। यह महसूस होता है ... बोझिल। कोई भी विचार? आप अपने तुलना कर सकते हैं संग्रहित संस्करण के लिए संग्रह: संग्रहअसर्ट। ऐरेक्वॉल (foos.ToList (), foos.OrderBy (f = & gt; f.Id)); या: कलेक्शन एसेट। ऐरेक्वॉल (foos.ToList (), foos.OrderByDescending (f = & gt; f.DateCreated));

hibernate - Can a @OneToOne relationship contain a @ForiegnKey annotation -

Does it make sense that @OneToOne member joins @forganjeanotation? @ Entitie class user {@Id @ generatedValue (strategy = IDENTITY) int id; @OneToOne @ForeignKey @JoinColumn (name = "home_address_id", referenced column name = "id") address home page; } @ Entity Class Address {@Id @ generatedValue (strategy = IDENTITY) int id; } " I do not think it is necessary because the mapping is viable to make a foreigner The key for the column On the other hand, if you think that it will help you and other developers to understand the code easier and there is no problem with it, you can leave it there. However, it seems that the foreking annotation is exclusively a hybrancet where the endowment annotation is part of the Java Atitissance API. It can support the idea of ​​taking it

php - why are some frameworks slow? -

Why are some frameworks slow? For example, how do the Zend Framework codes get slower than the ignition? If you do not use many classes, then just choose the classes of your needs, then it should not slow down? Are you forced to use too many classes with the Zend Framework or are they already loaded too many classes automatically? It depends on how much speed they take when writing the code, the CodeIgniter of the structure is written Astonishing always keeping pace with speed Apart from this, a lot of crazy and bolts are automatically filled up to slow down the structure of the larger framework. However, if you are experiencing any of these frameworks, you can speed up the framework in a good deal by filtering the materials needed for your current project.

testing - What kind of rules for segmentation we can use in latin languages for writing test cases? -

We need to write test case for partition based logic for Latin-based languages. W. R.T. I have found many sites, for the DOC's rules of the rules of division, related to that I got a link but we do not want to use it. Now we are looking for more relevant partition rules that can support all Latin languages ​​and after all the split split options such as the controversy mark, full stop, comma and other symbols used for Latin-language languages, those split rules Can be tested using? Thanks to anticipation, Manjushree Most of the normalized partition rules for Latin language Good source is Unicode standard Annex that is related to text segmentation: See this agreement in particular.

asp.net mvc - Do swfupload have any issues with authentication? -

क्या swfupload में asp.net mvc में प्रमाणीकरण के साथ कोई समस्या है? हां, लेकिन एक वैकल्पिक हल है:

forms - Rails - Should an object's types be in its own model? -

I have a contact, and the contact is near: Phone column has given a column name, phone_desk where I have to include the type of phone number saved by that user. My questions / best practices The options I provided manually (such as "mobile", "work", "home") Should provide a selection with ... -or - ... create new model name phones_types where I want them to add value, thus each one To create a unique ID, I can call phone_test_id by calling phone_desk, call and add phone: phone_types and phone_types Give the name of a name column: @phone = phone.Previously @ phone.type.name SidNote I am currently doing this with the first option (not a separate model) and when there are problems choosing this value, I go to edit the original item. In other words, edit the phone numbers. While selecting, the selected options do not have saved values ​​ This is always the first option selected, so users The phone can change DCC without knowing it ina...

excel - .NET - A way to add my own clipboard format to existing formats -

I have an Excel addin that shows some structure on the worksheet. Users can copy the formations and paste them into another worksheet or another application that is controlled by clipboard formats. When a user copies the structure, then I convert the structure to a specific format and keep it on the clipboard using DataObject :: SetData (). Please note that when the copy is started in Excel, it will put several formats on the clipboard (see image). The problem is that there is a third party application that depends on the data on the clipboard (copy from Excel and paste it into this third party app) but the funny thing is that I am not sure how this format depends. . I need to preserve the existing formats that Excel has placed there and also add its own format for it. Currently when I use the clipboard class in .NET (which takes DataObject and the set data inside it), all the other formats are replaced by new ones, then I create a new data object Tried, copy the current form dat...

MSBuild and TeamBuild - how to get post build files into BinariesRoot? -

I wonder how the following task can be solved: I have additional files afterCompile In the target, an MSBuild file post build files should be copied somewhere, so that they can be brought to binary, then automatically do a RUI on TFS. The post build files call obj / release / some.dll, so it's something to do. Dll must have been compiled after, but before the files are copied to the output directory binary rows. Can I add "CopyFilesToOutputDirectory" to them anyway? Any thoughts? Thank you, Marco I found out that $ (Binary Route) A CSPR is available during construction. So I copy my extra binaries to csproj AfterCompile target: & Lt; / ItemGroup & gt; & Lt; Copy SourceFiles = "@ (FilesToCopy)" DestinationFolder = "$ (BinariesRoot)" condition = "'$ (BinariesRoot)'! = ''" / / Gt;

Is MySQL's trigger concurrent? -

Can two triggers occur at the same time? This depends primarily on the type of operation you are running. If any type of table will prevent your second query from lock performance, its trigger will also be delayed - thus preventing concurrency.

sql - MySQL Filter results -

I have a SQL table that has been called actions: + - - - + -------- + ------ + --------- + | ID | Action | Type | User_id | + ---- + -------- + ------ + --------- + | 1 | 5 | 4 | 1 | | 2 | 6 | 4 | 1 | | 3 | 5 | 4 | 2 | | 4 | 0 | 0 | 2 | | 5 | 0 | 1 | 2 | + ---- + -------- + ------ + --------- + And I like the user table Therefore: + ---- + ------------ + ------------------ - --------------- + ---------- + | ID | Full name Password | Username + ---- + ------------ + ------------------------------- --- + ---------- + | 1 | Admin user | Xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx | | Administrator | | 2 | Arthur | Xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx | | Arthur | | 3 | John | Xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx | | John | + ---- + ------------ + ------------------------------- --- + ---------- + I want to select all the tasks from the action table except the operation of the Administrator, I have tried to: Select from * works where user_id! = 1; But this does not work in some instance...

.htaccess - htaccess rewriterule question -

पुनर्लेखन नियम ^ ([az] {2} /) {0,1} showcategory / ([0- 9 ] *) / [Az \ -_ 0-9 \ +] * / mp / (। *) (/ {0,1}) $ /main.php?id=$2&il[lang]=$1&$3 [एल] रीव्रेट नियम ^ ([एज़] {2} /) {0,1} शोकेबेट / ([0- 9] *) / [एज़ \ -_ 0- 9 \ +] * / (। *) / एमपी / ( । *) (/ {0,1}) $ /main.php?id=$2&il[lang]=$1&page=$3&$4 [L] रीव्रेट नियम ^ ([एज़] {2} /) {0,1} शोकेबेट / ([0- 9] *) (/ {0,1}) / [az \ -_ 0-9 \ +] * $ /main.php?id=$2&il[lang] = $ 1 [एल] रीव्रेट राउल ^ ([एज़] {2} /) {0,1} शोकेबेट / ([0- 9] *) / [एज़ \ -_ 0-9 \ +] * / ([0- 9] *) (/ {0,1}) $ /main.php?id=$2&il[lang]=$1&page=$3 [एल] रीरमिट नियम ^ ([एज़] {2} /) {0,1 } Showcategory $ / main.php?id=0&il[lang]=$1 [एल] मैं इन पंक्तियों का उपयोग करता हूं और localhost / show_category / ठीक है , localhost / showcategory / 0/1 ठीक है, localhost / showcategory / 0/2 पहले पृष्ठ पर रहता है ... (वही 0/1) अच्छा नहीं है समस्या? जब मैं 3 और 4 से इस / [az \ -_ 0-9 \ +] * को हटा देता हूं, तो यह ठीक है, ख Ut तो इ...

java - Spring ContextLoader fails to find applicationContext.xml -

I have been working alone on a project and now another developer has joined so that I can install the project We wanted to use SVN on our machine with very similar set-ups: OS X Snow Leopard Latest Eclipse WTP m2eclipse Maven plugin Subvoscript SVN plugin Tomack 6.0.24 The spring version used is 2.5.6. I have set up a project on my machine, which is used by Eclipse's "Project in SVN" tool, originally to make a 1: 1 copy of the project. Maven took care of all the dependencies without problems, as far as I can tell that the compiled project project without problem, with the resources in the source / web / resources resources, such as the webpage for application (eg applicationContext.xml), the Maven standard, src / The project code in main / java and all web-app related files in src / main / webapp and src is following / main / webapp / WEB-INF respectively. The Web XML is configured to load the context in this way: & lt; Context-param & gt;...

c# - Anonymous methods with return type in .Net -

This is really a question for my curiosity because I know there are other ways of working around the problem. There is a property on my "item" class- "mipartatite" - which I want to evaluate through the collection I want to repeat - "My item collection" - and if there is an "item" square The property which is not "MyProperty" is nothing, I have to set a Boolean flag to inform that any of the collection includes a non-faucet microprocessor, its "item" objects. Pure ContainsPF = Function () (MyItemCollectionImage.MyPropertyInot Nothing Selection Item as Item From This ITEM). Count & gt; 0 This gives me the warning of "no convertible expression", as in 'section; Object type is assumed ', so I tried Boolean = function as private content (POF) (MyItemCollection as item from this item where item. MyProperty IsNot is nothing Select items). Count & gt; 0 subc). Mount & gt; 0 Although thi...

javascript - Post to entire document like a form using jquery? -

I wan't to pass a variable without obtaining php, therefore, I use the post with jquery I'm doing, but I can not write the result in the document (refresh all the pages) Here's the code: $ Attr ("href"), {returnto: $ (this) .attr ("rel")}, function (a) {$ (document) .html (a);} ); Return false;}); The document is not a place to write your result in the form of your meta envelope Use the body rather than the HTML page: $ ("body"). Html ("My answer is:" + a);

c - Is there rule of thumb for catching errors in Lex/Yacc parsing? -

Should we parse the language of general purpose as quickly as possible (in Lex) or where it is more convenient and we Give more information (YACCP)? How do different languages ​​solve this problem? More complex error in general, code to emphasize more complex error Lexers and parsons are quite simple (in practice), and therefore ordinary errors are ripe. Li> Ol> Complex errors are usually on various translations at runtime or elsewhere in compiled time. Examples might include reference to a function / method that does not exist. Tons of closed scope / binding, object and reference identifiers, logic validity, overloading, and many other language dependent materials. Anything beyond that very narrow token / syntax scope should be carried out (or handled) in those AST analyzes or intermediate code generation. Consider: ab (); Now (); Both should make it for the object-oriented language via lexer / parser, where both statements are ...

How to strip domain name out of a url in PHP? -

parse_url ($ url, PHP_URL_HOST) उपर्युक्त के लिए काम करेगा : sub1.domain.name , sub2.domain.name , ... मैं केवल डोमेन नाम पट्टी करना चाहता हूं। इसलिए जो आप से शुरू कर रहे हैं वह यूआरएल नहीं है। सबसे आसान तरीका यह है कि यह यूआरएल की तरह दिखता है: function get_host_from_bad_url ($ url) {if (! $ Candidate_host = parse_url ($ url, PHP_URL_HOST)) {// जानबूझकर असाइनमेंट $ candidate_host = parse_url ('http: //'। $ Url, PHP_URL_HOST); } वापसी $ condidate_host; } सभी प्रकार की अन्य चीजें हैं जो हो सकता है में मेजबान नाम होता है - लेकिन बहुत अधिक जानकारी के बिना इसकी व्याख्या करना कठिन है। हालांकि एक वैकल्पिक दृष्टिकोण कुछ भी निकालने का प्रयास करने के लिए होगा, जैसा दिखता है कि यह एक होस्टनाम हो सकता है (और उसके बाद संभावित रूप से, DNS जांच कर सकते हैं): function strip_hosts_from_string $ Inp) {$ inp = strtolower ($ inp); $ से मेल खाता है = preg_match_all ( '/ ([एक-Z0-9 \ -] \) {2,} ([a-z] {2,6}) /।', $ Inp); $ होस्ट नामों = $ मैचों [0]; विदेश...

extend Python namedtuple with many @properties? -

How many nicknames can be extended with additional @products? For some, any text can write down; But there are many, so I am looking for a generator or property factory. One way is to generate text from _fields and exec exec; There will be one add_fields with the same effect on another runtime. (My @props have to get rows and fields in the scattered database in several tables, so that rec.pname is context [Rec.personid] .pname ; But there are other uses in nametuples-with-smart-fields.) Expand to designate with multiple @ properties? "" ("Person", "PNN peder") # ... tolerant = [person ("Smith", "NY"), person ("Jones", "IL")] class top (nominated ("top_ "," Topping amount was in vain ")):" Property "- family - for the continuous [person] .pname - & gt; Individual pad ..." "" __ slots_ = () @ property DP person (self ): Return [self.personid] with the same ...

php - Dead.letter email. Same domain name, different mail server -

I have a server setup "myserver.com" and I try to send an email to this from a PHP / Apache application I am the server. The host name is set to "myserver.com" and I can send emails to anyone outside myserver.com domain. We are using a different server / service and the problem is when I try to send emails to anyone on the Myserver.com domain they do not receive email. This also happens when I try to send through the command line, I have saved messages in: dead.letter ... / home / username / dead.letter It seems that the MX record is being ignored ... how can I honor this MX record? Thank you. How can I honor this MX record? By setting the proper hostname and if the server in question does not provide every service for myserver.com, then it must use subdomain.

css - How can I get an embedded video to float left in IE7? -

How do I get embedded video to float left in IE7? The following code works great in Firefox and wraps the text around the divisor and the video, but sits under the text div / video in IE 7. & lt; Object height = "264" width = "320" style = "float: left; margin: 5px;" & Gt; Ultimate name = "wmode" value = "transparent" & gt; Ultimate name = "Allow full screen" value = "true" /> gt; & Lt; Embed type = "application / x-shockwave-flash" src = "http://somevideo.com/" Allow FullScreen = "true" allowScriptAccess = "always" height = "264" wmode = "transparent" width = "320 "& Gt; & Lt; / Embed & gt; & Lt; / Object & gt; & Lt; P & gt; Advertisements can be used for advertisement or crop for any type of advertisement. Any is not willing to sell to sell Donik Orner Insentmatm Srs Ijet Fringilla brochures a...

sql - Is there a downside to adding numerous indexes to tables? -

I am creating a new DB and wondering if there is any negativity to adding many indexes to tables that I think That's one If I am creating an index but not using it, will it be the cause of any issue? Indexes it faster in the search table, but for longer writing. Due to unused indexes, due to some unnecessary slowing will come.

javascript - Read xml file, modify the values/add elements/attributes and save the xml how? -

By using javascript, I want to read XML file from disk, modify values ​​/ add elements / attributes and XML back Save on Disk Anyone here knows what can I find examples that work with IE and Firefox? I already look for examples to read, which is now changing the problem. Thanks Assume that you try to read and write discs from the browser And node.Jes, the first step is to use a input tag file to use the file system. & lt ;! DOCTYPE html & gt; & Lt; Top & gt; & Lt; Meta charset = "UTF-8" & gt; & Lt; / Head & gt; & Lt; Body & gt; & Lt; Input type = "file" id = "input" accept = "text / xml" & gt; & Lt; Script src = "script.js" & gt; & Lt; / Script & gt; & Lt; / Body & gt; As soon as a file is selected, we want to remove the body from the element. To do this, a good moment change occurs during the event. const input = document.query selector (...

cocoa - How to create a subscript with NSAttributedString -

I'm looking for NSAttributedString is a special feature for the superscript, but I can not find any subscript for a subscript What is the general practice to use NSAttributedString to create characters? Example: H2O

javascript - CSS/HTML Print Background Images/Styles without Browser Page setup tweaking -

Is there any way to print, when a user prints the page? & lt; Div id = "test" style = "background: # 000000; color: #fffff" & gt; Black Strip & lt; / Div & gt; I'm trying to create a page with line striping in the printout as it appears on the screen. When they go to print, it definitely leaves the background, apart from being told about each user to enable print background in their browser, whether to do so via CSS / HTML or Javascript Can program program be done? No, it is entirely up to browser settings that you do not change with JavaScript or CSS Can.

maven - Full search and replace of strings in source files when copying resources -

I have some Java source files that use the package prefix (they are copying some JDK classes). I use these files with the prefix to run against some unit tests, if I want to produce a jar from the test that contains the source files but all the java files have been removed with the package prefix. I'm using Maven for Builds Does anyone know how to do this? Basically what I want is something like the resource plug-in filtering feature, but it replaces and replaces $ {vars} rather than filtering properly (ex: s / my.package.prefix .// g). You can also use 100 % Maven and are doing exactly what you are doing more

binding - Plugging in jQuery HoverIntent for Sliding Panel -

I have a following code to create a dropdown accordion that shows the hidden div "#top_mailing_hidden" when div The problem is "#top_mailing" Hovered is the problem that when I interrupt the animation and then mousing again it closes the animation and clutches. I have the following code: // Drop down the top mailing list animation $ (document). (Function () ($ ('# top_mailing') .bind ("mousecent", function ($ {"(# top_mailing_hide"), stop (). Slide down ('slow');}) .bind ("mouseleave Slide Up ('Slow');}); }); $ (the "work") has been defined in the Brian Cherane plugin by calling the HoverInant Function ("Mactell" and "MeshShort" # Demo2 li "I think the behavior I'm getting His best solution is to use Brian Chern's "HoverIntent" jQuery plugin. The problem is that I do not know how / where to enter the code above to call the HoverIntent plugin, call it...

c# - Which is more efficient for rendering a server control in ASP.NET -

I am outputting the entire HTML for my server control: public override Zero rendering (HtmlTextWriter output) {output.Write (myStringBuilder.ToString ()); } myStringBuilder is a StringBuilder object that is created manually in a separate personal method. Is this an effective way to do this? Or is it better to pass HtmlTextWriter for my personal method and make several calls to HtmlTextWriter.Write ()? "post-text" itemprop = "text"> is more efficient to pass HtmlTextWriter in its own way, writing it on the output stream It does not, by buffering multiple strings. In fact, this method is the web control in the core. Net framework is at high level, it is going through the same HtmlTextWriter in all very render methods, generally, when reading / writing too much, dealing with a stream is more efficient ... What ultimately you are doing (stream is the Reops Stream in this case) Disclaimer: This is a little customizable unless you are creating s...

Sphinx search engine and related tags -

I am using Spinks search engine for the tags of all my intranet documents. With this I have no problem finding specific documents with one or more tags. I want to go ahead with a new feature like stack overflow "related tags" feature. Does anyone know the best way to do this with spinks? Thank you You run boolean or query on all conditions in that document You want to find related items for. This can be quite slow as all the documents in the database can be given space on parity, unless you can not limit the use and limit of search. See my text here:

qt - Qt4: Scale invariant qgraphicsitem outlines -

I am portraying some polygons using the Qt4 graphics visual framework, and I can see the user's drawing zoom in and out Allow me to I want to make the polygon bigger and smaller because the user changes the zoom level in the view, but does the setting thickness always remain the same? Thank you! Yes I think at least this is likely: you call > Hope this will help! This property allows to keep the width constant regardless of any change applied to the kPinter!

Suggestions for SQL Server GUI? -

I just downloaded the SQL Server 2005 Express Edition. I was hoping that it would come with a GUI so that it helped me to design my table and so on, but it is not so. I am working with ColdFusion / CF Builder here, so I do not really want to be integrated into Visual Studio. Also, if it also has the option to connect to a remote database, then it will be helpful. suggestion? SQL Server Management Studio Express should be installed with your download Was there. If not, you can get it here: Consider using the latest version of SQL Server Express (2008), which can be found here:

C# generics with linq search criteria -

I am trying to create small supportive methods for simple normal tasks but on the sample: public static int getEntityId & lt; Type, unit & gt; (String name) where the body:. Class {type type = _db.gettable & lt; Unit & gt; () SingleOrDefault (t = & gt; t.name == name); Return 0; } I get an error: Error 1 There is no definition of 'name' in 'entity' and no extension method 'name' first accepted The argument of type 'unit' can not be found (do not you remember the usage instructions or an assembly reference?) C: \ work \ asutp_migration \ asutp_migration \ Program.cs 89 62 asutp_migration Actually, this is expected of error, but how to solve it? UPD 1: According to the advice I did this: Public partial square unit: IHasName {} Interface IHasName {string name {get; } Int id {get; }} Public Fixed Integer Entitide & lt; Type, unit & gt; (String name) where unit: class IHasName {type type = _db.getetable & l...

c# - How to disable horizontal scrollbar for table panel in winforms -

Hello, I have a table layout panel and I keep it dynamically binding in control. When the item count is greater than the height of the panel, there is no problem if the vertical scroll bar is clearly visible. But the horizontal scroll bar is also visible at the same time, even the width of the item is less than the width of the panel. How can I stop it? int vertScrollWidth = SystemInformation.VerticalScrollBarWidth; TableLayoutPanel1.padding = new padding (0, 0, VertcrollView, 0);