Posts

Showing posts from August, 2011

Best practices: Where should function comments go in C/C++ code? -

So ... I think it can be subjective, but I have the opinion that what is the best practice for this is . I have the following heading and The CPP file is: Header: // foo.h square foo {public: int bar (int int); }; CPP: // foo.cpp int foo :: bar (in int) {// here some algorithm Which gives revised values} Now to say that I have the comment of this function: / * Input: An algorithm integer as the input of the FU output: The result of algorithm fu on input in the comment: this function p = np * / resolves the function of the CPP file In the header above the declaration or function definition ? Thanks SO I have described the comments in what is in the header and commented How does it in the CPP file.

datetime - time convert in javascript -

जावास्क्रिप्ट में एक को कैसे सेकंड में परिवर्तित किया जाता है? mm: ss.sss? क्या है एसएसएस? आप ऐसा कुछ कर सकते हैं: फ़ंक्शन getSeconds (टाइमस्टैम्प) {var भागों = टाइमस्टैम्प। मैच (/ \ d + / g), मिनट = 60, घंटे = 60 * मिनट, एमएस = 1/1000; वापसी (भागों [0] * घंटे) + (भाग [1] * मिनट) + (+ भाग [2]) + (भाग [3] * एमएस); } GetSeconds ('01: 33: 33.235 '); // 5613.235 सेकंड जब से आपको मिलीसेकंड की आवश्यकता होती है तब से संपादित।

iPhone Toolbar on top of a Scrollview to save UImage? -

Viewing some tutorials on a toolbar that are implemented through all navigation controller reps. Is there any way i can use the toolbar without using the navigation controller? Now I have a view controller with a scrollview in that ScrollView, when I use a touch gesture, I want a toolbar to look viewable and usable like a photo app for the user. I am I want to know how I can use the toolbar and make it functional without leaving an app representative and without being on the current view controller. A toolbar can be created and positioned like any other view. Do not confuse Toolbar with Toolbar

continuous integration - TeamCity vs Team Build -

Which support / opposition is between TeamCity and Team Build and why choose one instead of the other? Interesting questions I am using a lot of systems to build cement. Teamcity Easy to Use Beautiful Easy to Install and Set Up < Li> Easy to increase and optimize builds Easily discover with other systems such as git, svn, jira and many others. Team Foundation Build If you already have TFS set up, then build run is easy Simple Solving matters like making solutions is easy << li> Builds can get a job, but I like team policy.

winforms - pling sound .net application -

I have a pure Winform application that I want to be "idle". Occasionally when the user opens a dialog or a "plating" sound appears. How can I disable it on the global scale for my application? See this previous article: < / Html>

php - Complex SQL Query Help -

A beautiful standard set of related tables like customers, invoices, and line items. Like a query, "Select all customers who have 5 line items or more invoice invoices" or "Select all customers with more invoice than 2 customers" or finally "Select all customers whose line The item should be more than $ 100. " / P> I'm doing it in a difficult way (manually running through all records) and I know that it is in the most inefficient way but I have enough SQL to build these questions. is not. I am using PHP5, MySQL and Cake PHP 1.25. Start by adding them all together: Select CD to switch on Invoice i i.customer_id = c.id. Get Liittings li.invoice_id = i.id group by c.id Line item more than 5 or more To filter more customers, add: counting (li.id) & gt; = 5 Two or more invoice customers are intriguing to filter, because we are joining the line items table, there may be several rows per invoice, then only counting unique invoices

How to convert Sql query with inner join statement to sql query with Where statement(no inner join in statement) -

I have accessed the following SQL query code by using Quebec and it has been converted to SQL. Still, I want proof that I did without help, so I want to take all internal condominiums and want to change them with the WHERE statement. How do I work it out? Please explain and answer. Thanks SQL query:. Select Entertainer.EntertainerID, Entertainer.FirstName, Entertainer.LastName, Booking.CustomerID, Booking.EventDate, BookingDetail.Category, BookingDetail.Duration, Specialty. Specialty Features, Entertainment Feature. Interactive expert (Entertainer Inner Join (Include BookingDetail on Booking Inner Booking BookingID = BookingDetail.BookingID) on Entertainer.InternerID = Booking Dupet.InternerIDID) Inner Joiner (Specialty Inner Joiner Specialty on Specials.pecialistid = Entertainer Specialty. Specialist ID) On Entertainer EntertainmentID = Entertainer Specialty.InternationalWHERE (Entertainer.InternenairID) = [Enter Entertainer ID])); This is the strange zodiac statement tha

php - Facing issue generating pdf using fpdf -

I'm getting http500 for code below, I'm not sure what's wrong I'm new to php. Check that PDF.php is in the correct directory and fonts Just to ensure: Is your path correct? Do make /home/php/File/PDF.php and / home / php / file / pdf / fonts / actually exist? If I download and install the last version of fpdf, I have: /.../fpdf16/fpdf.php and /.../fpdf16 / Font> I have no "file" directory - but I do not have the same installed / version as you To avoid this notice: 'D' / code>, on the code of your last line: notice: undefined continuous de-eclipse 'D' After setting the right pets for my system, and ... then, Wall: Do you have an error, for example log of Apache?

linux - when a process is killed is this information recorded anywhere? -

Question: When a process is killed, this information is recorded anywhere (I.e., > Update - Thank you very much, you have given me some information. If your Linux The kernel is compiled with the Process Accounting option ( CONFIG_BSD_PROCESS_ACT ), then you accto Using the command n (8) , the recording process can begin accounting information and the information entered to access Sa (8) entered information includes 32 bit exit code Which contains the signal number. (These items have not been widely known these days / but I still remember from the days of VAXes of 4.x BSD ..) < / P>

html - Bought web design - table structure or CSS layout? -

I tried a new web designer for one of my projects after several attempts to make it a very good design for my webpage. Created and sent me the files. Now I am very surprised because he only has 20 slides in Photoshop (very badly cut, like limitations with content in an image) and all full 1 table structure HTML file When I asked him to do it in CSS, he said that he can not do it, he does not know that he is only a designer. His reasoning was: Nobody asked for any cut design in his 4,5 years experience, all the customers would have PSD file and piece and HTML in their own right. So, my question: am I old or not? So far, I have ever created a webpage, DIV and CSS, never use the table unless you actually have a table structured information to show. That's what I learn. Please tell me your opinion and how to deal with the real situation. They argued: In their 4,5 years of experience, No one asked for, all customers have only PSD files and pieces and make themselves HT

c# - Sort child objects while selecting the parent using LINQ-to-Entities -

Imagine that you have some entity framework institutions that look like this (obviously these are not specific classes, but Autogenerated entity framework pipeline with everyone; these are for illustration purposes only): Generators of public class {get public ID}; Set; } Public listing & lt; Child & gt; Children {receive; Set; }} Public Class Child {Public Ent ID {get; Set; } Parent Parents {Receive; Set; } Public Integer Number {Received; Set; }} I have a LINQ query that looks like this: In the context of parents. mother-father. Include ("child") guardian However, it gives a list of parents where the child ID is in order I want children to have their parents within their Number to be solved by property How can this be done? Edit: An explanation: The idea is hidden behind a method call (in the layer mask), which is only a IList & LT; Parent & gt; . This is using solutions like unknown class questions and manual sorting painful (compared t

php - jquery ajax get json array? -

I use $ .getJSON to call php file. It takes it back. <$ } echo "{'Result': 'Error', 'Count': '$ nr'}"; To get results, use I just alert (data.result) in jquery How do I get all the nr: s in counting is ? Edit: But how do I array in jquery through array? All the keys are numerical and I do not know about retrieving them. Use a JSON array to convert your PHP array: resonance "{'result': 'error', 'count':" .json_encode ($ nr). "}"; You can also create your own hole response message with PHP types and then convert it to json_encode : $ response = array ('result' = & gt; 'error', 'calculation' => array ()); ($ I = 0; $ i & lt; = 10; $ i ++) {$ response ['calculation'] [] = $ i; } Echo json_encode ($ response);

c# - how to get current URL in SharePoint? -

I am using SharePiont Server 2007 Enterprise with Windows Server 2008 Enterprise, and I am using the Publishing Portal template I am I am using VSTS 2008 + C # + .NET 3.5. I left each item in the left navigation area (in the SharePoint conditions, also called the current navigation area), and the left navigation area maps either a sub-site or a specific URL (i.e., the item in the left navigation area) Content of the specific sub-site welcome page or content of the specific URL in the main content area of ​​the central area) I want to know which URL is displayed on the main content area when the item is clicked in a left navigation area to create any sample reference? Is your app using SharePoint object model?

php - Manual run works, but not cron -

There is a problem with a php script to get the title of a URL, but it works when it runs manually I run it through the cron. function getTitle ($ url) {$ fh = fopen ($ url, "r "); $ Str = fread ($ FH, 7500); Fclose ($ fh); $ Str2 = Stroglager ($ str); $ Start = strpos ($ str2; "title"; title & gt; "+); 7; $ Len = strpos ($ str2, "& lt; / title & gt;") - $ start; Return $ url ($ start == 7); Return substrag ($ str, $ start, $ len); } Then I run down, where I see the URLs in texts, and print the url with the title: $ data = mysql_query ('SELECT * message by message order by DESC limit 100;); While ($ rad = mysql_fetch_array ($ data)) {preg_match_all ($ pattern, $ rad ["text"], $ a); $ Count = count ($ a [1]); ($ Line = 0; $ line; $ count; $ row ++) {echo 'URL:' $ A [1] ["$ row"]. & Lt; BR & gt; '; Echo 'TITLE:'. GetTitle ($ a [1] ["$ row"]) '&

php - getting mysql data for different users -

If I have two users, then a user has many posts in the post table, like postid, And I have another table for friends, for example id, friendly, user-id, franc_syn (i.e. timestamp ) / code> Now I want the user's friend to look at the user's posts after the date on which they user Added as TRI. Not from old to date, he added them as a friend. How do I do this in a single MySQL query? After making this, all the posts of people will be seen by friends 12: < P> >

ruby - Rails, Combine multiple controllers into one interface -

Controller can include editing, creating and deleting users and posts. I will also include removal of comments. I have a user, admin (basically just login / control everything), comments, and posts so far. So how do I add them all to an admin panel? An administrator should be processing each, instead you can put multiple controllers under the administrator namespace, / Post type of URL. However, in this way you have to write all your controllers and see the argument twice - once for the administrator, once for regular users Do not do anything with your choice of controller structure by adding any page to "a panel" Based on the authorization, it is easiest to allow the resources to be edited / deleted. You can just keep the link on the sidebar or at the top of that panel. In this way, instead of being limited to a panel, you can browse the site like a regular user, except that you will see some more buttons and will have the ability to edit / delete thing

licensing - How to license a project -

I wrote a project for the organization of my students, I want to share it among many organizations and I want to They use it for free. So I thought that the release of the project on GPL license (or other silimer). Although I do not want anyone to use this project for commercial purposes free of charge. How should I license this project? Is there a license that is suitable for it? Or should I release two copies of my project on different licenses? You should consult an attorney to get good legal advice. However, it is being said that, GPL is a very common license for this scenario, it does not explicitly prohibit commercial use, but it is necessary that under any GPL distribution Includes full source and complete delivery rights, it is not effectively involved for business use. For commercial purposes, you can easily negotiate distribution under another license, even for a particular company that is specific. My company has publicly distributed under GPL in this manner i

C++ Visual Studio character encoding issues -

Not able to wrap my head around this is a real source of shame ... < P> I am working with a French version of Visual Studio (2008), in a French Windows XP (2008). Insert French accents in the strings sent in the output window, get corrupted Input window to Input. Typical character encoding problem, I enter ANSI, in turn get UTF-8, or something for that effect. Which setting can be left in ANSI when showing the "hardcoded" string in the output window? Edit: Example: Add # & lt; Iostream & gt; Int main () {std :: cout & lt; & Lt; "AEEUUUU" & lt; & Lt; Std :: endl; Return 0; } will show in the output: and oacute; & Uacute; & Ucirc; & Amp; Uml; (encoded here & agrave; & eacute; & ecrac; and ugrave; Before I go ahead, let me tell you what you are doing C / C ++ is not compliant. In states 2.2 which are set in the source code in source code, it is not much there, and all the characters ha

permissions - Showing/Hiding Links in an ASP.Net MVC View -

I am trying to understand how to show / hide the link for a user based on my roles. I know how to set the attribute for an action method, but if the user says, in my database of roles there is an administrator or manager, then I have trouble creating links in a link. Any good article or any example of the code can tell me? In your opinion, you can user System.Web.Mvc. ViewPage 's user via property user for example. In your opinion, you might have something like this: <% if (User.IsInRole ("Admin")) {%> & Lt;% = Html.ActionLink ("admin only link", "edit", "user")%> & Lt;%}% & gt; & Lt;% if (user.isynol ("manager") || user.isynol ("admin")) {%> & Lt;% = Html.ActionLink ("manager and admin only link", "edit", "product")% & gt; & Lt;%}% & gt; HTH, Charles

c# - "Organize imports" in MonoDevelop -

Image
When Java is evolving in Eclipse, then I press Ctrl + Shift to "ID" for the IDE shape Can I suppress O Is there any similar feature in the monodequel for programming C #? EDIT : I am new to C # and entire Microsoft space. If there is no way to do this, then in general it will be decided that in which library are the classes which they were trying to use? You can use it by right-clicking on unfamiliar Type and hover over "solution": If type is identified (i.e., if you were already using gdk; in the example above), you will not see this menu. If you have Ubuntu personnel , the mono develop version in the repository 2.0 . You must add to the upgrade. If you are using Windows or OS X , you can save it from mono develop 2.2 to Download. >

Resetting a datagrid in ExtJs -

I have a button with the task listener in the ExtJs data grid. I have a toolbar with this reset button. I have no form. So what is the code that will reset the data grid on click? I can reset it by clicking the button while refreshing the page, but it will be smoothed to reset it again, since there is no reload in all, except that the user has chosen the settings selected. Will go Many thanks in advance. You can reload the grid's store: Grid.getStore () Reload ();

[iPhone and Web Services]: REST vs SOAP -

I have started a mobile application suitable for my degree project, iPhone, Android and (in the near future) Symbian. Web service (for mobile connections), based on TomCat and Axis2; Web site (for "Standard" users); li> For data of mySQL db storage users Surfing the Web, I have talked a lot about the interaction between the iPhone and the web services, and I do not have a clear idea of ​​what I can and can not do. I begin with the protocol used to obtain data from DB: Android-side application uses SOAP protocols, can I do the same with the iPhone? Are there some limitations or problems? I have also read about using REST instead of SOAP, is it possible with the server architecture described above? What are the main advantages / disadvantages? Sorry if these questions are called "n00b", but this is my first real experience with the iPhone and a lot of information found on the web came to my mind and I was afraid to be confused . Forgive me for an

Is there anything unique for file and folder in windows c#? -

I am working on the files n folder using C # .... I know that the UID for the file There is no way to get it - folders .... So far I was using the full path of the file ... but my problem is changing the name of the file names ... which will replace the UID for the file folder .. Plz is in any way already thanks, First of all, I think that The parties can get clear feedback if you clearly define what you are working on the "files" means. No, there is nothing like "UID" for files or directories, but if you want to dynamically monitor the status of files and directories, and if events are moved / changed / deleted Have informed, etc. You can use the net class. For example, with a dictionary, whose key can be some UID or GUID, or whatever may be, the form dictionary & lt; UID, string & gt;, where string may be the original file name, even if you receive an event from FileSystemWatcher, a second dictionary & lt; UID, string & gt; Update Wher

c# - Anatomy of a Postback -

मैं एक POST विधि द्वारा भेजे गए परम कैसे निर्धारित करूं? अगर मेरे पास बटन है, और वह बटन क्लिक किया जाता है, तो सर्वर को क्या भेजा जाता है? यदि आप अनुरोध की गणना करते हैं.फॉर्म आप POST द्वारा भेजे गए सभी डेटा देखेंगे। सुरक्षित शून्य पृष्ठ_लोड (ऑब्जेक्ट प्रेषक, इवेंटएआरजीएस ई) {फॉरच (अनुरोध में स्ट्रिंग की.फ़ॉर्म। सभी केये) {रिस्पांस। विइट (कुंजी + "::" + अनुरोध। फ़ार्म [कुंजी] + "& lt; br / & gt;"); }} हालांकि, यदि आप एएसपी.नेट सर्वर नियंत्रण का उपयोग कर रहे हैं, तो आपको इस तरह से डेटा तक नहीं पहुंच जाना चाहिए। आपको उस नियंत्रण की प्रासंगिक संपत्ति का उपयोग करना चाहिए उदा। // एक पाठ बॉक्स पाठ बॉक्स 1 के लिए। मूल्य; // एक ड्रॉपडाउन लिस्ट ड्रॉपडाउनलिस्ट 1 के लिए। चयनित इंडेक्स; DropDownList1.SelectedItem; DropDownList1.SelectedValue;

c++ - Compiling a gnu program without sse3 -

I am compiling an app for a device where the architecture does not support sse2 beyond sse2, and thinking Was it possible to disable the compilation with the sse3 instructions from the GNU Autoconf Generated Config Script? I know that you can turn it off in GCC / G ++ with the mno-sse3 option, but it would be nice if I shut it down at the configuration level instead of creating a Mac file and manually inserting that compiler flag Surely just set the required flag before configuring: < Pre> $ CFLAGS = "- mtune i386" .configure --enable-this --disable-that ... You can try - if works wrong So i am It is not tested in goal.

How can I convert hexadecimal to decimal numbers in calc of Emacs? -

How do I change hexadecimal in decimal numbers in amax calc? For example, if I enter FF , then I have to convert it to 255 . Update: How do I get a reverse operation, change base to 10 to base 16? You can enter any number in the format & lt; Base & gt; # & Lt; Number & gt; . Example: 16 #FF is immediately converted into 255 . For reverse, you have to set the output display mode. In this example, d r 16 rt has set the display to the base. Set it to 10 based on Default behavior again. By the way, you can also read the manual TM : .

android command-line -

How can I specify a command-line parameter when I launch an Android application? Itemprop = "text"> You can not run for any application, most of the Android The phone does not have any CLI and the apps are launched by clicking on their icon. You can do this via adb shell , but your user can not do anything It's okay what are you trying to do?

c# - find if dropdown value was added dynamically -

Is a value in a dropdown list dynamically added or is there an initial value? For example. & asp: dropdown list id = "MyDDL" runat = "server" & gt; & Lt; ASP: ListItem & gt; 1 & lt; / ASP: ListItem & gt; & Lt; ASP: ListItem & gt; 2 & lt; / ASP: ListItem & gt; & Lt; ASP: ListItem & gt; 3 & lt; / ASP: ListItem & gt; & Lt; / ASP: DropDownList & gt; // 1 Private Zero AddExtraItemToList (on postback) {If (some conditions) / / Additional items can be inserted MyDDL.Items.Add ("17") or not; } // Private Zero RemoveExtraItemsFromList () {// Remove any non-default values ​​from the // list on postback ...? } It is trivial to codify a list of the basic values ​​behind the code behind it, but if you can assume above which values ​​are the initial properties and the viewstate Were born from restoration The best way to handle this is to keep track of the original values. < P> Here is

Powershell regex question involving balancing parenthesis -

How can I change a table column definition in an array of columns using regex without taking formatting in the account? . How do I break the confusion on "," as they can appear in the Data Type definition part (between matching brackets) Sample Input: Create table test (District VARCHAR (3) character set not Latin CASESPECIFIC, CUSTOMER_ACCOUNT decimal (8.0), CUSTOMER_SUB_ACCOUNT decimal (3,0), SERVICE_SEQ_NUM decimal (7.0), EFFECTIVE_DATE TIMESTAMP (0), SUBSCRIBER_SEQ_NUM decimal (7.0)) Thank you! Friedrich After Traditionally not able to have regular expressions for balanced brackets Testing / matching but many libraries have made extensions which allow some recursion. Like with its "R" quantifiers? And Microsoft has added "" you can find an example of that feature to match (...)

java - junit testing a class with shell scripting functionality under win32 -

We have an API that is used in any class through an interface. The API is for the Unix family and believes that every bin / bin / sh is thus when we run a Junich test under Win32, we get: The program "/ bin / sh" Can be run Is it a catch-22 position or is it a chance to work? There is probably no other structure than junit which can be easily run under UNIX. Thank you. Update: This code is portable and it means that you can run on multiple OS. I want to write some unit tests (which is my own initiative) and some parts of the code open in front of me in the API (being tested in other departments). Now when I run a test for my code, because it relies on the APIS code, it is behind some magic, like calling shell script, which is virgin Win32 (we develop ours using Win32 + ssh) Are not present in Switching to Linux is not currently an option. Eclipse on UNIX + GIE via NX Client may be an option however. Hope this makes it a little clearer. Your question is uncl

c++ - What can you use to cast an int/float to a wchar_t*? -

How do you do if you have int or float It can promote it without using external libraries like wchar_t * in < Pre> std :: wostringstream oss; Int i = 1212; // or float F = 1212.0F; Oss & lt; & Lt; I; // oss & lt; & Lt; F; Std :: wstring ws = oss.str (); Const wchar_t * cwp = ws.c_str (); // const wchar_t * std :: vector & lt; Wchar_t & gt; Buf (cwp, cwp + (wc.size (+ 1)); Wchar_t * wp = & amp; Buf [0]; // wchar_t *

c# - Report Error. Deserialization failed: The element 'TableCells' in namespace -

I am trying to create a new report in my ASP.NET application. I am using the Report Wizard to try to create my .rdlc file. I am using a stored procedure defined in the SQL class in my Linux. I get the following error after completing the steps of the wizard. I can not seem to find a lot to shoot this error. Deserialization Failure: Incomplete content in element 'tableclack' '' in namespace is possible list of elements: '' line 125, position 32. Div class = "post-text" itemprop = "text"> Have you developed your report against a different version of SQL, are you deploying it? As you have developed it against SQL2008 and are you trying to deploy it against SQL2005?

ANTLR named function arguments / parameters in any order -

I'm looking for a way to designated function arguments / standards appear in any sequence in ANTLR . Anyone know if there is syntax in an ANTLR parser expression to ignore the command Say a function is in the foo language that can take two named parameters : X and y . Since they have been given the parameter name, so I want them to pass in the function in any order: foo (x = 1, y = 2) should be statutory foo (y = 2, x = 1) Both should be statutory. I can only list all parameter permutations in ANTLR, but I would have expected there would be a more elegant solution, especially since I can take some functions that take 5 parameters. Any help would be greatly appreciated! I am absolutely sure that nothing has been made in the ATLR so that it can handle it. . But you can do simple sprinkle to rebuild some regular programming logic parameters in your grammar Here is a small demo grammar: grammar NF; @ Pars :: header {package antillesmo; Import java.u

c# - Update binding of TreeViewItem using code? (XAML / WPF) -

मेरे पास TreeView जिसका ItemsSource एक मॉडल I पर सेट है की है। 3 स्तर गहरा एक वस्तु है जिसका राज्य बदल सकता है और प्रत्येक चरण (बहुत लंबा व्यवसाय) के लिए एक व्यू और व्यू मॉडेल लिखने के बजाय मैं इसे कोड का उपयोग करके अपडेट करना चाहता हूं। इसलिए मूल रूप से मेरे पास एक इवेंट है मेरे मॉडल के अपडेट के बाद निकाल दिया जाता है, मैं इसे पकड़ता हूं और फिर इस डेटा के साथ जुड़े TreeViewItem को ढूंढता हूं क्या कोई भी मदद कर सकता है? मुझे पता है कि यह सबसे अच्छा अभ्यास नहीं है लेकिन मैं वास्तव में एक समय के लिए कोड को बड़े पैमाने पर लिखने में समय बर्बाद नहीं करना है, बस एक चीज़ को अपडेट करने के लिए। धन्यवाद क्रिस यह उदाहरण काम करता है, हालांकि यह केवल दो (3 नहीं) स्तर गहरा है यह संख्यात्मक बच्चों (ए .1, बी .1, आदि) के साथ, माता-पिता, ए, बी और सी के साथ एक साधारण 2-स्तरीय पदानुक्रमित वृक्षचित्र दिखाता है। जब नाम बदलें B.1 बटन क्लिक किया जाता है, तो इसे B.1 को "सिल्विया" का नाम दिया जाता है। System.Collections.Generic का उपयोग कर; System.Windows का उपयोग कर; System.

internet explorer - Excel VBA and InternetExplorer causing errors on website -

I have some "smart" users who have written an Excel spreadsheet that automates some of their tasks on our intranet / tile sheet . It seems that the example of a built-in Internet Explorer is not doing everything I expect of a browser, e.g. Set up Cookies Is there a way to find out if a user is killing a web site with Internet Explorer's VBA COM object instance? I can not keep users from making creative solutions but I want to handle them. Thank you Some things come to mind first, until any restricted information or web scraping data If you do not intend to make public, it is better to fix the site so that the site works with purpose, but the user can still use VBA to access the place. VBA is an important productivity tool for many businesses and can provide people the flexibility to "extend" a site for those places which may not be suitable for development requests. However, if you insist on trying to break your user's application :) ... check the

asp.net - Disabled controls in Firefox -

In my custom webpage project first, I use a master page. What drives me is crazy, that hyperlinks (2 out of 2 children page) are disabled when debugging with Firefox (V 3.5.5). I have to face the same problem with a radio button list, which seems to control the ASP wizard, (does not accept the focus). Do not I understand why this is only in Firefox and not in IE Update: It works in both Firefox and IE Label: id = "lblsh" runat = "server" font-name = "Tahoma" font-size = "8pt" ForeColor = "white" text = "Your personalized update is Please "& gt; & Lt; / Asp: Label & gt; & Lt; Asp: hyperlink id = "hyperprofile" runat = "server" font-name = "taahoma" font-size = "8pt" font-underline = "true" ForeColor = "# FF6D06" navigate = url = "~ / ClientCenter / MyAccount .aspx "& gt; Profile & lt; / ASP: Hyperlink & gt; and

java - Trigger function when Undeploying application -

Text "itemprop =" text "> contextDestroyed () Apply and hook on Basic Example: Public Class Config Elements ServletContextListener {Public Zero Reference Start (ServletContextEvent Event) {// Write a code here, which should be executed on WebApp startup. } Public Zero ReferenceStored (ServletContextEvent Event) {// here is the code that should be executed on webpage shutdown. }} and call it and lt; Listener & gt; Register as web.xml in . & lt; Listener & gt; & Lt; Audience category & gt; Com.example.Config & lt; / Listener Category & gt; & Lt; / Listener & gt;

How do I join on a constant in LINQ? -

I'm trying to connect one left to the static like this: SELECT [ T0]. [DeviceId], [t0]. [DeviceTypeId], [t0]. [UnitID], [T.] [Unit Num], [T]. [MANOFFON], [T.]. [Status], [t2 [device] AS [ServiceExpiration] FROM [dbo]. [Instrument] AS [T] Inner Join [DBO]. [Customer Devoice] AS [T1] On ([T.]. [DeviceID]) = [T1]. [Device ID] Leaving [DBO]. [Maintenance] AS [T2] ON ([T.]. [DeviceID]) = [T2]. [Deviceid] and 8 = [t2] .aidid I get this when I try this in LINQ like this: Var devices = d to db Connect the CD to the DD in the device. Customer Devices CD on D.eviceId Divorce is equal to joining service DB New {d.DeviceId, ActionId = 8} / CS1941 is equal to the new {serviceExpiration.DeviceId, ActionId = serviceExpiration.ActionId}, Ration in device J1.DefaultIfEmpty () ration Try with Maintenances ActionId == 8 first, then go against it Use the. var expirations = Service retirement in DB Ensure that the termination of service ActionID == 8 Select service; Var device =

iphone - Provisioning failure in Application Testing Setup -

I'm trying to set up application tests to run on my development device but Apple's "Development Guide: Unit" Test app "() does not seem good enough ( after I set the active target for the base SDK to the iPhone device 3.0 and MyAppTesting (for application testing under steps 9 and 10) And in the attempt to make the following about provisioning Received error message: Code Sign Error: The application identifier does not meet a valid provision profile matching 'com.yourcompany.MyAppTests.' < P> I've verified that identifier (highlighting the target, display information -> properties page) is similar to my test version along with my regular goal. Target on the device? My door Settings to be given me with the approved development tools that allow running applications on any provision of delivery devices. You need a provisioning profile whose application ID is your ID Matches The Ovisioning profile is obtained with Apple throu

oracle - How to assign correlative numbers to rows only using SQL? -

मेरे पास ओराकल डाटाबेस में निम्नलिखित तालिका है: इनवॉइस नम्बर इनवॉइसडेट इनवॉइस कोरलरल --- ---------- ----------- ------------------ 123 02-03-2009 0 124 02-03 -2009 0 125 02-04-2009 0 126 02-04-2009 0 127 02-04-2009 0 128 02-05-2009 0 12 9 02-06-2009 0 130 02-06-2009 0 ... .. .... और प्रत्येक पंक्ति के लिए 1 से शुरू होने वाले नंबरों का अनुक्रम रखने के लिए मैं प्रत्येक पंक्ति में Invoice Correlative कॉलम के लिए एक मान सेट करना चाहता हूं । उपरोक्त उदाहरण में मैं तालिका को इस तरह दिखना चाहती हूं: इनवॉइस नम्बर इनवॉइसडेट इनवॉइस कोरल ------------- ----------- ------------------ 123 02-03-2009 1 124 02-03-2009 2 125 02-04-2009 1 126 02-04-2009 2 127 02-04 -2009 3 128 02-05-2009 1 12 9 02-06-2009 1 130 02-06-2009 2 ... ... ... क्या यह करना संभव है केवल SQL कथन का उपयोग कर ?। मैं rownum के साथ खेल रहा हूं लेकिन कहीं नहीं मिला। कोशिश करें: < पूर्व> ROW_NUMBER () ओवर (इनवॉइस डेट द्वारा चालान संख्या द्वारा भाग)

sql server - What SQL queries will help analyse a membership base? -

In our sports center, I would like to analyze the number of numbers and types of our members, but I'm having trouble exact With SQL queries. A "membership" is an entry pass that helps you in specific activities in our sports center. They have a start and end date, they represent a valid period. They have an affiliate activity (such as "gym", "swimming", "group fitness", "rock climbing", etc.) A member may have more than one subscription. Generally, their expiration period will expire before one can buy them, but they may have two (or more) valid (or current) subscriptions. A little bit simpler, we have the following two tables: Members - Store a member's data, these are the column IDs - member name (varchar) Unique ID for - Member's Name Gender (Membership) - Member's Gender NumGym (int) - The number of valid Gym is a member (Derivative) and Membership - Sold by us All membership has been subscribed, thes

ruby on rails - Can I Change Look / Feel Of Scaffolded Pages With Mostly CSS? -

I am using Web Framework (Grails similar to railways), in which auto-generated many codes through scaffolding Has the ability to do Consequently, all of my CRUD pages have been automatically generated, and whenever I want to further customize the contents of those pages, I still have the ability to insert additional HTML code I have the scaffolding I can control the templates and therefore can wrap any generated field in my own DIV or, when needed, can also apply through all the scaffolding. So if I have an object with the name and password field, then I can make my scaffold something like this for the "show" page. & lt; Div id = "prop.password" & gt; Password & lt; / Div & gt; & Lt; Div id = "prop.password.value" & gt; *** & lt; / Div & gt; We are about to put a more realistic design on scaffolded pages, and I'm wondering if the designer has the original layout (headers, footer, menus, etc.), but my For th

datetime - How to calculate elapsed time in terms of minutes in MySQL -

एक तालिका में एक समय स्टाम्प स्तंभ / फ़ील्ड है, और प्रारूप 2009-12-05 10:35:28, अब मैं मिनटों के संदर्भ में समय प्राप्त करना चाहता हूं (कितने मिनट बीत गए हैं) तब से समाप्त हो गए, यह कैसे करना है ? का उपयोग दिनांक / समय मानों के बीच अंतर प्राप्त करने के लिए किया जा सकता है, जो "एचएच: MM: SS.SSSSSS "format। इसे कई सेकंड में परिवर्तित कर सकता है। SELECT TIME_TO_SEC (TIMEDIFF (NOW (), my_date_and_timestamp) / 60;

jQuery Dropdown Menu Functionality based on Click Events (hiding help) -

I have two jQuery menus that are displayed properly when clicking on "show". For example, we say you have two links: "Show 1", "Show 2" You click "Show 1" and then click on a div in " Show 1 content appears with " You click on" Show 2 "and then a Divide appears with" Show 2 content " I found that point Has worked on Obviously there are some useful things that I need to deal if I click on "Show 1" and then click on "Show 2" then I will "Show the contents of 1" disappear Another thing, if I click anywhere on the page, whatever dropdown is active, I want to hide it to click outside the content box. My DOM structure: ul li.menu span = link_to '1 show' ul.dropdown.hidden li = link_to 'show1 content' li.menu span = Link_to 'show2' ul.dropdown.hidden li = link_to 'show2 content' my JS: $ ("# search li.menu Span a "). Click (func

java ee - HttpServletRequest.getRemotePort() -

How can a possible seller implementation of HttpServletRequest.getRemotePort () port remote? Is the actual request sent? I can not see a request header like "client-port", "request-port" or the like. The web server receives the client's request using the general mechanism of TCP / IP client host And the port is between information available at that level. After the connection is established, the server packs it into the information of the request sent to your program. The client does not send its port number, and even if this happens, it would be of suspicious value because it would be very easy for misunderstood fake port numbers by TCP / IP stack It is sent as part of the packet.

java - Runtime error when using StringUtils -

I'm using StringUtils in my Java code written in Intellij IDEA. My server resin is 3.1.9. I have no problem compiling the code, but when I ran it, I get the following Runtime exception: com.caucho.java.JavaCompileException: /sample.jsp: 219: Symbol symbol can not be found: method starts unknown cache (java.lang.String, java.lang.String) Location: org.apache.commons.lang.StringUtils Do I Am missing something? Thank you You said that you have no compile time error. But in reality this is a compile time error. You got it when your server tried to compile your JSP page, show the code of your JSP on line number 21 9 Most likely you do not have a commons-lang jar file in your classpath, that means you should add it to your application WEB-INF / lib < / Code>.

c# - "FormatException was unhandled" Input string was not in a correct format -

There is an error in my website and trying to solve it: error "format exception was unchecked" Both works for date with time as well as string and integer. Please see the details and the code thanks Previous> Return Convert.Change Type (IsThisObjectNull, DataTypeCode); The conversion is probably unsuccessful due to incompatible types. You may have to debug and check.

SQL Server DataBase Synchronization -

Is SQL Server compatible with many processes? Is it possible to get synchronized to work in the database so that more than one process is used at the same time? The SQL server is designed to handle multiple processes working simultaneously on the same data (Through various lock mechanisms etc.). You can also control the level of synchronization / isolation through the SET transfer algorithm statement. ()

caching - Does jQuery $(this) need to be cached -

I've recently come across some blog posts about jQuery's performance (i.e.) and all of them have been said That we should cache JQuery objects to JavaScript variables. What I need to know, though, is that it applies to $ (this) also if I do this, I will get it in the performance: $ ("# Some-link"). Click ("click", function () {var $ this = $ (this); $ This.doSomeThing ();}); Thank you in advance for your help. This can reference many different objects. Caching $ (this) can not be important, because this is already running element and thus jQuery DOM search for this element There is no need to do Although in a function if you call $ (this) more than once, then it is wise to put $ (this) There is $ (this) variable instead of making calls. Click $ ("# some-link") ("click", function () {var $ this = $ (this); $ this.doSomeThing (); $ this DoThisThing (); $ this.doThatThing ();}); will be more efficien

java - Pros and Cons of JavaFX and Silverlight -

I know there is a question about the performance of Flex, JavaFX, and Silverlight already. My question is a bit wider: We are evaluating the qualifications of JavaFX and Silverlight that control / configure our back-end service (currently written in Java). Service and GUI are usually on the same machine, but remote management (through the browser) should also be supported. We are currently divided into 2 teams: one. Net and a Java, though some of the Java developers have something to do. Net experience. As I've seen, professional & amp; Currently the following are: Silverlight 4: Pros: Excellent IDE integration Good developer-designer workflow << / Li> Comprehensive third party support (device, control, etc.) Much speed and drive from Microsoft Very good -Console integration Cons: Only supported on Mac & amp; Windows (Moonlight does not support standard) Java Fx 1.2: Professionals: Only supports Latin characters (at this time)

text to voice software -

Which programming language is appropriate to create a programming language like a voice converter? Microsoft's The system in the NET framework. Speech synthesis is a library that will accommodate your needs. (Although unfortunately the comment is still more generally valid)

python - Highlight a row in wxGrid (with wxPython) when a cell in that row changes programatically -

How do I highlight a line after the update of the built-in PyGridTableBase? I can not get my head around it. I am able to create linear lines for the first line line: ### Style a small table Def GetAttr (Self, Row, Column, Prop): attr = gridlib.GridCellAttr () if self.is_header (line): attr.SetReadOnly (1) attr.SetFont (wx.Font (10, wx.FONTFAMILY_DEFAULT, wx.NORMAL, wx.NORMAL)) attr.SetBackgroundColour (wx.LIGHT_GREY) attr.SetAlignment (wx.ALIGN_CENTRE, wx.ALIGN_CENTRE) if the prop is 'exposed' attr return: attr.SetBackgroundColour ( '# 14FF63') self.SetRowAttr (attr, line) # Ode any rows if the row% 2 == 1: attr.SetBackgroundColour ('# CCE6FF') Return Entry Return E do not But even after a fire. You're doing the right thing, the only problem that comes to mind It is that you probably did not refresh the grid manually after the GridTableBase update. Here's a small work example that is expected to help you out Import wx, wx.grid class

perforce - How to perform p4 submit operation without passing description inside the p4 submit form -

I have a P4 client workspace on a Linux machine. I add / edit some files in my client space and then try to restrict those changes to the server. I can not succeed but the steps given below are: p4 submit -d "test" When I tried just with p4 submit then open it p4 form submit and then I [enter details here] with token appropriate details and then it works. But I do not want to submit a form to submit a P4 to submit P4. How can I pass this information from a command prompt? / P> answer - p4 -d flag support for submission order was not started in the predominant version 2006 . So here's the solution to this problem: To modify the description field on the pre-2003 dislocation server, try piping a change / out form of a stream editor in / out it will create a numbered conversion list, which is then submitted needed. For example, something like: P4 changes - o. Sed -e "s / & lt; enter details here & gt; / my desc /" | P4 transf

c# - SharePoint MySites URL Conflict -

SharePoint site has a user login that we created using our email address and it becomes their username Creates a problem for MySites. When the user creates a MySset by cutting anything after the @Simbel in the user name, then the user's email address, user1@test.com, becomes the URL to your MySite: http: // host / personal / user1 / However this causes a problem if they have another user with the same email prefix but a separate domain That is, with user1@anotherdomain.com. This user needs to sign up for MySite URL on the site http: // host / personal / user1 / Using: (Profile Manager.UserExists (Username)) {UserProfile profile = profileManager.CreateUserProfile (username); Profile ["favorite name"]. Value = Full Name! = Null? Full Name: Username; Profile ["WorkEmail"]. Value = email! = Null? E-mail : ""; Profile ["PersonalSpace"] Value = email; Profile.Commit (); #region Create user (SPS ite site = profile.personal site)

facebook - Can javascript be used in static FBML under pages' tab? -

I want to hover the image in the static FBML page. But the following simple code also works: & lt; Div id = "button1" & gt; Button1 & lt; / Div & gt; & Lt; Set id = "button2" onmouseover = "document.getElementById ('button1'). Set-style ({display: 'none}}" & gt; button2 & lt; / div & gt; & lt; script type = " Text / JavaScript "& gt; Document.getElementById ('button1'). SetStyle ({Display: 'None'}); & lt; div Id = "button1" & gt; button1 & lt; / div & gt; When "onmouseover" is turned into "onclick", this works. & Lt; div Id = "button2" onclick = "document.getElementById" ('button1'). Set-style ({display: 'none'}} "button2 gt; & lt; script type =" text / Javascript "& Gt; Document.getElementById ('button1'). SetStyle ({display: 'none'});

Auto fit labels in R boxplot -

We currently use R for generating various types of boxplots / Code>. We have the problem that the length of our plots varies considerably between different plots and sections in a plot. Is there a way to automatically adjust a plot so that all the labels fit it well? It is not possible to specify the worst case mar because the label in some plots is much less than the other. is a Latys graphics library which is likely to be helpful here. I say that for two reasons: (i) Latis is based on grid system, and by reaching the grid's graphical premiums, you can get more control in place of the other things, instead of your panel output; And (ii) There's more to work with - R standard graphics package has 70 different parameters, while there are 371 in the laties - from my count, (length (name (list (list (tarry. .) ()))), Yet they are not in the 371 flat structure as they are in the original package, but instead in the hierarchical structure (with parameter grou

python - Simple Automatic Classification of the (R-->R) Functions -

Given the data value of some real-time physical processes (such as network traffic), it is to find the name of this function "Best" with the data " I have one kind of work Y = f (t) where y and t are real: funcs = set ([cos, tan , Exp, log]) and list of data values: values ​​= [59874.141, 192754.791, 342413.392, 1102604.284, 3299017.372] What is the simplest method possible to find a function from a given set? Div class = "post-text" itemprop = "text"> Saple is for fitting data, but they use multi-level or splene. You can use one of the guavas, many others Method to fit tasks.

sql - Sqlite API boolean access -

This should be an easy question for me, but I did not know where it is surprisingly, so I posted I am doing it here. I inherited an escalit-driven database in which it contains boolean columns, has been declared as such: create table example (ex_col BOOLEAN NOT NULL DEFAULT 0,); This table is trying to access via sqlite3c API call sqlite_column _ * function, now given that the scalites are actually boolean types Does not support, what is the expected behavior here? It looks like sqlite_column_int () always returns 0 or false , I believe this because all the columns in the Sqlite are actually text columns. .. And what is the correct way to keep it - to get it in the form of text and then string in comparison to the truth? I do not really want to modify the database and all other code attached to it. In an obvious way it will be "declared" in the form of a "full" column, and then when you INSERT will update or you will pass it 1 (True) or 0 (

unit testing - Grails PUT request with XML -

I have put a request I'm trying to unit test to create a user object. Unit Test: void testPUTXMLResponse () {def mockUser = new user (user name "Fred", password: Userkencrypt ( "Letmein"), FirstName "Fred", LastName "Flintstone", MiddleName: "T", phone: "555-555-5555", email: 'fred@fred.com', activationDate: new date (), logonFailureCount: 0) mockDomain ( user, [mockUser]) def mockUserXML = mockUser XML mockRequest.method = 'put' mockRequest.contentType = 'text / xml' mockRequest.format = 'xml' as mockRequest.content = mockUserXML.toString (). getBytes () controller.create () def updatedUser = XML.parse (mockResponse.contentAsString) stressed updatedUser.id == 1} controller action: def = {println If request.xml def user = new user (params.user) (! user.hasErrors () & amp; & amp; user.save ()) {println user.id withFormat {html {/ * (Presenting the scene: "show"

flex - Changes to one variable propagates to another -

For example, I have two ArrayCollection - first AC and IICAC. If I do secondAC = firstAC, and I make a second AAC change (already a filter function was applied to it) it is somehow used to propagate AAC first, would someone tell me that in Flex or ActionScript 3 Why does this happen If I only want secondAC to get all the data from the first AAC, but then when I make changes to the second AAC, then I do not see it in AAC first? Thanx a bunch for the answer! Ladislav In ECMAScript languages ​​(AS1-3, JavaScript, et al.), When you use var foo = // Some values ​​which are not a string or a number What exactly are you saying "Fu now points to the same object It is the other variable. "This means that in this situation, both arrays will have the same values: var foo: array = [1, 2, 3]; Foo = bar; Bar Peash (4); Trace (fu); // 1, 2, 3, 4 also works for this function: var foo: array = [1, 2, 3 ]; Copula (af); Function Joiner (Bar: Array): Zero {bar.push (4);

c - How portable is the output of pcap_compile? -

pcap_compile () एक फिल्टर प्रोग्राम में एक स्ट्रिंग को bpf_program के रूप में संकलित करता है स्ट्रेट सिद्धांत में मैं प्रोग्राम के संकलित रूप को सहेज सकता हूं और उसे एक अलग नेटवर्क इंटरफेस पर या यहां तक ​​कि किसी भिन्न मशीन पर pcap_setfilter () के लिए आपूर्ति कर सकता हूं। क्या वह काम करेगा? क्या विभिन्न इंटरफेस में bpf_program फॉर्म पोर्टेबल है? अलग प्रक्रियाएं? विभिन्न आर्किटेक्चर? या क्या हर बार जब मैं इसे इस्तेमाल करना चाहता हूं, तब अभिव्यक्ति संकलित करना सबसे सुरक्षित है? pcap_open_dead () के अस्तित्व के आधार पर मुझे लगता है कि यह कुछ पोर्टेबल है, लेकिन क्या सुरक्षित है और क्या है प्रलेखन में कहीं भी नहीं लिखा जाता है। नहीं, यह पोर्टेबल नहीं है सामान्य में। आप उन्हें उसी मशीन पर उपयोग कर सकते हैं। समान मशीनों पर कुछ हद तक सुरक्षित रूप से विभिन्न आर्किटेक्चर? शायद ऩही। हो सकता है कि उनके समान प्रकार हों विभिन्न ऑपरेटिंग सिस्टम? नहीं। मैं इनमें से किसी को भी नहीं सुझाता। यदि आप वास्तव में यह सुनिश्चित करना चाहते हैं, तो जब आप इसका उपयोग करते हैं तो अभिव्

icalendar - Google Calendar .ics import Standards -

I have an .ics file that I generate from my database that works properly in iCal, but Google Flaky in the calendar will occasionally import the Google Calendar file, but it does not raise all events. Do anyone have any suggestions on what areas Google has to offer? I'm at a loss here because sometimes why it is not imported, or why it does not like some incidents. We have 3 events for a few days, but Google only shows 1. Searching for more online does not really help because it seems that most other people have this problem Here is a sample of my formatting: BEGIN: VCALENDAR method: Publishing X-Dbluar- Timezone: America / Los_ajels Kaslshal: Gregoriyn version 2.0 Prodeed: - / / PUC calendar // v2.0 / etc BEGIN: Viaianti UID: 31754826317 Tijeaidi: US / Los_Egels DTSTAR: 20091001T 100000 URL; VALUE = URI: http: //www.puc.edu/news/calendar/events/dates/colloquy Dr.-Knight DTSTAMP: 20091001T100000 Summary: Colloquy: Heather Knight DTEND: 20091001T100000 Location: Sanctuar

microsoft.build - Programmatically modify Assembly Binding -

I have a problem with which I should be sure to modify the following .exe.config file. & lt ;? XML version = "1.0"? & Gt; & Lt; Configuration & gt; & Lt; Order & gt; & Lt; Assembly binding xmlns = "urnchemas-microsoft-com: asm.v1" & gt; & Lt; DependentAssembly & gt; & Lt; Assembly ID name = "Microsoft.bild framework" publicKitokon = "b 03f5f7f11d50a3a" culture = "neutral" /> & Lt; Compulsive Redirect Old Version = "0.0.0.0- 99.9.9.9" New WordPress = "3.5.0.0" /> & Lt; / DependentAssembly & gt; & Lt; Assembly identity name = "Microsoft.Build.Engine" publicKeyToken = "b03f5f7f11d50a3a" culture = "neutral" /> & Lt; Compulsive Redirect Old Version = "0.0.0.0- 99.9.9.9" New WordPress = "3.5.0.0" /> & Lt; / DependentAssembly & gt; & Lt; / AssemblyBinding & gt; & Lt; / Orde

iis 6 - ASP.Net error: The Local Security Authority cannot be contacted -

An Asp.net site was working under development on IIS6 and Server 2003, and after that something changed IIS Resets me and I'm getting an error message Local Security Authority can not be contacted IIS log returns code to 500 0 2148074244 I do not know what happened, but there is nothing like that in any log, which shows that does anyone know anything? The problem was with the EE pool identity in any way the service account name has lost its domain. App Pool was running as app_svc when it should run as domain \ app_svc When the domain was added back to the service account name, then everything started working again.