Posts

Showing posts from April, 2010

c++ - Automatically choosing object files for compilation -

I have recently started to write in C Unit Test ++ project (use). Creating main project is quite simple: I use the GCC -MM and -MD flag to automatically generate dependency to your object files, then I I am linking together for all the object files. Produce is not executable any inspiration. But as I am writing a unit test, is there any way or the GCC will know which object files are necessary to compile each test? Now, I have a simple solution (if you can call it) is useless as it collects all available object files for all the unit tests, which clearly (in terms of both time and space). Is there any way (make, gcc, SAD, or some need object files to the unit test in a forest) is divine, as how to generate dependency to the original source files ? It seems that you have two groups of source files: that actually executes your program , and the second is that all unit tests I believe that their own main function of each unit test, and once the unit tests do not even need...

c# - Webdriver: Interact with grid -

To edit the content of a cell on which you have to double click on it even though with the Webdriver they have an API There is no doubleclick function. How else can I change the contents of a cell? Which grid are you asking about? There is a JavaScript function to start editing cells for most grids. Still you can double click with javascript. Below is a IWebElement that you want to double click on element : for InternetExplorerDriver : ((IJavascriptExecutor) driver) .ExecuteScript ("Logic [0] .fireEvent ('onblblick')", element); For FirefoxDriver and 'ChromeDriver': ((IJavascriptExecutor) driver) .ExecuteScript ("var evt = document. CreateEvent ('MouseEvents'); evt.initMouseEvent ('dblclick', "+" true, true, window, 0, 0, 0, 0, false, false, false, false, 0, "+" null); "+" Logic [0]. Disappeared (EVT); ", Element);

android - detect where on the screen onTouchevent happened -

I found an onTouchEvent boolean on a Surfaceview, I have open GL objects drawn on the scene and I'm wondering, by the way Also know where the on-touch has happened on the screen? For example (x, y) coordination Use event .getX () and event.getY () Assuming that you have the following method The signature is: Public Boolean On-Touch (View View, Motion Event Event)

How can I make the SourcePath property of a file in a Visual Studio Setup and Deployment project (Windows Installer) relative rather than absolute? -

I have found a relatively simple project that is under source control (SVN), and I wanted to make an installer. I know that I can use it, but as I am new to making installers, I thought the built-in Visual Studio (2010) setup and deployment wizard would be easy to use. Unfortunately, it seems that there are files to be added with external (non-project-created) documents, configuration files, and full paths. This, of course, is subplot. I searched the web but did not get any answers, only one and the StackHowflow user has asked one, but the only answer is the suggestion that gives off-base (I have to keep an MSI that I have web based I do not want to distribute the installation). Does anyone know how (or what) it can be decided? It can be easy now but when you come to the limits of the device this is really hard to come Come bad Do not talk about behaviors which can be really difficult for poor end users setting up your product, which will encourage it. You have got Visual Stud...

math - How to get value prediction from Polynomial curve? -

OK, so math is not my strong point! I have this data, I used Zunzun.com, to create a user defined polynomial curve for my data, which is y = a + bx1 + cx2 + dx3 + ex4 + fx5 However, when I recommend code use: double A = -4.2294409347240979 E + 01; Double B = 5.5 9 46102161174718 E + 00; Double C = -1.3446057748924720 E-01; Double D = 1.5448461146899649 E-03; Double E = -8.2537158069276241 A-06; Double F = 1.7176546321558128 E-088; Temp = f; Temp = temp * x_in + e; Temp = temp * x_in + d; Temp = temp * x_in + c; Temp = temp * x_in + b; Temp = temp * x_in + a; Return temporary; Does it give me the 'sum of complete error'? Say for X value 94, I should get a value of approximately 60.3, but this code gives me -46.152. I know that I'm stupid and obviously there is no equation in the end. But did anyone have guessed my Y value from my X with this platform? The graph really fits well and will not be great to use a lookup table. Many thanks! XY - 180 200 178 1...

compiler construction - How use to write programme that involve with a lot of active calculation? In excel 1M+ Row and 20+ column -

First of all, I have no experience with programming. If I ever start, it would probably be my first I am looking for a reply to this site as long as no. I am looking outside the box because Excel is doing data of 1 million + row and 20+ columns, just to wait for the calculation will take a very long time and with copy and formula Paste will take longer to imagine that with the help of Marco and F4 (repeat) I have to give the computer more than 8 hours to run. All my formulas need to be pasted in number only, as I did with the formula. And even if I break the files into pieces, without the active size the file size is 20 MB to 110 MB. Opening the file is always taking place. I wonder how to write a program with a dialog box, 2) Excel command and formula (sort, delay, contattetate), 3) the ability to create graphs, 4) data with tabs Or to see the different set of graphs 5) Add a set of data 6) Number limited (1-100000), etc. Outlook looks like some utorrent What compiler is sui...

php - Getting total number of records from mysql table - too slow -

I have a file that goes through a large data set and divides lines into a paged way. There are about 210k rows, which is not very much, it will increase up to 3 miles + in a few weeks, but it has already slowed down. I have one such query, in which the number of total items is DB for a special WHERE clause combination, the most basic one looks like this: SELECT count It takes 0.9 seconds to run (v_id) from num_items versions like WHERE v_status = 1 . The second query is a limited query that receives the actual data on that page. This question is really quick (under 0.001) from v_id, v_title, v_desc in variants where v_status = 1 command v_dateadded DESC LIMIT 0, 25 There is an index on v_status, v_dateadded I use php; I cache the results in the memcache, so later the requests are really fast, but the first request has been requested. In particular, once I throw it in a complete search, it starts taking 2-3 seconds for 2 questions. I do not think this is corre...

html - Javascript: Enabled / Disable radio on selected with javascript -

I want to make this form dynamic with prototype. I mean, radio should be disabled, but when you choose one, with JS, they should enable them, so if you choose another, 1 should be disabled. This is my html, but I do not know where to start with this work from JS, thanks & Lt; Input disabled type = "file" id = "uploadcv" name = "uploadcv" /> & Lt; / Div & gt; & Lt; Div id = "pasted cv" & gt; & Lt; Input type = "radio" id = "pastedCvSelector" name = "uploadFormSelector" /> & Lt; Textarea disabled id = "pastedCv" name = "pasteed cv" rows = "8" cols = "40" onclick = "this.value = ''" & gt; Paste your CV & lt; / Textarea & gt; & Lt; / Div & gt; & Lt; Input type = "submit" value = "send'em!" / & Gt; & Lt; / Fieldset & gt; & Lt; / Form & gt; I think your...

H2 Database vs SQLite on Android -

