text
stringlengths
8
267k
meta
dict
Q: How do I grab an image retrieved from a camera via web browser? I have an IP camera that hands me a snapshot of what it is seeing when I enter a specific url which the manual provides. The manual also states that the http response is: HTTP Code: 200 OK Content-Type: image/jpeg Content-Length: <image size> Body:<JPEG...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607492", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Sencha Touch tabPanel tabbar dynamic images In my application i am having a tabPanel. The title and icons of the tabs need to be dynamic. I am getting this data from the server. But i couldn't find any way which can load icons from a external source URL. I used the iconCls property with my custom class as .tab{-webk...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607496", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Creating a Task scheduler for Database status change In my application a registered user's profile should expire after 3 months from the registration date. I need to check and set the status of users to expired in DB every day at midnight. How can I achieve this. I think this may be done by creating a windows servi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607497", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: bind with INADDR_ANY If I bind a socket to INADDR_ANY I know that it will accept incoming connections on any of IPs configured on the server. Lets say I have 1 IP configured when I make the bind() call and then a new IP gets configured. Will be bind() accept connections initiated to the newly configured IP also or d...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607499", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: sizeof(long) in 64-bit C++ I have downloaded MinGW-64, so I can now compile 64-bit programs for Windows 7, using g++ 4.7.0 (experimental). But the following line: cout << sizeof(long) << " " << sizeof(void*) << endl ; prints 4 8, not 8 8. The documentation for g++ 4.6.0 says: The 64-bit environment sets int to 32 ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607502", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "26" }
Q: Restoring a Google Doc from Trash using Zend GData I am creating a filemanger that uses Google Docs for storage, but I am having difficulty working out how to restore a file that has been sent to the trash. I can send to trash by using this code: $resourceId = "file:12345"; $link = "https://docs.google.com/feeds/de...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607508", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: change svn file property on the fly with svnkit I need to change the value of a versioned custom property of a file in an svn repository on the fly. I do not want to alter any content, just change the value of the property of the already existing file. I am using svnkit in java. How would i go about it? example: h...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607511", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: how can i implement cross reference attacks with using jquery? i am using jQuery in my asp.net mvc site. How can i make sure the use is secure in the sense of protecting against cross site scripting / sql injection attacks? A: jQuery doesn't play much role in protecting against those kind of attacks. It's the serve...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607523", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: how to replace the number with the "image width" in vote page <form action="/votes/vote" method="post"> <% for option in @vote.options %> <%= option.name %> <%= option.quantity %> <input type="checkbox" name="op[]" value="<%= option.id %>" /><br /> <% end %> <input type="hidden" value="<%= @vote.i...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607534", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: convert php array to array Lets say I'm having the following php array Array( [0]=>a,b,c ) how can I convert it to get as result another array, what should look like Array( [0]=>a [1]=>b [2]=>c ) A: // $a = array('a,b,c'); $b = explode(',', $a[0]) A: You can simple use php explode() function for that.explod...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607538", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: How to use logrotate with cluster? How to use logrotate with cluster node.js module ? What kind of signal logrotate must send to cluster process for reopening log files ? A: This is not possible yet, it's one of the first issues of cluster: https://github.com/LearnBoost/cluster/issues/5 A: After trying it out by m...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607541", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Issue with custom tableviewcell imageview and accessory view I'm using customized tableviewcell and adding image view to the cell. When I'm trying to add accessory discloser indicator to that cell, the accessory view's background is changing to gray color(which is default). Please see this image Can any one tel...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607549", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: scanf() skip variable In C, using scanf() with the parameters, scanf("%d %*d", &a, &b) acts differently. It enters value for just one variable not two! Please explain this! scanf("%d %*d", &a, &b); A: The * basically means the specifier is ignored (integer is read, but not assigned). Quotation from man scanf: ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607550", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "25" }
Q: GDB: debugging a child process after many fork()s I'm debugging a program which repeats the typical procedure of using fork() where the child process does some delegated task as the parent calls waitpid() to wait for the child to finish and then continues. For example: while (!finished) { pid_t p = fork(); i...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607555", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Why isn't this code working? C++ This code should ask the user for a their name and then split it at the space. It should put the firstname in the variable first, and the last name in de variable lastname #include <iostream> using namespace std; int main() { char string[80]; char first[20]; char lastname[20]; bool...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607562", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: WCF XmlSerializerFormat and OperationContract: nested soap parameters serialization After reading the post XmlSerializer with specified pattern not working I try to implement such a service : OperationContract with the XmlSerializerFormat. But my Soap message contains an additional tag that is the operation paramete...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607564", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Send and receive from Socket in Android Java Hi All I have a small question. * *I have server client application Where the client will be sending data asynchronously. *The server will receive message and parse. *If server receives a wrong data it will send and error message to the client. Now my Problem is in ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607565", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Edge detection in Javascript I have a matrix (here's the plot: http://i.imgur.com/GNIWp.png) and I'd like find out, where the edges are. Here's a picture of the same plot with lines which indicate the edges: http://i.imgur.com/yffGh.png Is there any algorithm to detect these edges? A: There are plenty of fairly sim...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607568", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Hadoop: what should be mapped and what should be reduced? This is my first time using map/reduce. I want to write a program that processes a large log file. For example, if I was processing a log file that had records consisting of {Student, College, and GPA}, and wanted to sort all students by college, what would b...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607569", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Is heroku console secure? When doing and running commands in heroku console, via heroku run console. Is this a secure connection? For example, if I am editing a user's password. Will the information from my computer to the heroku console be secure / encrypted? A: Yes, heroku console works over SSH. That's why you h...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607572", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How do I remove an invitation request notification? I'm using FB.ui({method: 'apprequests', ... }) to invite a user but when the user accepts and logs into the app, the app icon still has a little red 1 on it. How do I remove this notification or even get a list of notifications? I've tried querying the graph expl...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607574", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Rebasing to new versions in upstream git (GitHub) with losing all local changes I want to have the following version structure: (my private changes to 0.1.0) - A - B - C - ... / (upstream repo) - 0.1.0 - 0.2.0 - ... \ (my private cha...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607575", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: UIWebView content resize issue in iPad I have a UIWebview in iPad. I have attached a screens shot. Please see its coordinates and the masking of its position (The web view is added to xib in portrait mode). However when I load that in portrait mode or landscape mode the content is fit to the size of the web view. Is...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607576", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: What is the scope of function within anonymous namespace in VC++? If CPP file defines namespace { void Function() { ... } } what is the scope of Function? A: File Scope. In this case Function is accessible only within the file it is defined in.
{ "language": "en", "url": "https://stackoverflow.com/questions/7607577", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What to use to store in postgresql a string with no specific upper limit? On the postgresql manual page: If you desire to store long strings with no specific upper limit, use text or character varying without a length specifier. My question is: when to use which ? Or it doesn't matter ? A: They are the same. Use wh...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607580", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Throw exception from one-way operation Assume that you have the following operation: void AddCustomer(Customer) (i.e. a Customer object as input and no output) Complying to WS-I BP 1.1 you are not allowed to define fault messages for one-way operations [1]. However, you may want to throw an exception in case, for e...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607582", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How to check if a URL is valid or not in Windows batch script I am a newbie in Windows batch scripting. I have a question though. In Windows batch scripting, how will I know if a variable is a valid URL or not? Example: Valid URL: url=https://stackoverflow.com/questions/ask Invalid URL: url=not a valid url A: Y...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607586", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How do protocols in Objective C work? Possible Duplicate: Objective-c - Purpose of categories and protocols Can anyone justify @protocol mechanism of Objective C in simple words. Like, * *Defining protocol *Implementing protocol *Other alternatives of protocol A: You can find a good introduction on protoco...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607587", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: How to autocomplete path to include file with solid prefix? in Netbeans, when I start writing absolute path to file I get autocomplete for path. e.g. when write: require_once "D:/www/" and I get autocomplete for path to file e.g.: .. project1/ project2/ file1.php file2.php But when I use constant or variable prefi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607588", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: ASP.NET remote COM port access I'm building a website in ASP.NET with backend functionality in C#. The idea is that you can connect a device to your own serial port, then go to the website to send the received data from your serial port to the website. I made a simple page which can access a serial port but after so...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607589", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: 400 Bad Request when updating DueDate or creating new task with DueDate I am trying to update dueDate for task: Task updatedTask = service.tasks.get(gTask.getTaskListGuid(), gTask.getGuid()).execute(); updatedTask.setTitle(gTask.getTitle()); updatedTask.setNotes(gTask.getDescription()); updatedTask.setDue(gTask.getD...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607590", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: MVC: Replace A ID Value (of a Foreign Key) In A View By Its Value Assume we have these two tables, binded by foreign key CAT_ID: Category[CAT_ID,CAT_NAME] cat_id = 1, cat_name= Classical cat_id = 2, cat_name = Jazz ... MusicAlbums[ALBUM_ID, ALBUM_NAME, CAT_ID] album_id = 1, album_name = Wagner - Parsifal, cat_id=1...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607592", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: php get string from binary file I have JPG image with XMP meta data inside. I'd like to read this data, but how? $content = file_get_contents($fileName); var_dump($content); displays real number of bytes 553700 but $len = strlen($content); var_dump($len); displays 373821 So, I can't simple do $xmpStart = strpos($...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607597", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: copy elision method From the standard definition of copy elision method: In C++ computer programming, copy elision refers to a compiler optimization technique that eliminates unnecessary copying of objects. Let us consider following code: #include <cstdlib> #include <iostream> using namespace std; int n=0; struct ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607598", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: MVC or MVP architecture for winform applications using Entity Framework as ORM I am going to develop a winform project of considerable size. I am planning to use Entity Framework as ORM tool. Now I am searching for an architecture(MVC/MVP/MVVM etc..) to implement all these. Firstly there are few choices for n-layere...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607599", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Does Content Security Policy block bookmarklets? Does Mozillas CSP block to execute Javascript from a bookmark by default? Can it be configured to do so? A: The behavior is specified in mozillas wiki. CSP should not interfere with the operation of user-supplied scripts (such as browser add-ons and bookmarklets). ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607605", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "22" }
Q: Error in Update query [Using String.Format] I am trying to write an update statement for inserting data from asp.net gridview to sql server 2005 database.but it is showing me an error, Please tell me how to solve. cmdUpdate.CommandText = String.Format("Update Products SET ProductName= {0},UnitsInStock={1},UnitsOnOrd...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607610", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Convert a binary number to Base 64 I know this is a pretty silly question, but I don't know what to do. I have an arbitrary binary number, say, 1001000000110010000000100100000010000011000000010001000001011000110000110000011100011100000011000000010010011000100000000000000100100000010110001100001000000111 I want to c...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607611", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: JScrollPane doesn't appear in my JTextArea This class is the layout and implementation for the first tab in my program, the CreatePanel. I am trying to implement a JScrollPane in my JTextArea. However, the scroll bar never appears, although the program compiles correctly. I've looked all over for solutions and ha...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607619", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: jquery, how to use multiple ajax requests? i have this situation inside xxx.php: <form id="s"> <input id="q"/> <input type="submit" href="Search!"/> </form> <div id="r"></div> inside the foo.php i have another form: <form id="ss"> <input id="qq"/> <input type="submit" href="Search!"/> </form> <div id="rr"></div> a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607620", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Replace for-switch loop with a Linq query I have a Message object which wraps a message format I do not have control over. The format is a simple list of Key/Value pairs. I want to extract a list of Users from a given Message. For example given the following message... 1. 200->.... 2. 300->.... 3. .... 4. 405->.... ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607629", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: writing select clause with times I would like to write a sql clause like: SELECT * FROM table WHERE orderdate < {orderdate three years after}; I tried some dateadd function, but I didn't find an example to fit just my needs. Any help? A: If you are using SQL Server: ... WHERE orderdate < DATEADD(year, 3, orderdate...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607630", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: CouchDB not updating view for upcoming and past events I have the following view on couchdb that will only return docs with a date greater than the current date like: function (doc) { var eventDay = new Date(new Date(doc.start).toDateString()), currentDay = new Date(new Date().toDateString()); if (...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607631", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Why does IE not add to my dropDown? I'm running this sample script with IE: var $select = $('#select'); var $button = $('#button'); $button.click(function() { var $option = $('<option />'); $option.text('hello'); $option.appendTo($select); }); var $tabs = $('#tabs'); $tabs.tabs(); It's pretty straigh...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607633", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to increment an auto-increment field with ADO.NET in C# I have a database table with three fields: Product(ProdId, Name, Price) Where ProdId is a auto-increment field. The auto-increment is with seed 1, starting from 0. I perform operation on the database by using C# in an ASP.NET application. If I use LINQ to I...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607635", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to get the Version Number for JBoss 7 from within a WAR? For older JBoss these mechanisms worked : * *Check for Class org.jboss.mx.util.MBeanServerLocator *Then use JSR77: Look for a JMX MBean with *:j2eeType=J2EEServer,* and get the attribute serverVersion or * *Check for an MBean with name jboss.system:...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607649", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Convert ArrayList fetched from HashMap to an Array How can i do this ? When i stored my fields in HashMap , i did it like simple Objects HashMap map = new HashMap(); map.put ("Autorul",numelePrenumeleAutorului); map.put ("Denumirea cartii",denumireaCartii); map.put ("Culoarea cartii",culoareaCartii); ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607650", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Change the color of an image in php? How can i change the color of a clipart in a image ,this image has red color heart in it http://www.tutorialpark.com/wp-content/uploads/3/Heart-Blending.jpg i want to change from red to blue in php Thanks. Mostly my images will be in png format. A: In PHP5 you could use the imag...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607657", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: TinyMCE editor fixed size with no scrollers? At the moment I have this: tinyMCE.init({ // General options mode : "exact", elements : "fkField, lkField, ukcField, khField", theme : "advanced", plugins : "table", width : "300", height: "185", // Theme options theme_advanced_buttons1 : "fontsizeselect, bold,italic,...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607659", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: unable to get log4net to use WebServiceAppender from crm 2011 I have attempted to use a log4net webserviceappender from within a crm 2011 plugin (sandboxed), log4net apparently gets installed along with the plugin correctly (exception if log4net config file is malformed), but apparently the appender doesn't get call...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607664", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Code contracts and ASP.Net Validators Imagine I have a method having a contract : public void Do(string value) { Contract.Requires<ArgumentNullException>(!string.IsNullOrEmpty(value)); MyBusiness.Handle(value); } This method is called from an asp.net 2.0 web site, and value is grabbed from a textbox, mand...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607665", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Pretty urls (friendly_id gem) with dots Many solutions are available for rails 2 but none for rails 3.1 because the map object has been removed. Any solution for this problem in the latest rails? A: I have had to do this recently on a project. Luckily, it's simple to override the slug-generating method on a per-mo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607668", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Proving Fibonacci recursive algorithm time complexity I am trying to understand a proof by induction in my algorithms text book. Here's the author is proving using induction that the T(n) will always be greater than 2^(n/2) (This is for calculating the nth fibonacci number using the recursive algorithm): What I don...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607671", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: HTML5 WebSQL: how to know when a db transaction finishes? I've the following code that gets a json recordset and insert some data in three different tables on the client Web Sql storage. How can I intercept the end of databaseSync() function? What I want to do is display an alert or better an ajax spinner gif in ord...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607677", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: Pen input in Android tablet I want to use pen in android tablet . I use pen and want to write text with pen. How can I develop the android application to be accept only pen input in EditText . Can I use pen in emulator ? Is there any usable API for this .? A: As far as I know, only HTC supports a pen on some their ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607680", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Getting user specified information from URL in Objective C iOS Currently I am working with a UIWebview which shows web content provided from a user. In this content there will be links to other web content and I need to decide whether to open links in safari or in the UIWebview. My current solution is to add a query...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607681", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Is using JPA/ORM to generate a db schema a bad idea? Salve! Part of another question/answer on SO (as well as other statements claiming the same): if you are updating your database schema by JPA (generally not a good practice though) Is it true that you should not use a JPA implementation to generate your db schem...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607683", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: How can i create a my own custom button without using interface builder? I want to create my own custom button without using any interface builder. Actually i wants to set all my properties/attribute(Like frame,color,size,label etc.) separate in a NSObject class.Then from my UIView class i want to draw them . How ca...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607686", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-2" }
Q: Selenium Script For IE I got this error , while running selenium script for Internet Explorer 9. Exception in thread "main" org.openqa.selenium.WebDriverException: Unexpected error launching Internet Explorer. Protected Mode must be set to the same value (enabled or disabled) for all zones. (WARNING: The server d...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607694", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: binary propery in EF4 with mysql -- datatype I am using mysql together with EF4 and VS2010. I am using model first and uses the Generate database from model function to create the database. Problem is that the binary properties in the model is converted to varbinary(100). I need them to be converted to MEDIUMBLOB. ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607696", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Can't use "acts_as_url" in ruby on rails 3 I'm newb and I'm sorry because of my dumb question! Please, help me!! I'm working with Rails 3, and this my problem: I have a model name: Photo using gem 'mongoid'. I want to make a permalinks which are readable url instead of unreadable '_id' generated from mongoid! After ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607700", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: @WebServlet annotation and error 404 First of all: I use GlassFish 3.1 + Eclipse Java EE indigo. I want to testing cache solutions with javaee so I made a dummy app. I have a big generated database and I list, search, modify, etc some data. To do that I wrote some basic servlet and I call with GET parameters. e.g.: ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607701", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: How can I force Vaadin v8 to update the screen? I have a small Vaadin v8 application that has several input fields (comboboxes, selectgroups, etc...). The content of most of these is determined by the chosen content of the first ComboBox. However, when I select something in it, all the others stay blank until I clic...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607702", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "17" }
Q: How to make the JInternalFrame of the specified size? I have a JFrame. I have added menu-bar to it. I have set its size and location using following line. frmMain.setBounds(0, 0, 1024, 768); // JFrame Next I have added a JInternalFrame to the code for JInternalFrame as follows: ifActivateProject=new JInternalFra...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607704", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: WP7 (windows phone 7) How to zoom with the PhotoCamera? I'm using the PhotoCamera for an AR app and I was thinking that a zoom in/out function would be a nice one. But I can't figure out how to do it. There is no zoom method in the PhotoCamera Class. Does anyone have a lead on how to do it ? A: I've trying to figu...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607706", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Generate object model out of RelaxNG schema with RNGOM - how to start? I want to generate an object model out of an RelaxNG Schema. Therefore I want to use the RNGOM Object Model/Parser (mainly because I could not find any alternative - although I don't even care about the language the parser is written in/generates...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607715", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Can I reference an external JavaScript file in a PHP file? I cannot seem to get this to work. I have a small JS file that switches banners depending on the time of day, but it seems that doing an external reference in my PHP file does not work. It works fine in an HTML page. This is the code in the JavaScript file. ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607716", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: XCreateGC function performance I've a problem with XCreateGC function performance. It seems that works normal(fast) in several cases, and very slow in other cases:). For more details, please look on this code: void some_function(int dx, int dy, int sx, int sy, int w, int h, Drawable src, Drawable mas...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607728", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Delete GWT module development mode? I have a GWT application with several modules. I have deleted one that I don't need anymore (JasperReportTest) - I deleted JasperReportTest.gwt.xml file and classes referring to that module. But when I try to run my application in development mode I get this in my console: Loadin...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607734", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: .gitattributes not making a difference, trying to skip files when using git difftool I've read the Git Pro website and I've read multiple answers on StackOverflow, but sadly I am simply unable to make .gitattributes work for me. Whenever I'm using git difftool, it will attempt to display the difference between binar...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607739", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "10" }
Q: Does Facebook actually support OAuth 2.0? I've already succesfully implemented LinkedIn and Twitter Oauth 2.0 authorization in my App with external libraries. But I have problems with Facebook. It seems like it has different authorization flow. I need to have 3 endpoints to implement OAuth: request token url, access...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607741", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: What is the difference between Object-Graph and a class diagram? Is there a difference in the meaning of "class diagram" and "object graph"? A: see this tutorial http://www.cs.toronto.edu/~jm/340S/Slides6/ClassD.pdf Object graph contains value of one instance of class see example View its a view of an object syste...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607743", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How do you make a subdomain route for every action in a Zend Framework controller? Using Zend Framework I want to use an account name (:account) as the subdomain that will call the basket controller. When using getParams() for the index action it does display the :account parameter but this does not work on any othe...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607758", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Mysql From enum to tinyint problems I've got a table with `terms_of_payment` enum('0','1') NOT NULL DEFAULT '0' COMMENT '' I run ALTER TABLE `customer` CHANGE `terms_of_payment` `terms_of_payment` TINYINT( 1 ) NOT NULL DEFAULT 0 COMMENT ''; and I found all my customers (with '0' value) set to 1 when I'm wai...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607763", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: How do you modify IDEA IntelliJ v10.x code generators for getters and setters? IntelliJ generates the following getter/setter code for boolean fields: private boolean isTest; public boolean isTest() { return isTest; } public void setTest(boolean test) { isTest = test; } This too yields ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607767", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How to install XML::Twig for Windows XP I tried installing XML::Twig using ppm and also tried manually by adding twig.pm files in the perl/lib folder, also tried using Nmake but got an error "NMAKE : fatal error U1073: don't know how to make 'C:\Documents' Stop." How do I install it? A: The best solution I've f...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607772", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Hide author bio I have to convert a PSD to (x)HTML for a client of mine witch in turn will use that theme for a client of him. Now the question is, is there a way to protect my copyrights from within the page for copyrights like ? In example, is there a way to leave somethink like that into the code and protected fr...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607773", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: java/jsf strange error: WARNING: StandardWrapperValve PWC1406: Servlet.service() ... threw exception java.lang.NullPointerException I have simple jsf app with servlet for dynamic images and filter setting utf8 encoding. From time to time (1/10 requests) I get very strange error: WARNING: StandardWrapperValve[com.web...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607780", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Better way to return the value from a property from a child object when the childobject can be null I try to explain this with an example: public class Player { public string FirstName {get; set;} public Team Team {get; set;} } public class Team { public string Name {get; set;} } Now I want to map a Pl...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607782", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to use foreign keys in SQL Buddy? I need to use foreign keys for update and cascade, etc. ALTER TABLE topics ADD FOREIGN KEY(topic_by) REFERENCES users(user_id) ON DELETE RESTRICT ON UPDATE CASCADE; but I am not able to make foreign keys in SQL Buddy. Any way to do that? A: did you try this : ALTER TABLE...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607784", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Outlook 2003 VBA to detect selected account when sending Is it possible to detect which account an email is being sent via the Application_ItemSend VBA function of Outlook 2003? The accounts are POP3/SMTP on a standalone machine, and not MAPI or Exchange based. I have tried using "Outlook Redemption" (http://www.di...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607790", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Can't create a PDF with iText and JSF I want to create a pdf using iText in my JSF + Spring web app. When I click on a button the pdf should be generated. The method that is fired: public void createPDF() { log.debug("entered createPDF"); FacesContext context = FacesContext.getCurrentInstance(); HttpSer...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607795", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Jqgrid ui autocompletion : Disable Case sensitivity In my JQgrid i have a ui atocomplete column which are Case sensitive. For example i have 2 Items in my grid: Ivan and ivan, if i type "i" autocomplete will return only ivan. I have tryed to make a function inside of source: but i failed since my ajax call always ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607798", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Redirect from old site and subsites to new domain - main page with htaccess I have the following rules in my .htaccess rewritecond %{http_host} ^oldname.com [nc] RewriteRule ^(.*)$ http://www.newname.com [r=301,nc] rewritecond %{http_host} ^www.oldname.com [nc] rewriterule ^(.*)$ http://www.newname.com [r=301,nc] I...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607800", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: EditText formatting Now I've got an EditText with TextWatcher which formats user input as a phone. For example if users input is 89011234567 it will be formatted as +7 (901) 123-45-67. I wonder is there any way I can extend or implement some classes like CharSequence or Editableor any other like these to make EditTe...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607801", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to pack OGG audio file to RIFF container? I have an ogg audio file and some information which is saved as sequence of bytes. I need to pack this audio and information in a single container such as RIFF or something else. I'm searching solutions which can be written under .NET. A: Ogg is a container format. What...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607802", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How do I get a ContentItem's content in Orchard? I have instance of ContentItem and I'd like to get the contents of it. How do I do this? A: Say that your type is named Contact, has a BodyPart, and has a text field name Subject. If you are inside a content template like Content-Contact.cshtml, you can access the co...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607804", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Flash As2 Image snapshot Is there any approach to take the snapshot of a drawing created in pure AS2 flash coding ? I tried to use Bitmapdata and bridge but bitmap works in as3 and bridge combines two swf together and communicate with them. Is there a way of doing screenshot in as2 ? A: Yes, it can be done in AS2,...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607805", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Multiple domains and subdomains on a single Pyramid instance I'm looking to have multiple domains and subdomains on a single Pyramid instance. However, I can't seem to find any documentation on it. The last question referred to a glossary with very little information and no examples. Do any of you have any examples ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607807", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "14" }
Q: jQuery UI, draggable child div larger than parent I have looked over several articles and tried all of the methods proposed and found no solutions as of yet. I am attempting to create a map that is draggable, but will stop when it its own edge meets the edge of the parent's edge. The child is larger than the parent ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607808", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: mismatch in constructors/destructors count Possible Duplicate: C++ basic constructors/vectors problem (1 constructor, 2 destructors) I have got the code: #include <iostream> class A { public: A() { std::cout<<"A::A"<<std::endl; } ~A() { std::cout<<"A::~A"<<std::endl; } }; class B : public ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607819", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Masking or hiding inaccurately entered data in SQL Server 2008 OK, so my subject line isn't very descriptive, but here's the scenario: An end-user has a legal obligation to submit transaction data to a government agency. The transactions contain the name and address of various individuals and organizations. HOWEVER,...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607830", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Perl memory leak from match operator While investigating a long running perl program for memory leaks I tried to use Test::LeakTrace. Looking at one of the leaks it reports I can narrow down the leaking code to just: /$?/ So running: perl -MTest::LeakTrace::Script -e'/$?/' prints: leaked SCALAR(0x10d3d48) from -e l...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607831", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Android - Passing the main activity around I have a several activities in my app. The main activity (activity1) extends ActivityGroup (I need to support 2.2 and above, so I cant use fragments). The main activity1 creates activity2, which in turn creates activity3. But when creating activity3 I want activity1 to cre...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607840", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: ASP.NET MVC 3 in-memory data store I have a project which provides users with a list of current tasks that need to be completed. Any user can complete any task, and so to ensure that only one user is working on a task at a time I need to be able to 'lock' it. I'm using SignalR for this, so a user requests a lock on ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607841", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Exchange server search from android email I am trying to search exchange server mailbox by the following command from a android client. <Search> <Store> <Name>Mailbox</Name> <Query> <And> <Class>Email</Class> <CollectionId>5</CollectionId> <Fr...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607842", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: PHP Update giving error if no data is edited Thanks for asking me to make my question clearer. I have a form which is used to save content in a database. The user is also allowed to update any content by editing the fields in the form and submitting it. The update query looks something like this:- $res = mysql_qu...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607844", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: sql nested select parsing Situation: I have several SSRS reports of which I need the sql-code to be documented. For this I need the code to be formatted in exactly the same way time and time again. Problem: In some of my reports I have structures like select outer from ( select outin from ( select inner from ( selec...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607848", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to give priority to a jar file in eclipse classpath? There is a class file TagAttributeInfo which is under two of my jar files. j2ee-6.1.jar,servlet-api-2.3.jar . Now i need that class to be called from j2ee-6.1.jar but in runtime ,it is taking the class of servlet-api-2.3.jar,which i don't want. Can anybody he...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607849", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "8" }
Q: Pascal's Triangle returning nonsense values This is a homework project I was assigned some time ago... I've been successful in getting this far on my own, and the only hiccup I have left is (I believe) an issue with data types and overflow. I've tried changing over to unsigned and double, and the code complies and s...
{ "language": "en", "url": "https://stackoverflow.com/questions/7607850", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }