text
stringlengths
8
267k
meta
dict
Q: How to check if pid belongs to current user session? I can get the list of running process from the this source code on mac. Now, I want to filter these processes for different users or at least for current user session. A: You can just extend your code like this.. kinfo_proc *mylist; size_t mycount = 0; ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567140", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: object gets passed to action as string I have a form that has a hidden field wich stores a object. This object is a RoutesValues (I want to store a reference because when I process the form I want to redirect to a route). The action that processes the form is: public ActionResult Añadir(string userName, string codig...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567141", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: OpenGL OES Iphone glCopyTexImage2D I am new to openGL OES on iPhone and have a memory issue with glCopyTexImage2D. So far i understood, this function should copy the current framebuffer to the binded texture. But for some reason it always allocates new memory, which i can see in instruments checking the allocations....
{ "language": "en", "url": "https://stackoverflow.com/questions/7567144", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Make content go over large border I have the following rules: .borderedCanvas{ border-width: 89px 95px; -webkit-border-image: url(/images/canvas_bg.png) 89 95 repeat stretch; -moz-border-image: url(/images/canvas_bg.png) 89 95 repeat stretch; border-image: url(/images/canvas_bg.png) 89 95 repeat stre...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567148", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Setting Color Using Number in C# I can set a colors to object using Brush as follows: Brushes.Red How to apply the same using numbers, say, SetColor("#ffffff"); The above is an imaginary example. A: You can use ColorTranslator.FromHtml EDIT - In response to your comment, you can create a brush based on your colo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567149", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: naudio streaming position I'm playing mp3 file from Internet using BufferedWaveProvider in NAudio library. How can I get information about the current position and the length of the track? Is it possible? A: You can calculate the current position using the number of bytes that have been read from the Read method of...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567150", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Redirecting bad url links from external sites with .htaccess I have two inbound links that land on 404 pages because the links are squiffy. I have tried 301'ing these links as normal but without success, I believe because of the characters used from this external URL. Column<u>Radiators.html is the page suggested o...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567152", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Can I use Unicode characters in HTTP headers? Is HTTP headers limited to US-ASCII charset? Can I use unicode characters in HTTP headers? Edit: I want to do like this: WebClient myWebClient = new WebClient(); myWebClient.Headers.Add("Content-Type","یونیکد"); A: First of all, the header field in your example does no...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567154", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "14" }
Q: Don't display .pyc files in the Xcode 4 project navigator I'm working on a fairly large django-project in Xcode 4. I prefer not to see all the automatically generated .pyc files in the project navigator. Does anyone know a way to hide the .pyc files from the interface? I don't necessarily want to remove them from di...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567157", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How does List(1,2,3) work in Scala? How does this work in Scala? val something = List(1,2,3) List is abstract, and you can't construct it by invoking new List(), but List(1,2,3) works just fine. A: Because it is a call to the apply method of the list companion object. In scala, a method called apply can be called...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567160", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Using extern variables in visual studio 2010 I tried defining int GlobalVariable; in FileA.cpp and inside FileB.cpp, I tried to use GlobalVariable by declaring extern int GlobalVariable; but when I tried using GlobalVariable, I get 'GlobalVar' : undeclared identifier or some unresolved linking error, how do I go a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567161", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Wrong month name in russian I'm working on a site and my customer is from Russia. He said that the month translation in the news is wrong. For example, September: * *I get this from php: Сентябрь *and this from him: Сентября How can I overwrite this? Clarification: When using the locale ru_RU, the name of the mo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567166", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Android: Question about TTS use I'm using a TTS engine, and i want to disable the buttons until the tts message has finished, so the user can't select an option on the screen until the tts message has been listened completely. I've been trying using while (tts.isSpeaking()) { button.setclickable(false); } butto...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567170", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Use $.get() inside success: function(data) {... in $.ajax().? Can I use $.get() or $.ajax() inside of success: function(data) {... in $.ajax() ? Like: $.ajax({ url: 'ajax/test1.html', success: function (data) { $('.result').html(data); $.get("test2.php", function (data) { alert("D...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567173", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Is there a way to specify Character Spacing in SSRS/BIDS? I am trying to create a SSRS report. The report is essentially as certificate which will be printed on Custom Stationary (Some arty paper like certificates). The system we are migrating from used Word mail merge to specify the Certificate holder's name, certi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567174", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to send different sms messages to multiple recipients i have a somewhat challenging task.I have to write an application with PHP and MYSQL This application is intended to be an sms application that sends sms(text messages) to various job supervisors,reporting the messages that their subordinates have received. T...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567176", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Expand path in TreeView using view model I have dates bounded to TreeView. There is a wrapper class for date. Dates groups by years and months. Wrapper class also has IsSelected and IsExpanded properties: public sealed class DateViewModel : NotificationObject, IEditableObject { #region properties bool _isSe...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567177", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: jquery- get different page elements I want to get element attribute value which belongs to other html page. For example if I am in file a.html and want to get data like element attribute value from b.html in a.html All I am trying to do in jquery. Please suggest! I read posts but I want like below- something like-> ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567181", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: Java split string on third comma I have a string that I need to be split into 2. I want to do this by splitting at exactly the third comma. How do I do this? Edit A sample string is : from:09/26/2011,type:all,to:09/26/2011,field1:emp_id,option1:=,text:1234 The string will keep the same format - I want everything b...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567183", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: IOS: error in app purchase I use in my app a section with app purchse but when I test it I have a problem and this is my result in console: response for request product data 2011-09-26 19:14:37.601 MyApp[1233:707] Feature: puzzle, Cost: 0.790000, ID: com.mycompany.MyApp.puzzle 2011-09-26 19:14:44.973 MyApp[1233:707]...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567188", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Winforms Individually Format Double Values in ComboBox I need to individually format items in a combo box in C#/Winforms. The combo box contains a set of doubles taken from a set of objects assigned to it (e.g., 1, 1.01, 1.02, 1.03 etc.) What I need to do is format them so that the read (1.0, 1.01, 1.02, 1.03 etc.)...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567198", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: match rows that have a certain count if aggregating on another column I have a single table with these fields: Url, IP, input I would like to retrieve all Urls (and corresponding IPs) that have a different IP with different input example: Url1, IP1, input1 Url2, IP2, input1 Url3, IP3, input1 Url1, IP4, input2 Url2, ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567200", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: sql server 2008 r2 ee new query opening problem i am trying to execute a query in a newly installed sql server 2008 r2 express edition it just popup a window asking to connect to sql server compat edition , i am unable to change the server type also, how to avoid this
{ "language": "en", "url": "https://stackoverflow.com/questions/7567201", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to check for installed browsers using C# for newbies I am building an app and its a simple one, all I want it to do is display os information in plain english and the architecture as well as check for installed browsers and then I'll add the ability for it to delete cookies and what not. What Im stuck on is the ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567202", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "10" }
Q: Nested group in Orbeon xforms Please anyone let me know if group within a group works in Orbeon xforms. I have tried this but the inner group is not working. The code might look like this: <xforms:group ref=".[condition1]"> //outer group ... ... <xforms:group ref=".[condition2]"> //inner group ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567208", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Overlapping axis labels when setting base_size in ggplot2 I'm changing base_size via theme_set. When I view the resulting plot on screen, it looks great. However, when I save it as a pdf, the x-axis label is a bit too close to the axis numbers. One small thing: theme_set(theme_bw(base_size = 9)) doesn't cause any...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567216", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "5" }
Q: Display colon separated values in postgres I am using postgresql 8.1 and i dont have the new functions in that version. Please help me what to do in that case? My first table is as follows unit_office table: Mandal_ids Name 82:05: test sample 08:20:16: test sample Mandal Master table: mandal_id...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567220", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: how to merge two or more one dimensional boost::multi_array s? I want to learn how to add an one dimensional multi_array to end of another one dimensional multi_array. How would i do that? A: Boost multi-array has (not very well documented) iterators like any other container, so you can use them as normal. #include...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567226", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Hot republishing/deploying of static xhtml files issues I'm noticing a lot of issues operating the "hot deploying" of JSF pages in the following environment: * *Eclipse Indigo(latest version) *Tomcat 5.5 *JSF 1.2 *Facelets View Handler I noticed that, if I modify an already rendered xhtml page (for example ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567228", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Data can be inserted directly from SP but fails if the SP is called from the application I am trying to insert a record through my application by calling a stored procedure. When the stored procedure is executed though, I'm getting the following error: "Error converting data type nvarchar to datetime.Error convertin...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567230", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Does Xpath standard support null value in attribute for example is the following xpath string valid: /web:input_text[@value=null] which means the element doest not has a value attribute. A: This XPath returns web:input_text which don't have value attribute: /web:input_text[not(@value)] XPath /web:input_text[@val...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567231", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "6" }
Q: NHibernate and ADO.NET Connection Pooling It seems that NHibernate does not pool ADO.NET database connections. Connections are only closed when the transaction is committed or rolled back. A review of the source code shows that there is no way to configure NHibernate so that it is closing connections when the ISessi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567233", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: Get list of all sql servers installed in the system I am trying to get list of all SQL Servers installed in the machine and populate them in a drop downlist. I have searched in google and tried the following: using System; using System.Data; using Microsoft.SqlServer.Management.Smo; namespace SMOTest { class P...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567236", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Start video and play movie clip at the same time in Flash Is it possible (in AS2 or AS3) to have a button that starts a video as well as an MC at the same time? The idea being that the video will play alongside a movieclip that contains animated quotes from the dialog of the video, so syncing would be critical to. ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567237", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Trying to create a pop-up UITableView with rounded corners Been racking my brains to no avail with this one - I want to have a UITableView pop up, so it's floating over the stuff underneath, but with rounded corners. I don't know whether I need to use a clipping path in a UIView's drawRect (which I can't get to do a...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567241", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Rotating Three20 TTPhotoViewController inside TabBarController Adding Three20 TTPhotoViewController on an empty UIWindow Rotation were working like a charm. But when I moved the TTPhotoViewController to be created from UINavigationController inside a UITabBarController it does not rotate at all. I made sure I return...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567244", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "7" }
Q: Parse website in Windows Phone 7 I found that after some modification I can use Html Agility Pack for parsing websites in WP7. I can use LINQ but not XPath. I want to ask if there is some other (maybe) better way to parse websites in WP7 and if there si some tutorial. Thanks A: Scraping websites is generally a bad ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567248", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Problems with OnClickListener Hey am new to android , i just want to handle a click event , but i got problems ...thi sis my code: package karim.test; import android.app.Activity; import android.os.Bundle; import android.view.MotionEvent; import android.view.View; import android.widget.Button; public class TestAc...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567253", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: WP7 Mango RichTextBox support for copy&paste It seems that the RichTextBox control does not support copy&paste. Is it really so? I created a very simple application that had the control with some text in it and i could not select it. Are there properties that control this or it just does not work? thanks --oleg A: ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567254", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Differences with CSS positioning between IE9 and Opera, and Firefox and Opera I have a problem with a site I am doing some maintanence on, the latest test version can be found here http://www.smithandgeorg.com.au/new/ If viewed in IE7-9 or Opera this page displays as intended, however in Firefox and Safari the menu ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567256", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: VBA: Out of memory Error due to memory leak.... Can I manually call Garbage Collection? Novice programmer here. I have a code that copies 12 hours worth of data from a server and displays it in excel. My code takes the displayed code and exports it into a file, appending each 12 hours so that I can have a months wor...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567257", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: AS3 calling a global function with out 'new' or having a static method I'm creating a utility function for debugging/logs, which I access by importing the class and calling new Log(params); Alternatively I change the function to a static, and rename it to It, then I can call it by Log.It(params) I'm wondering if it ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567263", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Cant index table - MySQL server has gone away I am trying to index a field called category_id but I keep getting an error saying "MySQL server has gone away" in phpmyadmin About 100,000 rows of data. So what is the solution? Thanks A: If you have access to command line, try to index it from there not from phpmyadmi...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567264", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Statically initialized array? I was using a the reviewer "codePro Tools" by google and it flagged the flowing: new Object[] { max } with "Statically initialized array" Explanation: An array initializer is being used to initialize an array. Recommendation * *The array should be initialized dynamically. are th...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567267", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: NSSound crashing when trying to load a system sound Occasionally my Cocoa app crashes while trying to load a system sound. I've not been able to reproduce this myself, but a few users have sent me crash reports. The stack trace is always the same (see below). The app opens a modal dialog, the user clicks OK, the sou...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567269", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Can anyone tell me what 'fb:admins' could not be parsed as type 'fbid' means? I am doing my best to set up open graph on my website. It's all working ok and looking good on Facebook, but I'm getting this error message on my site: Object at URL 'http://www.thesocialnetworkingacademy.com' of type 'website' is inval...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567271", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "19" }
Q: Python: right way to build a string by joining a smaller substring N times What is the right "pythonic" way to do the following operation? s = "" for i in xrange(0, N): s += "0101" E.g. in Perl it would be: $s = "0101" x $N A: Nearly the same as Perl: "0101" * N A: The most Pythonic way would be s = "0101" *...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567275", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Is there a way to execute code dynamically in MySQL, similar to "execute immediate" in Oracle? Like EXECUTE IMMEDIATE in Oracle, is there any way to execute code dynamically in a MySQL stored procedure? I really want to use a prepared statement within a MySQL stored procedure, to generate a new SQL statement in each...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567277", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to apply Style sheet to label/textfield in iPhone? I have lots of labels in my application. Is there any way to apply common style sheet to all label rather than giving style to individual label? A: you can write a stylesheet class if you use THree20 Library by overriding TTDefaultStyleSheet. But if your need ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567280", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: STL set and map for the same user defined type I have a class for which I have defined comparison operator. Following is the code I wrote #include <set> #include <map> #include <list> template <typename _TyV> class Element { public: Element(_TyV in) : m_Label(in){} ~Element() {} ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567281", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Own drag function in AS3 I need to develop my own drag function in AS3 (instead of using startDrag) because I'm resizing a MovieClip. I'm doing this: public class resizeBR extends MovieClip { var initialScaleX, initialScaleY; public function resizeBR() { this.addEventListene...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567284", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Remove layer from renderInContext I use this code to make a screenshot, CGFloat breed = 768; CGFloat hoogte = 975; CGSize afmeting = CGSizeMake(breed, hoogte); UIGraphicsBeginImageContext(afmeting); [self.view.layer renderInContext:UIGraphicsGetCurrentContext()]; UIImage *image = UIGraphicsGetImageFromCurrentImageC...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567285", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: EF4 Hiding / Substitution of underlying fields I have a data model like this in SQL Server: table Note - varchar NoteText - tinyint PriorityLevel In my code, Entity Framework turns it into a class like: class Note - string NoteText - byte PriorityLevel Also in code I have a PriorityLevel enum which makes my code m...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567288", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: No item in ListView Hy! I load data from my Db and I will show it in a ListView. Tha problem is that no item is shown. The Listcount is 1. The list gets the data from the db. No error occures. I have no idea why. Code: public class Main extends Activity { private ListView lv; @Override public void onCre...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567291", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: ViewFlipper with only 1 layout? Following is the xml code/ layout used for my activity: <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:background="@color/white" android:layout_width="fill_parent" android:layout_he...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567293", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Why is a DispatcherTimer Tick event not occurring on time? I want to disable a button -to prevent double click: On a tablet PC you push once, it clicked twice and this is the easiest hack that I know- for a short period but I noticed/debugged the interval might be too long in practice; 50 ms vs > 2 seconds. There is...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567296", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: is possible to create a text with click action (like a Action link ) in blackberry mainscreen? This is seems like a pretty simple question. Is it possible to set a custom action for a text link (those blue texts that are underlined) inside mainscreen in blackberry. In other words, is it possible to have a handler do...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567298", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Javascript group by array content I have some problems figuring out how to group to certain variables in javascript. Here is the deal. I have one array containing categories in my case right now categories A-Z but it could be anything (Animals - dogs - cats - etc). In another array I have a result from an xml file w...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567301", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: MouseWheel event doesn't fire in SWT-AWT component I am stuck at mousewheel event that just doesn't fire. I use swt_awt bridge, so I am able to use swing component in my RCP application. I tested everything I was able to find, but with no success. Because my application is awfully complex, I created a simplified ver...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567305", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: How to make following layout with the help float,position ...if possible without setting any ht/wd of A and B divs! A and B contain transparent images which overlap the bg main div. |-------------------| | -- Main ------- | |--- ---------- ---- | |-|A| ---------|B|- | |-------------------| Thanks for respon...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567306", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: TOGAF 9: Example Implementation of Deliverables, Artifacts, and Building Blocks I am reading v9 of TOGAF and couldn't understand the illustration of Deliverables, Artifacts, and Building Blocks. Could anyone give a real example to help me understand these? A: Artifacts: Any chart or diagram, that shows an aspect of...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567311", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How to make a list of n numbers in Python and randomly select any number? I have taken a count of something and it came out to N. Now I would like to have a list, containing 1 to N numbers in it. Example: N = 5 then, count_list = [1, 2, 3, 4, 5] Also, once I have created the list, I would like to randomly select a n...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567318", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "33" }
Q: Using ActiveRecord's scope instruction to return a single result I have the following class that works fine in my unit tests but I feel it could be simpler. class License < ActiveRecord::Base scope :active, lambda { where("active_from <= ?", Date.today).order("version_number DESC") } end def current_license...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567327", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: image attach option is not coming after taking image from camera frnds,on clicking on button i open camera for taking picture ,i take picture successfull and now only two option is coming after clicking pic,"save" and "Discard",there is not any option for attaching the camera clicked image so how to attach image and...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567328", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Resubmitting the binary data into AppStore issue I am stuck at this point. Scenario is like that - I have already uploaded my application in apple Appstore and reflecting status is "Ready for sale",This is great. but there is one issue,now i want to update the binary file. How should i go around it? can anyone...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567333", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Horizontal Scrolling when Scrollview inside Scrollview I have two horizontal paging scroll views where a one is smaller and a subview of the the other. Is there a setup that consistently allows a horizontal drag to move the outer scroll view when there is no more paging to do in the inner scroll view? A: Apparently...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567334", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Linux Multiple virtual interfaces access through snmp We had configured net-snmp in a linux machine and configured around 100 virtual interfaces (eth0:x). And i could not access virtual interfaces through MIB browser. Can you guide me to discover all virtual interfaces as the part of Linux machine discovery? Thanks ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567336", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to restrict EditText to two lines in android Hi i need to restrict the EditText to two lines and i am using the following code <EditText android:layout_toRightOf="@+id/valettext" android:layout_centerVertical="true" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginRigh...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567338", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: Finding duplicates in List In a list with some hundred thousand entries, how does one go about comparing each entry with the rest of the list for duplicates? For example, List fileNames contains both "00012345.pdf" and "12345.pdf" and are considered duplicte. What is the best strategy to flagging this kind of a dupl...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567340", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Firefox automatically closing form straight away EDIT : Fixed, I just removed the tables and made it tableless, it will require abit of css to sort the layout but is working cross browser, thank you everyone. I have a really weird issue, I'm trying to do a AJAX quick order form in oscommerce. All is going well apart...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567341", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "-1" }
Q: Disadvantages of Lazy? I recently started using Lazy throughout my application, and I was wondering if there are any obvious negative aspects that I need to take into account when using Lazy<T>? I am trying to utilize Lazy<T> as often as I deem it appropriate, primarily to help reduce the memory footprint of our lo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567342", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "48" }
Q: Posting larger image on facebook How to post large image on facebook wall through iphone programmatically.I am using FBConnect API how can i acheive this. Thanks A: Facebook docs said: It is strongly recommended that you scale the image in your application before adding it to the request. The largest dimension sho...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567347", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: creating facebook fan pages I'm trying to understand open graph objects behind facebook pages. Actually I get there are basically these types of pages: * *facebook fan pages (i.e. https://www.facebook.com/HuffingtonPost https://graph.facebook.com/HuffingtonPost ) *websites fan pages og:type != "article"(i.e. htt...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567348", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: FindBugs RV_ABSOLUTE_VALUE_OF_RANDOM_INT warning I'm trying to do a code review for our project using FindBugs. we have a method to generate unique id (randomly) : public static String generateUUID(int base){ return String.valueOf(getCurrentTimeInNanos((long)base)) + String.valueOf(Math...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567350", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }
Q: Tabbing mysteriously disabled in Flash application I'm compiling a SWF using FlexSDK 4.1. I am not disabling any tab functionality. Swf is being embedded with the following via swf object: swfobject.embedSWF("Main.swf", "flashcontent", "984", "550", "10.0.0", params,flashvars, attributes, "expressInstall.swf"); E...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567356", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: android.database.sqlite.SQLiteConstraintException: error code 19: constraint failed this is the error code: 09-27 11:56:01.425: WARN/System.err(10324): android.database.sqlite.SQLiteConstraintException: error code 19: constraint failed 09-27 11:56:01.435: WARN/System.err(10324): at android.database.sqlite.SQLite...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567362", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Python: return output of ksh function On Unix, how can Iretrieve the output of a ksh function as a Python variable? The function is called sset and is defined in my ".kshrc". I tried using the subparser module according to comment recommendations. Here's what I came up with: import shlex import subprocess command...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567377", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: access a java class from within groovy I have a simple java class: package test; class Hello { public static void main(String[] args) { System.out.println("Hi"); } } on which I do a javac Hello.java Problem: Now I would like to access this class from a groovy script (access.groovy) ... import test.* Hello....
{ "language": "en", "url": "https://stackoverflow.com/questions/7567378", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "12" }
Q: C# : How to change windows registry and take effect immediately I am trying to make a application that can change registry values. I Can Change registry Values well but problem is need a restart to get it`s effect. I want to do it without restart. I want change OS registry Value like as wallpaper and others. A: Re...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567387", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: jQuery: is there a reason not to always use live() for click and other functions? I really like using .live() in jQuery for click() focus() blur() and other interaction events. I do a lot of prototyping, so I find it gives me great flexibility if I want to dynamically add elements. For that reason, I find myself dra...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567388", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "3" }
Q: How to apply constraint satisfaction problem to vertical/horizontal automated layouts? like swing and flex layouts I need to build a vertical and horizontal automated layout system. There is very little documentation on the internet about how to implement it, but I hardly found something that might help me "Constrai...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567390", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Placing Google Analytics code in Wordpress specific page I'm trying to get Google Analytics Code to work on the thank-you page after customer has filled in the contact form and I've tried putting it in the thank-you page which is in the pages under admin in Wordpress backend using HTML tab but it seems to generate u...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567391", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Why you cannot use onRelease in a class I am trying set up a simple onRelease function of a button in AS2 within a class file but this is not allowed... public function callFunction(functionString:String) { var functionItems:Array = functionString.split(","); var functionName = functionItems.shift(); var...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567394", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: match a regular expression to get attribute I'm already so desperate with this one. I need to be able to match the following pieces of text but: 1) despite of any garbage before the text staveb and 2) I need to match every <OPTION ....</OPTION> with occurence of the text staveb that means, I need to match these p...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567398", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How to add multilanguage Posts in PHPBB forum I add Multilanguage support in PHPBB forum (English/Spanish). English is default language. How I add Spanish posts. Only one editor is available for English. I already add language successfully. All forum translate to Spanish language except Post that are still in Engl...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567399", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: LazyInitializationException with OneToMany in the simpliest way I'm using Hibernate with jpa and I'm getting LazyInizializationException trying to do a very simple thing. I know what does LazyInizializationException means but I can't understand why it comes while i'm doing everything in the most common and simple wa...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567400", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: disable/enable compilation errors in Netbeans I've made the terrible mistake of telling Netbeans always to ignore compilation errors when running my Maven application. Now that I want to revoke this, I can't seem to find an option anyway in the various configuration panels. Does somebody know where this option c...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567401", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Backbone.js : repopulate or recreate the view? In my web application, I have a user list in a table on the left, and a user detail pane on the right. When the admin clicks a user in the table, its details should be displayed on the right. I have a UserListView and UserRowView on the left, and a UserDetailView on the...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567404", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "83" }
Q: create a common converter for objects from different packages I have 5 webservices, A, B, C, D, and E. Each has autogenerated objects of the exact same structure, but with different names and in different packages. com.ws.a.carA contains parameters and com.ws.a.wheelA com.ws.b.carB contains parameters and com.ws.b...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567409", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: Magento SOLR doesn't return results I am trying to integrate SOLR with Magento on my development machine. We are upgrading Magento and I want to test if SOLR is working as well. I am able to feed SOLR, the stats say that it has documents. In SOLR admin, when I put in : as query string, I do get the list of documents...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567410", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: How to detect mail client : desktop or mobile, and platform if mobile? This question is similar to Standard way to detect mobile mail client? but not sure there's a solution inside. I understand how to handle mobile format with specific, screen-size-dependent css. But what about content AND/OR images ? Case study : ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567413", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Alternative to range.getBoundingClientRect I need an alternative to range.getBoundingClientRect() for FF3.6 (XULRunner 1.9.2). I cannot update to a newer XULRunner version. Any help? A: Try looking into jQuery Plus Plus (jQuery++), specifically the Range object. http://www.jquerypp.com
{ "language": "en", "url": "https://stackoverflow.com/questions/7567414", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "4" }
Q: How to call a excel macro from .net Web service? I am trying to call a excel macro from the my web service but it is unable to initialize the Excel.Application object. This is giving error at following line: Microsoft.Office.Interop.Excel.Application oExcel = new Microsoft.Office.Interop.Excel.Application(); Even fo...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567415", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Parsing the XML to print a string with formatting attributes per word I have an XML which contains a field of the type: <mytext><![CDATA[ My name is <color value="FF0000">Bill</color>. ]]></mytext> Since I'm new to E4X methods, I wonder if there is a simple methodology (using E4X methods) in order to print the inne...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567416", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Google Chrome issue - Unable to retrive button(HTML tag) value while submitting form I have a scenario in which a button value is not being posted while submitting form in ASP.NET MVC controller. This is happening only for Google Chrome browser. For all other browsers Firefox, IE, I am getting Submit_0 value in Cont...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567424", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: How do I write Alt+Enter to a spreadsheet using PHP? I want to place Alt+Enter (line break) in a cell in an Excel spreadsheet. How do I write a character which is equivalent to Alt+Enter? A: \n is the escape-sequence for a line-break in a String. A: \n is for line break <br/>is for html break A: For Windows only ...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567432", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "1" }
Q: Slightly Distorted Bitmaps on some Android Devices I have a problem that occurs on some displays (HTC Hero, Motorola Defy, HVGA emulator) where some bitmaps are distorted in a peculiar way: The image apparently is shifted by one or two pixels, e.g. to the left, and the resulting gap on the right side is filled by du...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567435", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "2" }
Q: Javascript - emulating document.ready() on HTML object I have a main site A onto which I load content with AJAX from sub-site B. There is a jQuery file that alters elements on the site A (adds events to them, classes, re-renders them if needed etc) that is being launched on document.ready() Now I need to load conten...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567437", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: Handle Web Server with multiple clients I am working on a web application which can serve only one client.Now I need to include functionality to serve multiple clients. For that one mechanism should be there in which all the clients can see OR will be notified if any changes are done by some another client in the ap...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567462", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "0" }
Q: What is a right CLS-compliant naming convention for protected fields? I am developing a CLS-compliant types library and I have a class inside It, which contains private, protected and public fields and properties. I use underscore symbol (_) as prefix for private or protected fields and little first letter to distin...
{ "language": "en", "url": "https://stackoverflow.com/questions/7567464", "timestamp": "2023-03-29T00:00:00", "source": "stackexchange", "question_score": "9" }