Due to I'm mostly interested in Android vs performance and stability Are you using it? Should I Know Any H2 Database Pitfalls? Things are much better than I expected Now I have an Android phone (HTC Desire, Android 2.2 ) And I have made a first test. Opening and closing a database is relatively slow (for the second time opening an existing database takes 0.2 seconds, approximately 0.2 seconds off), but otherwise it seems that H2 has performed very well on Android , Even if the delwyn VM desktop is not optimized as JVM. It is very quick to give a solid number, but Android is now a supported platform.

Taking object without empty properties in Linq -

मैं pa लेना चाहता हूं, लेकिन खाली MG props। मुझे पता है यह सच नहीं है, लेकिन मेरी वस्तु इस तरह से लेना चाहते हैं: var vv = pa.mg.Where (_p = & gt; _p .2! = "") चुनें। (_k = & gt; _k ** ** मूल **) pa.mg = pa.mg.Where (जीसी = & gt; जीसीएम 2! =" ") .ओएरे ();

string - Python Base64 print problem -

I have a base 64 encoded string When I decode the string like this: & gt; & Gt; & Gt; Base base & gt; & Gt; & Gt; Base64.b64decode ("XH13fXM =" '\\} w} s' The output is OK. But when I use it like this: & gt; & Gt; & Gt; D = base64.b64decode ("XH13fXM =")> and gt; & Gt; Some characters are missing Can anyone give advice? Thanks advanced. This is a matter of presentation: & gt; ; & Gt; & Gt; '\\} w} s' '\\} w} s' & gt; & Gt; & Gt; Print (_, lane)}}} 5 This string has 5 characters. When you use it in code, you need to avoid backslash, or use raw string literals: & gt; & Gt; & Gt; R '\} w} s' '\\} w} s' & gt; & Gt; & Gt; R '\} w} s' == '\\} w} s' true

ASP.NET jQuery - how to invoke server method when asynchronous method is complete? -

I have a jQuery plugin - how to open server side method on progress bar success? The code is below: (Everything is OK) $ ("# & lt;% = this.btnGetData.ClientID%>"). Click (function () (intervalID = setInterval (update progress, 100); $ .ajax ({type: "post", url: "progressbar. Espx / executeport", data: "{}", content type: "app / Jason; Charset = UTF-8 ", Datatype:" Jason ", Async: True, Success: Function (msg) {// should be started here}}); Return Return;}); As we have installed it in the webform, then you have an ASP.NET AJAX You can use to callback the web method kept in your ASPX file. First, create your server side method in C # (or NAT language of choice) and comment it with more features, such as: [System. Web.Services.WebMethod ()] [System.Web.Script.Services.ScriptMethod ()] Public Static Zero MyServerMethod (string myArgument) {// Something} Then your aspx file You need to add a ScriptMana...

Starting with Android: Java or Python (SL4A) -

I just ordered an Android smartphone and want to start playing with my own application. Now the question is, what language should be used, native Java or Python is to use SL 4A (formerly ASE). I go for a dragon, because I know that it is better than Java, but I'm wondering what I will do on Android by using the language of "second class" This is also called alpha-quality software on the 4A website, which is not very encouraging. I am not sure what the limitations of the scripting environment are and if they are problematic. /p> At the moment you are using SL4A to release one with Python (or any other scripting language) Can not create a suitable program. I've heard rumors that it's something that is working on Google, but even if they enable it, then python apps are slow and power-hungry than Java There is a possibility. Additionally, the scripting API only provides access to a limited subset of native Java APIs. I will not consider using SL4A for s...

c++ - dynamic memory allocation -

Here is how Pointer is used to store and manage the addresses of dynamically allocated blocks of memory #include & lt; Iostream & gt; # Include & lt; Stdio.h & gt; using namespace std; Struct item {int id; Four names; Boat cost; }; Struct item * make_item (const char * name) {struct item * item; Item = maulock (structure item); If (item == faucet) return tap; MEMSAT (item, 0, size (strip item)); Items, & gt; Id = -1; Items, & gt; Name = zero; Items, & gt; Cost = 0.0; / * Save a copy of the name in new items * / item- & gt; Name = malloc (strlen (name) +1); If (item-> Names = NULL) {free (item); Return tap; } Strcpy (item-> name, name); Object back; } Int main () {Return 0; } But here are the mistakes 1 & gt; ------ Construction started: Project: dynamic_memory, Configuration: Debug Win32 ------ 1 & gt; Dynamic_memory.cpp 1 & gt; C: \ users \ david \ documents \ visual studio 2010 \ projects \ dynamic_memory \ dynamic_memo...

c++ - How do I get the size of a file after ftp'ing? -

सीएफटीपीफ़ाइलफेंडर खोजक (mConnection); पाया = खोजक.फंडफ़ाइल ("*। लॉग"); जबकि (पाया) {found = finder.FindNextFile (); Wsprintf (fileInfo, "% s", finder.GetFileName ()); // इस फ़ाइल के आकार की आवश्यकता है। लॉग // कोई सदस्य फ़ंक्शन CFTPFileFind वर्ग में इसके लिए? } संपादित करें उत्तर खोजक.गेट लैंप (); CFtpFileFind से CFileFind से प्राप्त होता है, जिसमें GetLengh () है।

xcode4 - How to rename a project in XCode? -

There are some very awesome instructions in XCode, is there no easy way to do this? Try this in encode 4: Click on blue node with ⌘ + 1, project name, wait a second, click again (name becomes editable). That's it.

Wildcards with ASP.NET MVC MapPageRoute to support organizing legacy code -

I am working to migrate an existing ASP.NET web site to an MVC project. There are many (60+) pages that do not want to rewrite yet, and so I'm thinking that there is a way I can: Existing .aspx pages (Setting up routing in my MVC structure) Set up routing, so call /foo.aspx (without 'legacy') will actually call ~ / Legacy / foo .aspx Effectively, I do not want "inheritance" in URL, but I also do not want that MVC solution I am sure that this is a very small case, I am curious if it can be done with routing. I know that I can do it: / P> routes.MapPageRoute ("legacy-foo", "fu espx", "~ / legacy / fu espx"); Is there any way to dynamically (using MVC routes)? Example: Routes. MapPageRoute ("Legsirounds", "{filename} .aspx", "~ / Legacy / {filename} .aspx " ); I think there is a way to use a URL rewriter module, but it seems that something is unnecessary when being able to route t...

CSV file written with Python has blank lines between each row -

खोलने के साथ सीएसवी आयात करें ('thefile.csv', 'rb') f: data = list (csv) डेटा में पंक्ति के लिए आयात संग्रह संग्रह = संग्रह .defaultdict (int): काउंटर [पंक्ति [10]] = = ओपन के साथ ('/ pythonwork / thefile_subset11.csv', 'w') आउटफ़ाइल के रूप में: डेटा में पंक्ति के लिए लेखक = सीएसवी। लेखक (आउटफाइल): यदि काउंटर [पंक्ति [10]] gt; = 504: लेखक। लेखक (पंक्ति) यह कोड पढ़ता है thefile .csv , परिवर्तन करता है, और परिणाम को thefile_subset1 पर लिखता है। हालांकि, जब मैं Microsoft Excel में परिणामस्वरूप सीएसवी खोलता हूं, तो प्रत्येक के बाद एक अतिरिक्त खाली पंक्ति होती है रिकॉर्ड! क्या यह एक अतिरिक्त खाली पंक्ति नहीं डाल सकता है? पायथन 2 में, 'w' की बजाय 'wb' के साथ आउटफ़ाइल खोलें। csv.writer लिखते हैं \ r \ n सीधे फ़ाइल में यदि आप द्विआधारी मोड में फ़ाइल नहीं खोलते हैं, तो यह \ r \ r \ n लिख देगा क्योंकि Windows टेक्स्ट मोड पर प्रत्येक का अनुवाद होगा \ n में \ r \ n । पायथन 3 में आवश्यक वाक्यविन्यास बदल गया है,...

jquery - jqgrid reload grid partially working -

I have a client side jackgood managed, when I remove some external events, then I reload. Everything is fine when I reload the grid with more data, but when I reload it with less data, the amount of rows is wrong. For example, when currently there are 100 rows in the grid and I reload it with 200, then the nav bar shows 200 records. If there are 200 rows and I refresh it with 25 rows, it still shows 200 in the shipping bar instead of showing 25. The code refreshing the grid looks like this: $ ("# List2") trigger ("GridUnload"); $ .ajax ({url: 'http: // xxx, datatype:' jason ', async: wrong, success: function (data) {gridData = data;} }); $ ("# list2") SetGridParam ({Data: Grid Data}); $ ("#list2") trigger ("reloadGrid"). I do not think the problem is with the navigation bar because I can clearly hit the next page and see the additional lines. Thanks Try changing $ ("# List2") [0] .refreshIn...

writing a django query and get reverse related objects in one hit of database! -

मैंने models.py में यह मॉडल लिखे हैं: वर्ग उपयोगकर्ता (models.Model): first_name = मॉडल.कारफिल्ड (अधिकतम_लाँग = 80) वर्ग कौशल (models.Model): उपयोगकर्ता = मॉडल। फ़्रीइन्गकी (उपयोगकर्ता) शीर्षक = मॉडल.खरीफिल्ड (अधिकतम_लांबी = 80) स्तर = मॉडल.इटेजरफिल्ड (डिफ़ॉल्ट = 3) वर्ग कार्य (मॉडल। मॉडल): उपयोगकर्ता = मॉडल.फोरिएग्नकी (उपयोगकर्ता) work_name = models.CharField (max_length = 80) salary = models.IntegerField () अब मैं उन कार्यों को उन डेटाबेस से प्राप्त करना चाहता हूं जो उनके उपयोगकर्ताओं के पास निश्चित है कौशल, और उनके साथ एक html प्रस्तुत करना मैं इस कोड को views.py: def show_works (अनुरोध, कौशल) में लिखता हूं: works = work.objects.select_related ()। फ़िल्टर (user__skill__title = skill) return render_to_response ("works.html", { 'काम करता है': काम करता है}} लेकिन उस HTML में एक और बात है जिसे मैं दिखाना चाहता हूं: मैं उस कार्य के उपयोगकर्ता के पहले नंबर और उसके कौशल दिखाना चाहता हूं। मैंने select_related () का उपयोग किया है, लेकिन मैं केवल first_name दिखा ...

java - getting uknown error -

OK, then there is an assignment: Create a simple image viewer that will allow the user to click Select an image from a button and then the file system and the image is displayed in JLabel. Here I have the code: import java.awt.event .ActionEvent; Import java.awt.event.ActionListener; Import java.io.file; Import javax.swing.ImageIcon; Import javax.swing.JButton; Import javax.swing.JFileChooser; Import javax.swing.JFrame; Import javax.swing.JLabel; Public Class Main implementation ActionListener {JButton openButton; JFileChooser FC; File filename; JLabel image; Jeff Frames; Public Main () {frames = new JFrame ("Picture Viewer"); Frame.setBounds (100,100,750,750); Frame.setLayout (zero); Frame.setVisible (true); OpenButton = New pocket ("Choose an image to display ..."); OpenButton.setBounds (0,0,750,50); OpenButton.setLayout (zero); OpenButton.setVisible (true); Frame.add (openButton); OpenButton.addActionListener (this); } Public static zero main (string [...

django - Is there a python implementation to .net automapper? -

Automap is an Object Object Mapper, where we will be able to project the domain model to see the model in asp.net net MVC Can be used. What is the same implementation in Python for use in Django (template) / pylons? Or what is the requirement for this in the Python world? This is not usually necessary in Python We have some very complex domain models and we will consider them as our ideas We are able to use it easily, considering the issues without any performance, and we serve hundreds of page views in a month. Also remember that in Django == "Controller" MVC in "View", and "Template" in Django "View" is in MVC so instead of MVC, MTV was a few things that I initially slipped : -) If there is a specific problem in which you are running, then also post it as a question ...

asp.net - jQuery and LinkButtons, or Regular Buttons and CSS -

On my master page I have a small login control on the login control, I am using a LinkButton for the submit button Because I like the way it looks. However, I'm also using jQuery when pressing in any of the 'Enter' to capture the login control text box with the click of the link button with jQuery in every browser is difficult to trigger is. I've also tried hard-code __doPostBack, but LinkButton ID is just a little different from what is built on the control href = "__ doPostBack" attribute. It is not responding to .trigger (), click (), etc. On the other hand, a regular button control works fine with jQuery click (). But the way I'm not a big fan of watching the button, and my CSS skills are limited. Is there a simple way to look like a normal ASP.NET button control like a link? Or is linkbutton an easy way to deal with jQuery? Whatever method I need to try less I :) Thanks in advance. You can get precise javascript by using the fire linkB...

java - JTextArea as listener for log4j Logger -

How can I set a JTextArea to get anything (I lack the "MyLoggerListener" like creating an interface and Implementation is in my JTextArea) Edit: I have fixed this problem by creating a textAreutputstream, by creating a print marketer, and adding a writer appendix with the printer in the constructor. Used to be. I think @ Oscaris's approach is a good idea. However, I think you should think it is difficult that you should try to do this. The problem is that the log message in the Java GUI is likely to be painting CPU intensive. It is likely to slow your app launch, and as a result there is a possibility of annoying your application. (It is not that your application should be sensitive at the time. But if you have time-bound bugs, then changing logging level etc. is not useful, so the application causes the app to behave differently. ) My feeling is that embedding a fancy log viewer in your application is more likely to be a problem because its price is ......

virtual memory - Which (OS X) dtrace probe fires when a page is faulted in from disk? -

I am writing a document about page defect and trying to work with some solid numbers, So I wrote a simple program that reads 12 * 1024 * 1024 bytes of data: int main () {FILE * = in fopen ("data.bin", "rb") ; Int i; Integer = 0; For (i = 0; i So yes, it reads completely and reads the whole file issue is that I need a fire detriment probe of 1536 times during this process (12M / 8k) . Even if I count all FBT: mach_kernel: vm_fault *: probes and all vminfo ::: checks, then I do not have 500 hits, so I know I have not found the correct check. Does anybody know that I can find a detrace probe when I get a page from Discovery? Update: The problem is that the issue was that some were intelligent after proceeding to the Stdio functions, I tried the following: int main () {int = open ("data.bin", O_RDONLY | O_NONBLOCK); Int i; Integer = 0; Four buff [128]; For (i = 0; i & lt; 1024 * 1024 * 12; i ++) {read (in, buff, 1); Total + = Buff [0]; } P...

firefox - CSS Problems with IE6 -

I am creating this site and it looks good in Firefox, Chrome, IE8, but apparently It looks like death in IE 6. Normally I hope everything looks a bit different in IE6, but it's not bad. I am not even sure why this is happening so much, anyway, I need to work on the site in IE6, but the problem is that I do not even have to test IE 6 or see if it is actually How does it look in Any suggestions I've just seen on screen shots? Very different results based on the method used to build your page in Internet Explorer 6 May be. There are some notable differences that are well documented on the web which explain various techniques to solve these problems. Internet Explorer on a machine that makes testing and a little easier. Note one side of my thoughts, if you need to develop these old browsers, then it is worth noting that some sources have a population of users Use of sites with IE 6 is approximately 12-15% What should be considered about how much time should be s...

Getting the left property of an LI element in jQuery? -

I have a dynamic list of LI inside of UL. I am trying to be competent in any way to 'track' the last list of ul, in which there is a final category. I thought that if I could test against a number of numbers for the left property of the original, I would say, -500, then I could have done what I had to do. The problem is that I can not get that property. Is it possible or override parents (in this case UL)? If you want a left position relative to the page, then you do so It can: var left = $ ('ul li.Last') offset (). Left; According to or their parents, do this: var left = $ ('ul li.Last'). Event (). Left; Example:

.net - Dealing with VB.NET Linq formatting in Visual Studio? -

Want to format the VB.Net Link code anyhow in visualization studio? What are some tricks for you, how do you work with it? I know that Visual Studio lets you uncheck the option of "Beautiful list (code) of code", but most of the time it's really easy to continue and with a team of developers who can make other settings If this is not really a viable solution, then my questions are: You can not use multiline link statements in VB without fighting Visual Studio code formatting Disposed? What is a special style guide for Linq is recommended VB.NET? Something like this is readable, and does the visual studio like without refunding nightmare? Edit - It may be that the clarity in my original question is not desired Ho. Here is a more concrete example: Take this fake linq query: Select one of the dcGetTable (DAL.GenericTableDao) () in the slow query = .withID = a.ID, .Something Eclse = a.SomethingElse, .MyOtherRecord = (DTC from Dc.gettable (DAL.DetailTableDao...

css html footer -

I am writing this question to better understand this problem: My There are 3 output mechanisms: PDF print generated using the same media type as the PDF screen are doing. On the screen: I just want the footer to appear below the content ... simple ... easy! PDF: I want to display the footer at the bottom of the last page of the content Print: As above, I have a footer in the bottom of the last page of the content I want to display The problem is: If I set the full position for the media type = print two problems: Its PDF display has no effect If the content is spread across multiple pages, then Under Prahlad article content is printed at the bottom of the first page. If on screen - I need a footer to display below a fictional page, so that when the PDF is ready, it will appear under the last GE If on print - I need the footer to display at the bottom of the last page of the content You can define 2 stylesheets for the page; 1 for "Screen" ...

.net - LINQ to Entities produces query containing datetime2 on SQL 2005 Express -

I have a VS 2010 Solutions is a unit project and a database project to manage schema in targeting. Net 4.0 The unit model is currently reverse engineered from the database. One of the tables is defined with one type of column. The database project is configured to use SQL Server 2005 compatibility mode and therefore it deploys all properly. I have just attended a problem where an update statement appears to use datetime2 instead of datetime2, through the unit structure, which causes exception because of the SQL 2005 data type Does not support: System.Data.UpdateException: An error occurred while updating the entries. See Internal Exceptions for details --- & gt; System.ArgumentException: The version of SQL Server in use does not support data type 'datetime2' The stack trace appears to be occurring inside this error: Data.Mapping.Update.DynamicUpdateCommand I have looked through all my SQL code and entity code and confirmed that datetime2 (including dbschema...

Adding email subscription to Wordpress theme -

I have developed my own Wordpress theme and I want to give users the ability to subscribe to my blog. I have the typical post RSS and RSS options that come with Wordpress under the sidebar's Meta section, but I wanted to give my readers an option just by inputting their email address and pressing the button "Customers Become " I know this is possible because I have seen many blogs that use it, and if necessary I can make a list here. But I'm not sure whether this is a plugin or a widget - you If you know how to implement this feature in a WordPress theme, please let me know. The plugin is sufficient in the directory; You should not add this topic to your subject; This is actually a plugin job, and your users can select someone else from you.

create new folder with php -

I have a file upload script that [finally] works, but wants users to submit photos to a folder, Which I want to be made as a user name I was thinking that I could probably submit the file and then to make it, but if it did not happen, how can I do this? This is my script: PHP code: & lt ;? Php // configuration portion $ dbhost = "localhost"; // database host $ dbname = "users"; // database name $ dbuser = "dbuser"; // database user name $ dbpass = ""; // Database password // Connect to database $ db = mysql_connect ($ dbhost, $ dbuser, $ dbpass) or die ("Error: Could not connect to database"); Mysql_select_db ($ dbname, $ db) or die ("Error: database could not be selected."); If ($ ezogg in) {$ userid = $ _GET ["userid"]; If ($ _ POST ['Submit']) {if ($ userid) {$ uploadName = mysql_query ("Select * from user where user id = '". $ Userid. "' '); While ($ upName = mysql_fe...

python - Using urllib and minidom to fetch XML data -

I'm trying to get data from an XML service ... it's one. I am using urrlib and minidom and I can not seem to make it work. I have used minidom with files and do not have URL This is a code trying to use xmlurl = 'http: //xmlweather.vedur .is 'xmlpath = xmlurl +'? Op_w = xml and type = forec & lang = & amp; See = xml & amp; Id = '+ str (space) xmldoc = minidom.parse (urllib.urlopen (xmlpath)) Can someone help me? The following should be done (or at least give you a strong idea about what is going wrong Should): xml.dom.minidom import parse import urllib xmlurl = 'http://xmlweather.vedur.is' xmlpath = xmlurl +'? Op_w = xml and type = forec & amp; Lang = is & amp; See = xml & amp; ; Ids = '+ str (try): xml = urllib.urlopen (xmlpath) dom = parse (xml) Exception as E: print (e)

c# - Build Version vs Revision number -

मेरे पास एक asp.net/C# ऐप है जो स्त्रोत नियंत्रण के बदले का उपयोग करता है। मेरा ऐप स्वचालित रूप से इसे इकट्ठा करना और प्रत्येक विधान पर असेंबलफाइलवर्सन जो एक जादू की तरह काम करता है, और साइट के प्रशासनिक पक्ष में बिल्ड संख्या प्रदर्शित करता है। हम जब हम परिनियोजन करते हैं, तब हम AssembleVersion और AssemblyFileVersion का ट्रैक रखते हैं, जब एक मुद्दा उठता है और हमें एक निश्चित संस्करण में वापस रोल करने की जरूरत है, हमें कोई अंदाज़ा नहीं है कि उपखंड में लक्ष्य को संशोधित करने के लिए कौन सा संशोधन है। मेरे पास कुछ विचार हैं: असेंबल सहेजें टिप्पणी के रूप में विर्सन किसी भी मदद और सुझाव की सराहना की जाएगी नवीनीकृत: विकल्प "1" वास्तव में एक बेवकूफ विचार है, इसका मतलब यह होगा कि हर बार मैं निर्माण, सभी फाइलों को अद्यतन के रूप में चिह्नित किया जाएगा और जब मैं प्रतिबद्ध हूँ, हर पाप Gle फ़ाइल को अपडेट किया जाएगा जब मैं बना रहा हूँ, तो मैं उस बिल्ड नंबर को हर जगह रख दिया। मैं इसे एक svn में डाल दिया। मैंने इसे बनाने वाले हर विधानसभा की असेंबली मेटाडेटा में डा...

.net - System.ArgumentNullException when adding AutoPostback to DropdownList -

When I add autopostback = trust with my dropdown list (on-selected index change), I get a system . Exceptional exception: Value can not be empty. My control looks like this: & lt; ASP: Dropdown list id = "dropdown" runat = "server" autostebback = "true" by changing the on-selected index = "dropdown_on-selected index changelog" /> and the code to fill the control: dropdown. Items.ad (new list item ("item 1", "1")); drop down. ITEM Add (new list item ("item 2", "2")); drop down. ITEM Add (new list item ("item 3", "3")); update I get an error when I add an empty page with the following code: & Lt ;; DOCTYPE HTML PUBLIC "- // W3C // DTT XHTML 1.0 Transcription // N" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> & Lt; Html xmlns = "http://www.w3.org/1999/xhtml" & gt; & Lt; Head runat = "server...

mysql - INSERT ON DUPLICATE KEY question -

मेरे पास [tagId, articleId] फ़ील्ड के साथ एक तालिका ' टैग_article_assoc ' है मैं एक विशिष्ट लेख के लिए नए टैग डालने चाहता हूँ (लिखते हैं, आइडी = 23), लेकिन पहले से ही डीबी में रिकार्ड को छोड़ दें। मैं सही वाक्यविन्यास, किसी भी विचारों पर निश्चित नहीं हूँ? डुप्लिकेट कुंजी अद्यतन पर wd_article_tag_assoc (tagId, articleId) मूल्यों ('$ upTag', '23') INSERT ... धन्यवाद s मुझे लगता है कि आपके पास tagId, articleId दोनों के रूप में है अपने डेटाबेस में प्राथमिक कुंजी wd_article_tag_assoc (tagId, articleId) मूल्यों में डालें ('$ upTag', '23') डुप्लिकेट की कुंजी अद्यतन tagId = $ upTag आप पढ़ने के लिए स्वागत है

debugging - Why does Perl's quotemeta() function behave differently when under the debugger? -

I have been bitten by this small inconsistent debugger behavior. perl -d $ perl -e 'under the print quotemeta ("/ a quotemeta () function behaves differently / The output is \ / a \ / b / c , which is correct and as such copy-F comma . Now, when under the debugger, the output becomes \\ / a \\ / b \\ / c . I thought that I'm using some core modules, Although the task was redefined in the form of a test, it seems that behavior happens when D CORE :: quotemeta () gives the same output. Can anyone illuminate me? Thank you! quotemeta is a shotgun, to avoid all non-word characters For whether they require it or not, debugger is less heavy; cites those words for which it is needed (backslash, do not slash forwards.) More importantly, when you use the original When you print them, then compare them: DB

asp.net - Modifying the html output of a gridview -

I'm trying to modify the output of my GridView in RowDataBound event handler, but it does not work - . Nothing happens My code: private sub MyGridView_RowDataBound (ByVal) MyGridView.RowDataBound e.Row.Attributes as this object, ByVal e GridViewRowEventArgs. Add ("data-xkoordinat" handle, 0) End Sub What I expected to see: what comes & lt; Tr & gt; ... & lt; / Tr & gt; How can I add attribution Update : I have done a lot more research, and seen there anything Not to know about the RowDataBound method - should it be there? I Page_Load is routine, where data binding, as follows: Protected Sub Page_Load (ByVal as this object, ByVal e System.EventArgs ) handles using IDatabaseAdapter = Locator.GetDatabaseAdapter (db as Me.Load) db.Open () MyGridView.DataSource = db.ExecuteReader ( "MatpunktLista", it is true, {db.CreateParameter ( "id_uppdrag", Request .QueryString ( "id_uppdrag"))}) will MyGridV...

NHibernate error (Cannot insert duplicate key with unique index) -

मेरा क्लास क्लाइंट: सार्वजनिक वर्ग क्लाइंट: इकाई {सार्वजनिक ग्राहक} {ListClientObjectX = नई सूची & lt; ClientObjectX & gt; (); } सार्वजनिक वर्चुअल आइएलआईटी & lt; क्लाइंट ओब्जेक्सएक्स & gt; ListClientObjectX {प्राप्त करें; सेट; } ...} मेरे क्लास क्लाइंटऑब्जेक्टएक्स सार्वजनिक वर्ग क्लाइंटऑब्जेक्टएक्स: इकाई {सार्वजनिक क्लाइंटऑब्जेक्ट X () {क्लाइंट = नया ग्राहक (); ऑब्जेक्ट = नया ऑब्जेक्ट (); } सार्वजनिक आभासी क्लाइंट क्लाइंट {get; सेट; } सार्वजनिक वर्चुअल ऑब्जेक्ट ऑब्जेक्ट {प्राप्त करें; सेट; } सार्वजनिक वर्चुअल स्ट्रिंग Name {get; मेरा क्लाइंट ऑब्जेक्ट टेबल तालिका में 2 कॉलम (क्लाइंटआईडी और ऑब्जेक्टएक्सआईडी) के साथ एक अनूठा इंडेक्स है: idxClientObjectX क्लाइंट मैपिंग (फ्लुेंट): पब्लिक क्लास क्लाइंटमैप: क्लासमार्क & lt; क्लाइंट & gt; {सार्वजनिक क्लाइंटमैप () {टेबल ("टीबीएलएक्टलिएन्ट"); आईडी (x = & gt; x.ID, "ClientID")। उत्पन्न हुआ। पहचान ()। बिना सहेजे हुए मूल्य (0); HasMany & lt; ClientObjectX & gt; (x = & ...

jquery - JQGrid loading message displayed after the grid container is hidden -

मेरे पास एक jqgrid है जिसका HTML निम्नलिखित तरीके से प्रदर्शित होता है। मैं यह कुछ कस्टम जावास्क्रिप्ट का उपयोग कर एक jqgrid के रूप में इस myTable का निर्माण। यह एक लंबे समय के लिए ठीक काम कर रहा था। जब मैं ग्रिड में कोई अभिलेख नहीं है, तो मुझे "टेबलसैक्शनडिव" को संक्षिप्त करने के लिए (छिपाने के लिए सरल शब्दों में) एक बदलाव आया है। ऐसा करने के लिए, ग्रिड पूरी घटना पर मैं गणना करता हूं, var r = jQuery ("# ​​myTable")। GetGridParam ('reccount'); यदि (r = = 0) {$ ("# tableSectionDiv")। Hide (); } वहाँ div को गिराने से एक बटन है जो div को साधारण $ ("# tableSectionDiv") दिखाएगा। शो (); कोड लेकिन जब मैं ग्रिड को देखता हूं तो वह खाली ग्रिड को प्रदर्शित करता है, लेकिन मैं इसे में कोई पाठ के साथ लोडिंग इमेज नहीं देखता हूं। यह क्यों हो रहा है पर कोई भी विचार? आपको कोड को पोस्ट करना चाहिए जो समस्या को पुन: उत्पन्न करता है। एक अन्य उदाहरण में मैं लदान (पंक्तियों की संख्या पर स्वतंत्र) लोड करने के तुरंत बाद तालिका छुपाता ह...

wpf - What is the proper way to handle multiple datagrids in a tab control so that cells leave edit mode when the tabs are changed? -

wpf I have a tab control setup does have a data template with the data grid for each object that bind the collection of objects Happens information If I select a particular cell and puts it in edit mode, my grid will be placed on the return Detagrid go exception, except on the second tab: 'Deferr Rifesh' AddNew or EditItem transactions. It seems that cell has never left the editing mode, is an easy way to get the cell out of editing mode, or is there anything else on here? Update: It seems that I have a tab control to the data source, but instead clearly defined in each tab and then bind the data source to the content source to each source Let this problem go away. This is not really a great solution, so I still want to know how to tie the collection directly into the tab control. Update: So what I have really done for myself is to use a list view and content control in place of a tab control instead of being able to solve oneself. I use a style to make a list o...

sql server - SQL CLR trigger: name of the context DB -

I want to turn trigger triggers on / off in my SQL CLR trigger. According to me, call me EXEC sp_dboption '& lt; Name of db & gt; ',' recursive triggers', 'true' / 'false' Is there a way to know what the current DB is? On creating the trigger, I ask users to choose one, but I do not want to write it in a table. Regards, The SQLCLR trigger is being removed in which the database name There is a very easy way to find: Just make a connection to the connection connection and the database property does not require you to execute a query: -). All the SQLCLR object types (stored procedure, function, user-defined consolidated, user-defined type, and trigger) should work in: string _DatabaseName; (Using SqlConnection _Connection = New SqlConnection ("Context Connection = true;")) {_Connection.Open (); _DatabaseName = _Connection.Database; } It is! I tried it just in the SQLCLR trigger and it works very well. Keeping ...

compression - What is the best way to load a CCITT T.3 compressed tiff using python? -

I am trying to load a CCTT T.3, which is in python, and get pixel matrix from it . It should be just a logical matrix I have tried to use Pilibitif and public relations, but when I load it with them, the matrix comes back. I have read in many places that these two tools support loading of CCITT, but not reaching the pixels. I am open to changing the image, as long as I can get the logical matrix from it and can do it in Python Code. The crazy thing is that if I open one of my images in the paint, save it without any change, then try to load it with the yellowbitiff, it works paint it compresses again for LZW compression is. So I think my real question is: Is there a way that morally loads CCITT images from metric or converts the LZ into images using the illustration ?? thanks, tylerthemiler The way the dragon can not be fully used, lean on: import image import image file import subprocess quarrel = 'test.tiff' im = Image.open (quarrel) Try print 'size...

unicode - C: sscanf problem -

मेरी इस तरह एक टेक्स्ट फाइल है: 2 ए 10 5 बी 31 2 सी 6 6 मैं एक चर में पहली पंक्ति संख्या पढ़ना चाहता हूँ - और प्रत्येक पंक्ति के स्पेस से 3 सेल्स में 3 वैरिएबल की सूची पढ़ा। मैंने यह कोड लिखा है: iF = fopen (फ़ाइलनाम, "आर"); fgets (tmp, 255, तो); sscanf (tmp, "% d", & amp; अंतराल); जबकि (! फीफ (iF)) {cur = (P *) मॉलोक (आकारफ (पी)); fgets (tmp, 255, तो); Sscanf (टीएमपी, "% सी% डी% d", और नाम, और एटी, और एट); चालू & gt; jobName = नाम; चालू & gt; arrivalTime = एटी; चालू & gt; execTime = एट; ADD_TO_LIST (सिर, CUR); } यह लाइन 1,3,4 के लिए ठीक से काम करता है, लेकिन पंक्ति 2 के लिए नहीं! 2 लाइन में यह कुछ भी स्टोर करता है! जैसा कि मैंने डीबगर में जांच की है, कुछ अजीब अक्षर फ़ाइल (\ 342 \ 200 \ 252) में हैं और मैं नहीं जानता कि वे कहां से हैं! समस्या क्या है? धन्यवाद हम्म ... मुझे आखिरी रेखा, लेकिन आप यह नहीं देख पाते हैं कि आपको कहीं और समस्या क्यों होनी चाहिए। ओटोह, कम से कम जब मैं स्पष्ट रूप से समस्या का समाधान करता ह...

Need suggestions/ideas for easy-to-use but secure captchas -

To get started with , I know very well about the safety / disposable trade-off associated with the captains and There is no explanation about that. I know that recapture is the latest in captcha technology but we do not want to use it for our site to provide distortion words to our site to provide live online classes. Is a study portal for students, so users will be the student (leaving the certificate level) and the teacher. I am searching for different ideas and some good people like: - Sesame Street Solutions Asking questions that are "very easy for humans", such as "who tastes better" but how many such questions do I need to keep safe? My objective to ask this question is to get as much thoughts as possible. I think there are still many user-friendly but safe ways that I can analyze before finalizing. Please highlight the pros and cons of the method, suggesting in the context of the work of spam bot. I do not know much about my strengths...

Wordpress - Delete all tags by Post ID -

I have found a function to add a tag by post ID, but now I want to delete all the current tag for it That id before adding my new tag? - P> If you can use the direct database (PhpMyAdmin) then the fastest way is to have a SQL request. View in Codecs: Remove Warning: Obviously, modifying the database directly is dangerous. Be careful not to do this.

What is wrong with my jquery javascript here? -

So I'm trying to create a page in Visualforce (salesforce's page builder), and problems with JavaScript aspect It's been What will happen is that this section will generate a series of links. Javascript is required to click on those links I am using jquery & Lt; / Supreme: Repeat & gt; & Lt; Top: Included script value = "{URLFOR ($ resource .jquery, 'js / jquery-1.4.2.min.js')}" /> & lt; Script type = "text / javascript" & gt; Var j $ = jQuery.noConflict (); J $ (document) .ready (function () {var anchortags = j $ ('name'); for (i = 0; i & lt; = anchortags.length; i ++) {var current tag = encartag [I]; current tag trigger (click); warning ("your mother");}}); & Lt; / Script & gt; & Lt; / Supreme: Page & gt; Answer your exact question, this: currentTag.trigger (clicks) Please); should be: currentTag.trigger ('click'); But, come on, jQuery can do all this for...

coldfusion - session objects that has Arrays within Array -

I need to create a shopping cart in which many variables such as Shirts, Company, Disneynar, Names, Company, Cons_N, DSNR_Cert_Number, DSNR_Cert_Issued_Date etc. Are there. Here "Shirts, Company, Disneyer_name" are all array type variables, where "Shirts" is the main array. So I basically have to work on the array which is inside it, there are 2 different arrays with arrays in two arrays with other variables & Lt ;! --- "Cons_Code" is an important value taken from "Cons_name" and "Company_Text_Code"; Every time a user selects a new "shirt", a new key "Cons_Code" is created ---> & Lt; Cfset Cons_Code = 2 & gt; & Lt ;! --- create a structure --- & gt; & Lt; Cfset st shirt [cons_Code] = Stretton (New) /> & Lt ;! --- Assign the value of our structure --- & gt; & Lt; Cfset st shirts [cons_code] .company_Text_Code = "" / & gt; & Lt ;! --- & lt; Cfset...

Django: Loading large JSON dataset with loaddata -

I am trying to load a large dataset of approximately 76K entries generated by the dumpet command and after some time from the JSON file The process only goes with "killed" as an error message. What to do? No, I can divide the dataset by app .. All heavy data are the same table. The problem is that resource borders are killing the load before it is completed. If you can use the database remotely, you can set up a new project on the local machine on the telecommunication database, and you can perform loaddata there.

Rails -- Possible to run migration methods in generic rake task? -

I know this is not the best practice, and most likely should not be used as well, for migrations Is used, but I was wondering if it is possible to execute migration specific orders in regular RAK work. Something like this: Namespace: Working Dummy: Update = & gt; : Add Environment Addition: User, Deleted: Boolean, {: Zero = & gt; Wrong, default = & gt; Wrong} end of end thanks it is possible to run your Arbitrary proxy-migration in rack works: Namespace: Working Dummy: Update = & gt; : Environmental ActiveRecord :: Base.connection.add_column: User, Deleted ,: Boolean,: Cord = & gt; Wrong, default = & gt; If you are doing a lot of this type, use a short-hand: Namespace: Working Dummy: Update = & gt ; : Environment do c = ActiveRecord :: Base.Connect c.add_column: User, deleted ,: Boolean,: Cord = & gt; Wrong, default = & gt; Incorrect end and

key value - Redis access from MS Excel? -

I would like to use redis to query data from commandline, scripts, web and spreadsheets for all of me Good examples can be found but spreadsheets ... I do not know where to start with to enter the MS Excel spreadsheet, though. Google is failing me Please tell me how you would suggest doing this, thank you! There is a significant value datestore described for those unfamiliar redis: me Looks like I got the XL loop

JavaScript compatibility libraries -

What are JavaScript libraries that provide compatibility with particular implementation? For example, such a library can offer features in JavaScript 1.6 that are portable in different browsers. When it is available, you should take advantage of basic support for that functionality. Some frameworks, such as jQuery or Prototype, provide features that are similar in new versions of JS, but I want to cut both, I am using a standard or published version on the size of the library. And am ensuring full compliance. Is there such libraries present? There is not much on this subject in Google and Wikipedia. It seems that such a library: "JavaScript Standard Library" () it is JS 1.2 or later As much as possible to browse versions, JS is ready to provide 1.6 compatibility. I have not used it, and it is not sure how well it works. The documentation Sketchy has been written in English; This can be a sign of lack of extensive use, because otherwise someone might have correc...

c# - how to make an instance of an unknown class to use as a parameter for a method invocation using reflection? -

Well, to provide a way of grabbing all the ways from a webservice and checking them. So far we are displaying our methods and in some ways only work with entrees and stars. The part is taken care of (we can implement the method correctly and parse the results). The problem is that some parameters required for the method call are classes that are somewhere in the website Are defined and we have no way of knowing what they are. The only thing we know is that these classes are made only by wire and ints (yay) We say that the image is trying to make an example which is the "agent" Type So far I have access to the service that was loaded at runtime which is in a different class. It works just fine Proxy class: . . . Compiler parameter = new compiler parameter (assembly reference); Compiler Results Results = Provider 1 Compilation of Symphonomadom (Paramus, Unit 1); // Check for errors // To add web service method to our list of testing methods, please call. ---------...

visual studio - Automatically changing the toolbars and windows shown in different views in VS 2008 -

There is a way to automatically find the Visual Studio 2008 when the tool window is changed to see if the view is changing from To do? I'm doing the code in the view, I can see Solutions Explorer and Classroom windows, but not the Properties window. When I switch to the Design view, I do not want to have Solution Explorer or Class view, but I want the properties to come up. Visual Studio can change these things for me instead of doing it myself everytime I switch to a scene? It seems as if this facility exists or does not seem to be an easy thing to do, but I am not able to find anything about it. Maybe I have misinterpretation I am using. After Thank you for the swan for pointing me macros in your comment, and to answer I came up with a solution based on the bulk pettys' code of it, but I added an event handler for WindowActivated event where I decided what should I load the footage Private sub WindowEvents_WindowActivated (ByVal GotFocus as EnvDTE.Window, byVal L...

encoding - Proper MySQL character set/collation variables in my.cnf? -

I'm trying to completely change my site in UTF-8, so I do not have to deal with utf8_encode Is () & Amp; Utf8_decode () functions. I have a matching set of my tables properly, and I'm temporarily using query SET NAMES utf8 to override my file. My question is - in my CNF there is a ton of character sets and collation variables, and I suspect something should be left alone ... which would change me to get the effect of Should I SET NAMES utf8 ? (My tables are matching utf8_unicode_ci .) character_set_client | Latin 1 Character_set_connection | Latin 1 Character_set_database Latin 1 Character_set_file system | Binary | Character_sat_resests | Latin 1 Character_set_services | Latin 1 Character_set_system | UTF8 | Collation_connection | Latin 1_swedish_c | Collation_database | Latin 1_swedish_c | Collation_server | Latin 1_swedish_c | Well, mainly for classification, so long as you do a lnaguage Do not archive specific sorting requirements, utf8_unicode_c...

DBUS- Diff of "Service" and "Bus name" -

In DBS programming terminology, they change service names with just the name. Or is there any difference? A "bus" is a "communication world / space". You can run many buses simultaneously on the same computer: System & amp; Sessions are conservatives, private buses may also be identified by their daemon socket: "UNIX: path = / var / run / dbus / system_bus_socket" A "bus name" is a connection point It is the type of an identifier, it can be a process connection for the bus. Usually, when you address messages in "just name" some time, that name is "well known", meaning that It is registered with a second "friend" Or is it. A "service" is usually a program that starts on-demand and provides the required interface (and "well-known" "bus name", such as "org.gnome. Keyring ") But people often call" service "as" a well-known bus name that provides an...

PHP REGEX: Problem with Smiley `:)` and `:))` -

मुझे क्या चाहिए हाय! मैं : से मुस्कुरा और :) को बदलना चाहता हूं से laugh.png । समस्या स्क्रिप्ट पाता है : अंदर :)) इसलिए : यह है कि मैंने अभी तक के लिए कोशिश की है:)) नहीं दिखाया गया है : preg_replace ("/:) + (?!) / I", $ image, $ string)) कुछ अन्य regexes जो मैंने कोशिश की: "/ \: \) + (? = \)) / I" "/ \: + (? = \) \)) / मैं" लेकिन कुछ भी नहीं करना चाहता है जो मैंने अभी तक प्रयास किया। के लिए :) - (: \) (?! \))) तब के लिए :)) - (: \) \))

osx - Programmatically run at startup on Mac OS X? -

How do I programmatically programmatically run a program bundle to run on Mac OS X when a user logs in? Actually, HKCU \ Software \ Microsoft \ Windows \ CurrentVersion \ Run \ / code> equivalent to registry key in Windows. In the user's "login items" (under System preference => account = [user]) You can add application or you can add the user's ~ / library / LaunchAgents agent folder (see man launchd.plist ). Use the ~ / Library / LaunchDaemons / if your app does not have a user-facing UI According to other people, the launch gives you lots of control when the app starts, what happens if the app Ends or crashes, and the "Daemon" style app is best suited for (without us). The first option (login item) can be manipulated (linked from).

monads - Is mapM in Haskell strict? Why does this program get a stack overflow? -

निम्न प्रोग्राम सही ढंग से समाप्त होता है: आयात करें सिस्टम। यादृच्छिक यादृच्छिक सूची = mapM (\ _ - & gt; getStdRandom (यादृच्छिक आर (0, 50000 :: इंट))) [0..5000] मुख्य = रैंडम इन्स & lt; - यादृच्छिक सूची प्रिंट $ 5 ले जा रहा है चल रहा है: $ runhaskell test.hs [26156,7258,29057,40002,26339] हालांकि, यह एक अनंत सूची के साथ खिला रहा है, प्रोग्राम समाप्त नहीं होता, और जब संकलित, अंत में एक स्टैक अतिप्रवाह त्रुटि देता है! आयात सिस्टम। यादृच्छिक यादृच्छिक = सूची = एमएम (\ _- & gt; getStdRandom (यादृच्छिक आर (0, 50000 :: Int)) [0 .. ] Main = do randomInts & lt; - randomList प्रिंट $ ले 5 randomInts चल रहा है, $ ./test स्टैक स्पेस अतिप्रवाह: वर्तमान आकार 8388608 बाइट्स इसे बढ़ाने के लिए `+ आरटीएस -केस-आरटीएस 'का उपयोग करें मुझे हर बार जब मैं सूची से एक आइटम चुनता हूं, तो 5 बार ऐसा करने के बाद समाप्त होने पर मुझे लाज़िली मूल्यांकन करने के लिए कार्यक्रम की उम्मीद है getStdRandom पूरी सूची का मूल्यांकन करने की कोशिश क्यों कर रही है? धन्यवाद। ...

unix - ld can't find lib to link -

मेरी समस्या का वर्णन करने के लिए निम्न उदाहरण है: ld -Lpath1 -Lpath2 - LA -lB -Xlinker -T-Xlinker \ -W1, -rpath, / usr / local / lib -lo लक्ष्य ld: नहीं मिल सकता है -lA collect2: ld 2 बाहर निकलें स्थिति दोनों पथ 1 और पथ 2 सापेक्ष पथ हैं, और मैं पुस्तकालय ए को एलडी के पीडब्ल्यूडी के अनुसार पा सकते हैं, तो एलडी आउटपुट को इस त्रुटि संदेश क्यों मिला? क्या कोई मुझे इस समस्या को डिबग करने के लिए कुछ सुझाव दे सकता है? मुझे कुछ याद आती है, आरटी के नाम से एक लाइब्रेरी के पहले एक '' स्टेटिक '' है। आपके सुझाव के रूप में, मैं जीसीसी को लिंकिंग प्रक्रिया करने के लिए एलडी को चलाने की कोशिश करता हूं। जीसीसी एओ बो -एमबी = 64 -स्टीटिक- lrt -Xlinker -T -Xlinker ld.script -W1, -rpath, / usr / local / lib -lmemdbg -o लक्ष्य यह काम नहीं करता है। जीसीसी एओ बो -एमबी = 64 और फिर मैं "-स्टीटिक" विकल्प को हटा देता हूं, और अन्य गतिशील लिपि- lpthread के बाद (क्योंकि आरटी पथ्रेड पर निर्भर करता है जो कि "-सैतिक" को निकाल देता है)। -lrt -lpthread -Xlinker -T -X...

Android layout - Screen wont move up to allow input in EditText at the bottom -

Hopefully this is just a bit easier because I'm still wet behind the ears with the programming of Android. My problem is that I have some editing text boxes at the bottom of the layout. When they do the required work in the emulator, you touch the editor and scroll the screen so you can see the content. But when I try it on my droid inc, it comes from the Edit Keyboard. Try applying it so that whenever you add more control to any layout, it will allow you to scroll up and down. This will definitely help you understand ScrollView .