Id
int64
1.68k
75.6M
PostTypeId
int64
1
2
AcceptedAnswerId
int64
1.7k
75.6M
ParentId
int64
1.68k
75.6M
Score
int64
-60
3.16k
ViewCount
int64
8
2.68M
Body
stringlengths
1
41.1k
Title
stringlengths
14
150
ContentLicense
stringclasses
3 values
FavoriteCount
int64
0
1
CreationDate
stringlengths
23
23
LastActivityDate
stringlengths
23
23
LastEditDate
stringlengths
23
23
LastEditorUserId
int64
-1
21.3M
OwnerUserId
int64
1
21.3M
Tags
list
6,186,562
1
6,186,701
null
1
68
Could you tell me what is the circled element no.1 on this image? The one that look like a submenu, but it seams it's not a submenu. What does the logo in the top left corner mean? ![screenshot](https://i.stack.imgur.com/G9Uqd.png)
Can you explain the elements on this image
CC BY-SA 3.0
null
2011-05-31T11:01:37.990
2011-05-31T11:11:39.357
null
null
437,039
[ "android" ]
6,187,337
1
6,188,305
null
5
2,096
I have identified a strange problem in Internet Explorer and Chrome: I have a simple HTML table with no layout CSS, 2 columns, no styles, and width set to 100%. When I attempt to print this table in Internet Explorer (all versions) and Chrome, the first cell on the 2nd page and later is dropped. Snippet of the HTML: ``` <html> <head></head> <body> <table width='100%' cellspacing='0'> <tr><td align='left'>Date</td><td align='left'>Order No.</td></tr> <tr><td align='left'>5/24/2011</td><td align='left'>287426</td></tr> <!-- SNIP :: Many more rows --> </table> </body> </html> ``` The entire table can be found at: [https://gist.github.com/1000367](https://gist.github.com/1000367) The output in the Print Preview on Internet Explorer, for page 2 looks like: ![Missing first cell](https://i.stack.imgur.com/HEEYO.png) I have added the colored lines and circle to highlight that the left cell is missing. Any ideas? I've tried adjusting cellpadding and margins on the outside of the table, with no luck. As suggested, I have also added the following css rules with no effect: ``` BODY { margin: 0px; padding: 0px; } ```
Print of HTML table drops cells in first column
CC BY-SA 3.0
0
2011-05-31T12:06:52.187
2015-10-01T17:38:21.073
2011-05-31T12:36:49.007
29,156
29,156
[ "html", "printing" ]
6,187,358
1
6,189,733
null
1
450
I'm having some performance problems with images in my app. I assign a UIImageView to the backgroundView property of a UITableViewCell. The Time Profiler instrument tells me that I'm spending most of my time here: ![enter image description here](https://i.stack.imgur.com/clR3E.png) My table view has semi-transparent cells to let the background shine through. I know this is not good. But from what I can tell from the Profiler, this is not the bottleneck, right? png_read_filter_row sounds like if there is some kind of expensive filtering going on. Also down the bottom, there are 10.6% spent on transform_premul_argb_fn ... which sounds like some kind of scaling. My images are not scaled at all. I use them naturally (i.e. if the display needs 200 x 100, it gets 200 x 100. If it's retina, it gets a 400 x 200 version). And finally, 6.7% on gzopen which sounds strange. My images reside in the Documents directory, not in the zipped App Bundle. Maybe someone with deep Core Graphics knowledge can tell what those calls mean and how to avoid them?
How to avoid calls to png_read_filter_row and transform_premul_argb_fn in Core Graphics?
CC BY-SA 3.0
0
2011-05-31T12:08:48.137
2012-03-06T01:04:11.407
null
null
472,300
[ "iphone", "ios", "performance", "ipad", "core-graphics" ]
6,187,728
1
6,187,888
null
5
17,109
I'm kind of stuck on this one, I know it can be done but unsure the steps needed. I want to create a fully custom User Interface design for an application I'm having to create. I can change the form background and all that but this is a bit more complex. An example image is shown below of the kind of change I'm referring to, as you can see its a rather big change compared to the current UI used by most applications. ![Example UI image](https://i.stack.imgur.com/7aRFq.jpg)
Custom C# Form Design
CC BY-SA 3.0
0
2011-05-31T12:42:19.190
2021-09-13T19:06:21.357
2021-09-13T19:06:21.357
2,756,409
767,561
[ "c#", "winforms", "user-interface" ]
6,187,828
1
6,187,887
null
7
9,310
Here's what I have so far. When the phone is vertical: ![enter image description here](https://i.stack.imgur.com/JVxYG.png) When the phone is horizontal: ![enter image description here](https://i.stack.imgur.com/hsEnA.png) Here's my XAML markup: ``` <StackPanel Margin="19 0 19 5"> <Grid> <Grid.ColumnDefinitions> <ColumnDefinition Width="110" /> <ColumnDefinition /> </Grid.ColumnDefinitions> <Image Grid.Column="0" Source="{Binding ImageUrl}" Stretch="Uniform" Margin="0 10 0 10"/> <StackPanel Grid.Column="1" Margin="14 0 0 0"> <TextBlock Text="{Binding Title}" FontSize="30" /> <TextBlock Text="{Binding ReleaseDate}" FontSize="22" Foreground="#E0A655"/> <TextBlock Text="{Binding Synopsis}" FontSize="22" TextWrapping="Wrap"/> </StackPanel> </Grid> <Line StrokeThickness="4" Stroke="#434343" X1="0" X2="350" Y1="13" Y2="13" /> </StackPanel> ``` I'd like a line that is the same width as it currently is, but centered. But also when the phone is horizontal, the line should be a bit bigger to address the wider space available to it. Is this possible?
How can I draw a horizontal line and center it?
CC BY-SA 4.0
null
2011-05-31T12:50:33.890
2018-09-23T14:52:37.033
2018-09-23T14:52:37.033
1,033,581
699,978
[ ".net", "xaml", "windows-phone-7", "line" ]
6,187,950
1
null
null
1
621
How to show Background image in UITableView Like ![enter image description here](https://i.stack.imgur.com/ipNO0.jpg) Please help me out. Thank you
Background on UITableView?
CC BY-SA 3.0
0
2011-05-31T13:00:43.530
2014-07-20T23:11:21.597
2011-05-31T13:07:33.170
491,980
532,445
[ "iphone", "xcode", "uitableview" ]
6,188,058
1
6,190,009
null
3
756
I have been working through building a module for Orchard; based upon the [N-N relationship tutorial](http://www.orchardproject.net/docs/Creating-1-n-and-n-n-relations.ashx). After getting the project working once I went through and changed the namespace, various classes and variable names as I had made various assumptions about names that did not pan out. Since this renaming exercise the Module ("Definition List") shows up twice in the modules dashboard: ![Screenshot of Modules Dashboard](https://i.stack.imgur.com/gth2a.png) Here is my module.txt: I can't think of anywhere in the project that would specify a different category. Migrations.cs: ``` public class Migrations : DataMigrationImpl { private readonly IRepository<DefinitionRecord> _definitionListRepository; private readonly IEnumerable<DefinitionRecord> _sampleRecords = new List<DefinitionRecord> { new DefinitionRecord { Term = "Term A", Definition = "This is the definition for Term A" }, new DefinitionRecord { Term = "Term B", Definition = "This is the definition for Term B" }, new DefinitionRecord { Term = "Term C", Definition = "This is the definition for Term C" } }; public Migrations(IRepository<DefinitionRecord> definitionListRepository) { _definitionListRepository = definitionListRepository; } public int Create() { SchemaBuilder.CreateTable("DefinitionListPartRecord", table => table .ContentPartRecord() ); SchemaBuilder.CreateTable("DefinitionRecord", table => table .Column<int>("Id", column => column.PrimaryKey().Identity()) .Column<string>("Term") .Column<string>("Definition") ); SchemaBuilder.CreateTable("ContentDefinitionRecord", table => table .Column<int>("Id", column => column.PrimaryKey().Identity()) .Column<int>("DefinitionListPartRecord_Id") .Column<int>("DefinitionRecord_Id") ); ContentDefinitionManager.AlterPartDefinition( "DefinitionListPart", builder => builder.Attachable()); if (_definitionListRepository == null) throw new InvalidOperationException("Cannot find the Definition List Repository"); foreach (var entity in _sampleRecords) { _definitionListRepository.Create(entity); } return 1; } } ```
Duplicate module entry in Orchard CMS Modules Dashboard
CC BY-SA 3.0
null
2011-05-31T13:08:37.747
2013-04-19T03:54:19.610
2011-06-14T19:41:59.240
629,335
74,302
[ ".net", "asp.net", "asp.net-mvc", "asp.net-mvc-3", "orchardcms" ]
6,188,274
1
6,201,263
null
2
1,058
## Intention I have a `java.applet.Applet` subclass `MyApplet` with a `java.awt.Canvas` subclass `MyCanvas` added to it. My code changes the size of `MyApplet` to `new Dimension(600,400)` and changes the size of `MyCanvas` to match. When `MyCanvas` is `paint`ed, it should 1. fill its whole area with red 2. draw a blue circle of width 300 and height 300. ## Problem Instead (when run as a Java Applet from Eclipse), the paint of `MyCanvas` clips to a far smaller area than 600,400 (I measured it to be 195,200) even though `MyApplet` resizes correctly. [This is what it looks like.](http://dl.dropbox.com/u/196227/MyAppletContents.png) ![enter image description here](https://i.stack.imgur.com/8AApg.png) The printouts are OK too -- see bottom of post. ## Code This is my code: ``` import java.applet.Applet; import java.awt.Canvas; import java.awt.Color; import java.awt.Graphics; public class MyApplet extends Applet { Canvas mainCanvas; public void init() { // Set the size of the applet setSize(600, 400); // Print dimensions System.out.println("Applet dimensions: " + getSize()); // Make a canvas with the same sizes as this applet mainCanvas = new MyCanvas(getWidth(), getHeight()); add(mainCanvas); } public class MyCanvas extends Canvas { public MyCanvas(int w, int h) { setSize(w, h); System.out.println("Canvas dimensions: " + getSize()); } public void paint(Graphics g) { g.setColor(Color.RED); System.out.println("Canvas dimensions when painting: " + getSize()); g.fillRect(0, 0, getWidth(), getHeight()); } } } ``` ## Printouts It produces the following printout: ``` Applet dimensions: java.awt.Dimension[width=600,height=400] Canvas dimensions: java.awt.Dimension[width=600,height=400] Canvas dimensions when painting: java.awt.Dimension[width=600,height=400] Canvas dimensions when painting: java.awt.Dimension[width=600,height=400] ``` The sizes are correct throughout! ## Attempted solutions - `setBounds()``setSize()``MyApplet``MyCanvas` Am I missing something?
Java Applet painting clips to [195,200] despite resize
CC BY-SA 3.0
null
2011-05-31T13:24:28.110
2011-06-01T12:37:51.367
2011-05-31T14:17:38.043
418,556
777,586
[ "java", "eclipse", "canvas", "applet", "clip" ]
6,188,438
1
6,189,857
null
1
3,538
``` <div dojoType="dijit.Dialog" id="errorDialog" title="An error occured" style="display: none"> <p id="errorMessage">An unexpected error occurred</p> <button dojoType="dijit.form.Button" type="submit" onClick="hideErrorDialog();"> OK </button> ``` Can I add an image to a dojo dialog? to to make it appear like an alert box or something? Above is my current code? Something like ![enter image description here](https://i.stack.imgur.com/Xaefw.jpg)
Add an image (alert) to DOJO dialog
CC BY-SA 3.0
0
2011-05-31T13:37:57.803
2011-05-31T15:23:23.567
2011-05-31T13:45:13.373
39,278
39,278
[ "dojo" ]
6,188,669
1
6,191,281
null
0
814
![this is the sample for our project](https://i.stack.imgur.com/xXWJc.png) this is what my project need for multiple file uploader control, is there any control can do the same thing as it?
Is there any multiple file uploader control in asp.net (just the same as pre-image)?
CC BY-SA 3.0
null
2011-05-31T13:55:19.050
2011-05-31T17:33:15.363
null
null
680,297
[ "jquery", "asp.net", "multifile-uploader" ]
6,188,958
1
6,189,292
null
1
1,564
So I'm doing one of the Princeton exercises here: [http://www.cs.princeton.edu/courses/archive/fall10/cos126/assignments/lfsr.html](http://www.cs.princeton.edu/courses/archive/fall10/cos126/assignments/lfsr.html) and I've fully tested by LFSR class with the data that has been provided, so I'm sure I haven't gone wrong there. However, my PhotoMagic class yields an encrypted photo of the pipe as below: ![Encrypted photo of the Pipe image](https://i.stack.imgur.com/w6YFo.png) This is not how it should appear. Any idea as to where my code has gone awry? ``` import java.awt.Color; public class PhotoMagic { private LFSR lfsr; public static void main(String args[]) { new PhotoMagic("src/pictures/shield.png","01101000010100010000",16); } public PhotoMagic(String imageName,String binaryPassword,int tap) { Picture pic = new Picture(imageName); lfsr = new LFSR(binaryPassword,tap); for (int x = 0; x < pic.width(); x++) { for (int y = 0; y < pic.height(); y++) { Color color = pic.get(x, y); int red = color.getRed(); int blue = color.getBlue(); int green = color.getGreen(); int transparency = color.getTransparency(); int alpha = color.getAlpha(); int newRed = xor(Integer.toBinaryString(red),paddedBitPattern(lfsr.generate(8))); int newGreen = xor(Integer.toBinaryString(green),paddedBitPattern(lfsr.generate(8))); int newBlue = xor(Integer.toBinaryString(blue),paddedBitPattern(lfsr.generate(8))); Color newColor = new Color(newRed, newGreen, newBlue); pic.set(x, y, newColor); } } pic.show(); } /** * Pads bit pattern to the left with 0s if it is not 8 bits long * @param bitPattern * @return */ public String paddedBitPattern(int bitPattern) { String tempBit = Integer.toBinaryString(bitPattern); String newPattern = ""; for(int i = 1; i < 9-tempBit.length(); i++) { newPattern += "0"; } newPattern += tempBit; return newPattern; } /** * Performs the bitwise XOR * @param colorComponent * @param generatedBit * @return */ public int xor(String colorComponent, String generatedBit) { String newColor = ""; for(int i = 0; i < colorComponent.length(); i++) { if(colorComponent.charAt(i) != generatedBit.charAt(i)) { newColor += 1; } else { newColor += 0; } } return Integer.valueOf(newColor,2); } ``` }
Can't figure out the bug in this code
CC BY-SA 3.0
0
2011-05-31T14:18:18.907
2016-03-18T14:31:25.670
null
null
741,898
[ "java", "image", "encryption", "feedback" ]
6,189,117
1
null
null
0
496
I'm looking to implement some tooltips that will show quick tips to users on a web app. They will need to shown only once and can be turned off from a users preferences. Anyone developed anything like this before? Looking for some ideas/suggestions for how to implement such functionality... Flow has a good implementation of them as does Facebook: ![enter image description here](https://i.stack.imgur.com/aGOFJ.png) ![enter image description here](https://i.stack.imgur.com/GBcpA.jpg)
Quick Tips/Tooltips
CC BY-SA 3.0
null
2011-05-31T14:29:15.567
2013-04-30T13:49:26.830
2011-05-31T14:41:01.590
302,533
302,533
[ "jquery", "tooltip" ]
6,189,327
1
null
null
5
3,210
Does anyone knows any good tool for drawing correlation heat maps for WPF? Example based on comments: ![enter image description here](https://i.stack.imgur.com/ycg8d.png) Original image [source](http://lcchong.files.wordpress.com/2011/05/image_thumb.png?w=644&h=206)
Correlation heat map for windows presentation foundation
CC BY-SA 3.0
0
2011-05-31T14:43:22.807
2016-11-19T00:44:54.203
2011-05-31T15:59:29.850
636
777,868
[ "wpf", "visualization", "data-visualization", "heatmap" ]
6,189,329
1
6,194,327
null
1
1,219
![I've attached an image of the error message I am getting. At first my date drop down select for users birthday was working fine. But I finally installed and enabled the intl extension that symfony2 was asking for and now I get that error message. Any idea what the problem could be?](https://i.stack.imgur.com/tkw8e.png) Here is my controller: ``` <?php namespace Home\JoinBundle\Controller; use Symfony\Bundle\FrameworkBundle\Controller\Controller; use Home\JoinBundle\Entity\User; class DefaultController extends Controller { public function indexAction() { $user = new User; $user->fname; $user->lname; $user->bday; $form = $this->get('form.factory') ->createBuilder('form', $user) ->add('fname', 'text', array('label' => 'First Name: ')) ->add('lname', 'text', array('label' => 'Last Name: ')) ->add('bday', 'birthday', array('input' => 'array', 'widget' => 'choice')) ->getForm(); return $this->render('HomeJoinBundle:Default:index.html.twig', array('form' => $form->createView())); } } ```
PHP error message on form after enabling intl.so extension
CC BY-SA 3.0
null
2011-05-31T14:43:25.193
2012-08-05T09:12:46.687
2012-08-05T09:12:46.687
569,101
439,688
[ "php", "frameworks", "symfony", "intl" ]
6,189,472
1
null
null
7
905
I have a curved div created with css3 border radius (the image part). I have text lines next to it that I would like to align 20px or so off the curve, like so (cant post images, cant remember old login): ![enter image description here](https://i.stack.imgur.com/cQ6rh.jpg) The trick is the curve changes depending on the window size, so I'd like to be able to calculate the points on the curve that the text should offset from, essentially creating a really manual text-wrap. Ultimately I need to be able to calculate and update with javascript. (edited to add per comment below): The curve css for purposes of demonstration is border-bottom-left-radius: 316px 698px; but that is calculated based on page size by a script. Also, good to mention, is I have no requirement to support IE or FireFox at all--just webkit (standalone kiosk application).
How to calculate points on a curve that matches CSS3 created border radius? Geometry geniuses?
CC BY-SA 3.0
0
2011-05-31T14:54:00.903
2012-04-15T15:16:11.547
2011-05-31T20:04:50.373
777,889
777,889
[ "javascript", "geometry", "word-wrap", "curve" ]
6,189,573
1
null
null
2
102
We have a CalendarTimeUTC Dimension table in our Data Warehouse that looks like this: ![enter image description here](https://i.stack.imgur.com/oSClM.jpg) The PK in the table is the CalendarTimeUTCId (clustered). This used to be a Int field. All fact tables have CalendarId in them (some of these are multi-billion row partitioned tables). We want to go from putting a DATE value to DATE+HOUR value in this field. Sample data (Old and New): ![enter image description here](https://i.stack.imgur.com/4j9PE.jpg) Now with the advent of SQL 2008, and the shiny new implementation of DATETIME, is there a reason to switch the dimension's ID column from INT to DATETIME? How will it affect the Index Size in the fact tables? More importantly, how will it affect performance?
Is the new Date better than the old Date?
CC BY-SA 3.0
null
2011-05-31T15:01:59.200
2011-06-15T09:56:17.987
2011-06-01T11:27:38.233
109,035
109,035
[ "sql", "performance", "sql-server-2005", "sql-server-2008-r2" ]
6,189,727
1
6,293,901
null
24
787
I have a web app that I am trying to speed up. It looks like this: ``` +------+ | | | | +------+ +------+ | | | | +------+ +------+ | | | | +------+ ``` Each box is an iFrame containing a Flash SWF and some javascript. The SWF downloads a thirdparty SWF that is used to display information. I have found that the load time for the webapp is: ``` LoadTime = (4 seconds) * numberOfBoxes + (3 seconds) ``` When I just imbed the 3rd party swf directly (without our swf or the javascript) the load time is: ``` LoadTime = (1 second) * numberOfBoxes + (2.5 seconds) ``` I am trying to find where the extra 3 seconds is being used so that I can speed up our webapp. I think that the candidates are: - - - - - ## Download Below is an image of the downloads taken from firebug. I have replaced the file names with what their type is. None of the downloads are taking especially long . One place of interest however is marked in red. The red area is a 3 second gap between when `My SWF` is loaded and when two gif files are loaded followed by the `Third Party SWF`. I think this pause is caused by processing on the client (is this true?). ![enter image description here](https://i.stack.imgur.com/HBgVd.jpg) . I think that I can conclude from this that I have a client side processing issue which implies either Flash or Javascript. - - - - - ## Javascript I used the profiler in firebug to profile the javascript. Here are the results when there are four components on the page: ![enter image description here](https://i.stack.imgur.com/iV248.jpg) This means that the javascript is running for about .25 second/chart. This seems reasonable to me. This leaves about 3.5 seconds/chart of processing for something else. ## Flash I inserted some trace statements in the AS3 code. We are listening to an event called something like "done loading". I put a trace in the first initialize method and in the "done loading" method. The flash is only eating up .2 second/chart between those two trace statements. ## Other I am not sure if there are other things other than: - - - - ## Next Steps I am not sure what my next step should be. I know that something is taking about 1.5 - 3 seconds/chart but I cannot figure out what it is. I suspect that it is something related to my swf. ## Update: Time Summary I have graphed all of the times for each thing that could be taking time. - - The last graph is possibly the most important graph. The blue dots is the amount of total loading time (measured using a stop watch). The red dots are the amount of time that I have accounted for (Javascript, download time and flash time). ![enter image description here](https://i.stack.imgur.com/0q3nR.jpg) ## Update: Browser Wars I am targeting IE and Firefox (although it is a nice bonus if other browsers work). All of the results presented so far are with Firefox with firebug running. Just for fun I thought I would try in other browsers. I don't think that this brings me closer to a solution but interesting to see how much IE sucks. ![enter image description here](https://i.stack.imgur.com/XLXbf.jpg) ## Update: Flash Loading I have been sprinkling `console.log` statements though my code trying to sandwich the slow code. (The results get pushed out to the Firebug console). One thing that I have noticed that seems suspicious to me me is that there is a 2.5 second gap between when my last javascript log gets printed and when my first flash log gets printed. ``` 17:08:29.973 - Javascript code Time difference: 2510 ms 17:08:32.483 - Flash- myComponent.init() ``` Does flash need to setup a virtual machine for each swf? Does it compile the actionscript on the client? What happens between when I `<embed>` my swf and when the `creationComplete` event in my main `.mxml`?
Optimizing my web application using Flash, Javascript and JSP
CC BY-SA 3.0
0
2011-05-31T15:13:15.290
2011-06-09T13:55:17.800
2020-06-20T09:12:55.060
-1
251,589
[ "javascript", "flash", "optimization" ]
6,189,878
1
6,206,823
null
1
187
I've recently switched over a rails app to a new server. For some reason, search results are scrambled. They look like this: ![scrambled results](https://i.stack.imgur.com/gzDit.png) But they should look like this: ![proper results](https://i.stack.imgur.com/uEMUJ.png) When I check in firebug, it seems that the wrapper div is not being parsed correctly, and so instead of a bunch of nodes wrapped in an `<a>` tag, the nodes are flat in the collection. ![firebug issues](https://i.stack.imgur.com/ifhJ1.png) This happens on chrome and firefox, windows and linux, and on different computers. There don't seem to be any CSS or HTML validation errors. I get no problem on my local development server, only in production. What's odd is that when I view an offending page in Firefox, click `View > Source`, copy the HTML into a blank document and then open it, it comes out looking fine. I also don't seem to have this problem if I just fetch the page with `curl`. The site is accessible at [http://50.57.76.99](http://50.57.76.99). You might need to make a couple of searches to get the problematic result. Any ideas? I'm totally baffled!
Scrambling HTML / CSS issue seems unexplainable
CC BY-SA 3.0
0
2011-05-31T15:24:49.917
2011-06-01T19:50:32.527
null
null
317,302
[ "html", "ruby-on-rails", "css", "nginx" ]
6,189,963
1
null
null
1
9,870
We are developing some Form, but using CustomLayout in Vaadin Forms. we used Label of Field in HTML and want to suppress the TextField Caption. Also want to make required attribute in the left side of text field. There is separation of tasks between graphics designer and developer, so Custom layout is convenient for us, so we cannot use any other layout right now. Currently my test screen is as follows, [added only two fields in Form for custom layout] As you can see that "hello" caption is top of Text Box, which I want to completely removed. This caption is just for illustration purpose, otherwise I make it empty, but still there is space in table. Also I want to make required indicator aligned with Text box. I made a Form Field factory and tried many options but no luck. if there is any specific CSS changes required please clearly tell me how to add it since I am new on CSS. based on previous discussion of Forum I added following style in my TextField without any sucess, ``` myLabel.setStyleName("inline"); ``` and using CSS: ``` .inline, .inline div { display: inline; } ``` ![enter image description here](https://i.stack.imgur.com/77K6F.png) [my case I am adding it into TextField object }
Vaadin: Custom Layout with Form [Text Field Caption and required indicator]
CC BY-SA 3.0
null
2011-05-31T15:32:29.493
2013-09-18T15:55:45.630
null
null
122,679
[ "java", "vaadin" ]
6,190,019
1
6,190,160
null
13
7,584
I need to split a rectangle (A structure which is `{{float x,float y},{float w,float h}}`) into a number of smaller rectangles/structures, creating some sort of a grid. I'm writing a window layout manager and I want a window preview option. ![enter image description here](https://i.stack.imgur.com/4EyIp.png) I saw similar questions but of the algorithms I saw (the ones involving `ceil` and `floor`) worked. I've also tried: ``` float widthOfNewRect = total.size.width / floor(sqrt(n)); float heightOfNewRect = total.size.height / ceil(sqrt(n)); ```
Split a rectangle into equal sized rectangles?
CC BY-SA 3.0
0
2011-05-31T15:37:05.297
2016-07-07T13:19:27.503
2011-05-31T15:45:11.960
160,868
160,868
[ "c", "cgrect" ]
6,190,171
1
6,446,386
null
3
1,270
I want to create a line chart. Currently my graph look like this ![enter image description here](https://i.stack.imgur.com/OY6Pa.png) The data is live so the chart should start at 9 AM and increase toward x-axis upto 4 PM when a user generate chart at 12 PM. My expected result is (Note: Data is only available upto 12 PM.) ![enter image description here](https://i.stack.imgur.com/HNQax.png) I could not find a way to generate above partial chart. Any idea?
Creating charts using google chart api with partial data
CC BY-SA 3.0
null
2011-05-31T15:48:40.337
2011-06-23T17:35:39.317
null
null
150,174
[ "charts" ]
6,190,827
1
6,190,882
null
16
19,628
I am trying to see if its possible to achieve this kind of shadow using pure css3: ![enter image description here](https://i.stack.imgur.com/BYSiU.jpg) I quickly mocked this up in photoshop. I am looking for that curved shadow effect. I know its possible to get straigt shadow effects. I tried to look on google I dont even know what to call that curved shadow. I couldn't find anywhere that says its not possible. Couldnt find anywhere that says it IS possible either. if css3 isn't happening, I am willing to use jQuery. any help, much appreciated. thanks. edit: The closest I've gotten to achieve any sort of shadow just with css3 is this: [http://jsfiddle.net/tVt4w/](http://jsfiddle.net/tVt4w/)
how to achieve this css3 shadow effect?
CC BY-SA 3.0
0
2011-05-31T16:47:54.067
2017-04-21T12:30:38.447
null
null
435,867
[ "shadow", "css" ]
6,191,012
1
null
null
4
2,260
I found this: [How does teamviewer find my computer](https://stackoverflow.com/questions/2776971/how-does-teamviewer-find-my-computer-even-if-my-comp-behind-of-the-firewall-and) but I could not understand and the answers are not what I am looking for. I'm looking for a solution in .net. If I have an image-Sender-app and how can Teamviewer connect to image-Receiver-app? Is there any tunnelig system included? Or does Teamviewer only use Port 80? Does Skype use same methode for voice chat? I am on PC-A and I have an 50KB image here as Screenshot-Frame and would like to send it to my PC-B. Now, TV (teamviewer) looks on the whole portrange from 1 to 65,000 if any port could connect the SERVER-PC. I think minimum Port 80 will success, right? But on my computer also port 4001 is open, TV will use 4001 for the feature. On PC-B it checks also for open ports and founds port 80 and 6500 and will use 6500 for the feature. My question is now, where are data going to? Is my image first going to SERVER-PC by using port 4001 and the 50KB is stored for short time there and PC-B will download it on port 6500? I cannot believe that that is the truth because it would create too much TV-SERVER-PC traffic. But how can it work? ![Image of Port switcher](https://i.stack.imgur.com/qdUP6.jpg) Regards
How can Teamviewer share images by using direct port behind a firewall
CC BY-SA 3.0
0
2011-05-31T17:06:24.867
2011-06-10T10:31:38.620
2017-05-23T12:30:37.427
-1
719,246
[ ".net", "service", "port", "remote-desktop" ]
6,191,194
1
6,191,250
null
3
151
Main Function: ``` my %hash = {'inner1'=>{'foo'=>5}, 'inner2'=>{'bar'=>6}}; $object->State(0, %AMSValues); ``` Sent to: ``` sub State { my ($self, $state, %values) = @_; my $value = \%values; ``` From what I know one should be a hash and the other is a pointer, but... ![Hash Values](https://i.stack.imgur.com/cEk0B.jpg) It doesn't look like the picture is working so, ``` $value = $value->{"HASH(0x52e0b6c)"} %values = $values->{"HASH(0x52e0b6c)"} ```
Can someone explain hashes in Perl?
CC BY-SA 3.0
null
2011-05-31T17:25:06.443
2011-05-31T17:30:20.607
null
null
507,120
[ "perl", "function", "pointers", "hash" ]
6,191,266
1
6,191,371
null
1
456
![Poorly rendered graphical representation of the picture in my head](https://i.stack.imgur.com/qats8.png) So I am designing a rather simple layout for an item manager program which i am making in Java with Swing. Typically, the cells light colored row would all stretch down to meet the blue. However, I am curious to know if you can enable cells to be sized independently of their rows. Any ideas would be most appreciated
Cells sized independently of rows MigLayout
CC BY-SA 3.0
0
2011-05-31T17:31:40.957
2011-05-31T17:42:14.337
null
null
625,050
[ "java", "swing", "user-interface", "miglayout" ]
6,191,377
1
6,203,729
null
5
890
I'm writing shadow removal for my [pony detector](https://stackoverflow.com/questions/5823903/). After I've [converted a PNG image from sRGB to CIE XYZ](http://en.wikipedia.org/wiki/Srgb#Specification_of_the_transformation) I remove the luminance [as per instructions](http://en.wikipedia.org/wiki/CIE_1931_color_space#The_CIE_xy_chromaticity_diagram_and_the_CIE_xyY_color_space): ![](https://upload.wikimedia.org/math/7/4/4/744849490ceac23308039a41761b8e13.png) ![](https://upload.wikimedia.org/math/5/b/0/5b0e763c657d9db8a8e05c7852127475.png) ![](https://upload.wikimedia.org/math/e/0/4/e043a6be1210d88f07885f53f5a9e5c2.png) When I try to convert the image back to sRGB for display, I get RGB values that fall outside the [sRGB gamut](http://en.wikipedia.org/wiki/File:Cie_Chart_with_sRGB_gamut_by_spigget.png) (I get values greater than 255). Note: conversion to XYZ and back without modification produces no glitches. Illustration (top left: [original](http://en.wikipedia.org/wiki/File:RGB_24bits_palette_color_test_chart.png), bottom left: byte value wraparaund for red and blue hues): ![](https://i.stack.imgur.com/zZNpV.png) For completeness: top right: color ratios, bottom right: convert to HSV and equalize value.
Should the result of sRGB->CIEXYZ->discard luminance be convertible back to sRGB?
CC BY-SA 3.0
null
2011-05-31T17:42:36.520
2011-06-01T15:29:34.710
2017-05-23T11:45:25.620
-1
456,116
[ "colors", "computer-vision", "color-space", "srgb" ]
6,191,427
1
12,806,113
null
2
1,264
I'm setting up a ruby Apache Buildr on a fresh Windows 7 machine. I've installed Ruby, the DevKit and installed buildr via ``` gem install buildr ``` wich all ran perfect. Until I tried to execute buildr, then I get an error. ``` buildr compile C:/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:247:in `to_specs': Could not find buildr (>= 0) amongst [atoulme-Antwrap-0.7.1, builder-2.1.2, buildr-1.4.5-x86-mswin32, buildr-as3-0.2.12, diff-lcs-1.1.2,highline-1.5.1, hoe-2.3.3, json_pure-1.4.3, minitar-0.5.3, minitest-1.6.0, net-sftp-2.0.4, net-ssh-2.0.23, rake-0.8.7, rdoc-2.5.8, rjb-1.3.2-x86-mswin32-60, rspec-2.1.0, rspec-core-2.1.0,rspec-expectations-2.1.0, rspec-mocks-2.1.0, rubyforge-2.0.3, rubygems-update-1.8.4, rubyzip-0.9.4, xml-simple-1.0.12] (Gem::LoadError) from C:/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb:256:in `to_spec' from C:/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems.rb:1182:in `gem' from C:/Ruby192/bin/buildr:18:in `<main>' ``` When I list all the gems with ``` gem list buildr ``` Everything seems to match up, and this error makes no sense at all. ![enter image description here](https://i.stack.imgur.com/EWd5Q.png) Any ideas? Help would be great, I'm getting desperate now. :)
Ruby on Windows7 - could not find gem
CC BY-SA 3.0
null
2011-05-31T17:47:29.103
2012-11-20T07:45:05.690
null
null
369,130
[ "ruby", "windows-7", "rubygems", "buildr" ]
6,191,453
1
6,191,509
null
2
4,326
Is it possible to style the tfoot section of a table so it shows between the thead and tbody? I would like to get a table to look like this: ![enter image description here](https://i.stack.imgur.com/Oa7mp.png)
Set tfoot position
CC BY-SA 3.0
null
2011-05-31T17:49:25.237
2018-10-24T22:29:58.083
2018-10-24T22:29:58.083
4,370,109
632
[ "jquery", "css", "html-table" ]
6,191,504
1
6,192,111
null
2
10,212
I am sorry if it has been asked before. I am trying to process a text file using Java. The text file is exported from MS SQLServer. When I open it in PSPad (sort of text editor in which I can view any file in hex format), it tells me that my text file is in `UTF-16LE`. Since I am getting it from someone else, it is quite possible. Now my Java program is not able to deal with that format. So I wanted to know if there is any way by which I can either convert my text file in `ASCII` format or do some preprocessing or anything? I CAN modify the file. Any help is greatly appreciated. Thanks. I wrote this program, but it is not working as expected. If I see the output file in PSPad, I can see each character as a 2-byte char, e.g. '2' is 3200 instead of just 32; 'M' is 4D00 instead of just 4D, etc. The though says the encoding of output file is UTF-8. I am kind of confused here. Can anyone tell me what am I doing wrong? ``` public static void main(String[] args) throws Exception { try { // Open the file that is the first // command line parameter FileInputStream fstream = new FileInputStream( "input.txt"); // Get the object of DataInputStream DataInputStream in = new DataInputStream(fstream); BufferedReader br = new BufferedReader(new InputStreamReader(in,"UTF-16LE")); String strLine; // Read File Line By Line while ((strLine = br.readLine()) != null) { // Write to the file writeToFile(strLine); } // Close the input stream in.close(); } catch (Exception e) {// Catch exception if any System.err.println("Error: " + e.getMessage()); } System.out.println("done."); } static public void writeToFile(String str) { try { OutputStreamWriter writer = new OutputStreamWriter(new FileOutputStream("output.txt", true), "UTF-8"); BufferedWriter fbw = new BufferedWriter(writer); fbw.write(str); fbw.close(); } catch (Exception e) {// Catch exception if any System.err.println("Error: " + e.getMessage()); } } ``` Here are the snapshots: input file in PSPad (a free hex viewer)![enter image description here](https://i.stack.imgur.com/l2PUE.jpg) output file in PSPad ![enter image description here](https://i.stack.imgur.com/g0ee5.jpg) this is what i was expecting to see: ![enter image description here](https://i.stack.imgur.com/NSAUR.jpg)
How to deal with UTF-16LE encoded text file using Java? or convert it to ASCII?
CC BY-SA 3.0
null
2011-05-31T17:54:50.510
2011-06-06T13:51:09.273
2011-06-01T15:21:31.227
645,226
645,226
[ "java", "character-encoding", "utf-16le" ]
6,191,555
1
6,191,641
null
30
92,289
Which is the best base java IDE (eclipse, Netbean) for developing spring based application apart from IntelliJ. I have used NetBean so far , the online documentation and google search points to only one link [http://netbeans.org/kb/docs/web/quickstart-webapps-spring.html](http://netbeans.org/kb/docs/web/quickstart-webapps-spring.html) . So does it mean we can only develop Spring MVC application. If we start Spring MVC application , the suggestion window work very slow, also we cannot map existing classes with the bean, or cannot explore features, it only prompts bean attributes. Also we cannot start with the application with existing source, even tried to add framework later will not work. I had recently downloaded Net-Bean 7.0 , which is latest so far, I have tried to install springs plugins for net-bean [http://plugins.netbeans.org/plugin/808/spring-netbeans-module](http://plugins.netbeans.org/plugin/808/spring-netbeans-module) but it was in vain, although the post on the plug-in page says no additional plugin will be required, but while installing, it throws some error like as shown in image attached. ![enter image description here](https://i.stack.imgur.com/aqWN2.png) Not tried Eclipse yet. I have seen IntelliJ on my friends machine. The development on it is fast and excellent, but bit expensive for personal application development. Please suggest what to do, any less expensive but good IDE for spring.
Which is the Best Java IDE for Spring Framework?
CC BY-SA 4.0
0
2011-05-31T17:59:43.037
2021-06-12T06:43:13.880
2019-05-09T17:58:29.360
8,810,941
353,497
[ "java", "spring", "eclipse", "netbeans", "ide" ]
6,191,663
1
6,191,762
null
10
3,370
Using C# and .NET 3.5, how can I get a listing of all outgoing queues in MSMQ? I found [this article about it](http://www.codeproject.com/KB/IP/MSMQ.aspx) but as you can see below I do not have the COM entry for `Microsoft Message Queue 3.0 Object Library`... ![I accidentally the Microsoft Message Queue 3.0 Object Library](https://i.stack.imgur.com/XJd5s.png) So how can I get the current outgoing queue listing? I figured there must be a way since I can see them in `Computer Management`... ![Computer Management + MSMQ](https://i.stack.imgur.com/aZGzr.png) What can I do?
Enumerate all outgoing Queues in MSMQ, C#
CC BY-SA 3.0
0
2011-05-31T18:10:10.230
2011-05-31T19:33:06.723
null
null
169,153
[ "c#", "msmq" ]
6,191,680
1
6,192,378
null
1
6,879
I have designed 4-digit BCD Counter and BCD-to-7segment Converter as a project of one of my courses in the university. Here is the circuit: [http://img849.imageshack.us/img849/930/111vr.png](http://img849.imageshack.us/img849/930/111vr.png) ![enter image description here](https://i.stack.imgur.com/58vlv.png) and here is the source code: ``` library IEEE; use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_UNSIGNED.ALL; entity IC_74163 is port(LdN, ClrN, P, T, ClK: in std_logic; D: in std_logic_vector(3 downto 0); Cout: out std_logic; Qout: out std_logic_vector(3 downto 0) ); end entity; architecture IC_74163_1 of IC_74163 is signal Q: std_logic_vector(3 downto 0); -- Q is the counter register begin Qout <= Q; Cout <= Q(3) and Q(2) and Q(1) and Q(0) and T; process (CLK) begin if CLK'event and CLK = '1' then -- change state on rising edge if ClrN = '0' then Q <= "0000"; elsif LdN = '0' then Q <= D; elsif (P and T) = '1' then Q <= Q+1; end if; end if; end process; end architecture; ``` ============================== ``` library IEEE; use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_UNSIGNED.ALL; entity Four_Digit_BCD_Counter is port(Clk: in std_logic; Q1, Q2, Q3, Q4: inout std_logic_vector(3 downto 0):= "0000"); end entity; architecture Four_Digit_BCD_Counter_1 of Four_Digit_BCD_Counter is component IC_74163 is port(LdN, ClrN, P, T, ClK: in std_logic; D: in std_logic_vector(3 downto 0); Cout: out std_logic; Qout: out std_logic_vector(3 downto 0) ); end component; signal ClrN1, ClrN2, ClrN3, ClrN4: std_logic; signal T2, T3, T4: std_logic; begin ClrN1 <= Q1(3) NOR Q1(0); ClrN2 <= Q2(3) NOR Q2(0); ClrN3 <= Q3(3) NOR Q3(0); ClrN4 <= Q4(3) NOR Q4(0); T2 <= not (Q1(3) NOR Q1(0)); T3 <= not (Q2(3) NOR Q2(0)); T4 <= not (Q3(3) NOR Q3(0)); IC_1: IC_74163 port map ('1',ClrN1,'1','1',Clk,"ZZZZ",open,Q1); IC_2: IC_74163 port map ('1',ClrN2,'1',T2,Clk,"ZZZZ",open,Q2); IC_3: IC_74163 port map ('1',ClrN3,'1',T3,Clk,"ZZZZ",open,Q3); IC_4: IC_74163 port map ('1',ClrN4,'1',T4,Clk,"ZZZZ",open,Q4); end architecture; ``` ============================== ``` library IEEE; use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_UNSIGNED.ALL; entity BCD_to_Seven_Segment_Converter is port(B3, B2, B1, B0 :in std_logic; output:out integer range 0 to 9); end entity; architecture BCD_to_Seven_Segment_Converter_1 of BCD_to_Seven_Segment_Converter is signal ss:std_logic_vector(6 downto 0); signal a, b, c, d, e, f, g:std_logic; begin a <= B3 or ((not B0) and (not B2)) or B1 or (B0 and B2); b <= (not B2) or ((not B0) and (not B1)) or (B0 and B1); c <= (not B1) or B0 or B2; d <= B3 or ((not B0) and (not B2)) or ((not B0) and B1) or (B0 and (not B1) and B2) or (B1 and (not B2)); e <= ((not B0) and B1) or ((not B0) and (not B2)); f <= B3 or ((not B0) and B2) or ((not B0) and (not B1)) or ((not B1) and B2); g <= B3 or ((not B1) and B2) or (B1 and (not B2)) or ((not B0) and B1); process(ss) begin case ss is when "1111110" => output <= 0; when "0110000" => output <= 1; when "1101101" => output <= 2; when "1111001" => output <= 3; when "0110011" => output <= 4; when "1011011" => output <= 5; when "1011111" => output <= 6; when "1110000" => output <= 7; when "1111111" => output <= 8; when "1111011" => output <= 9; when others => null; end case; end process; --process(input) --begin --case input is --when "0000" => output <= "1111110"; --when "0001" => output <= "0110000"; --when "0010" => output <= "1101101"; --when "0011" => output <= "1111001"; --when "0100" => output <= "0110011"; --when "0101" => output <= "1011011"; --when "0110" => output <= "1011111"; --when "0111" => output <= "1110000"; --when "1000" => output <= "1111111"; --when "1001" => output <= "1111011"; --when others => null; --end case; --end process; end architecture; ``` ============================== ``` library IEEE; use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_UNSIGNED.ALL; entity Project is port(Clk: in std_logic; Count: out integer range 0000 to 9999 := 0000); end entity; architecture The_Circiut of Project is component Four_Digit_BCD_Counter is port(Clk: in std_logic; Q1, Q2, Q3, Q4: inout std_logic_vector(3 downto 0):= "0000"); end component; component BCD_to_Seven_Segment_Converter is port(B3, B2, B1, B0 :in std_logic; output:out integer range 0 to 9); end component; signal Qout1, Qout2, Qout3, Qout4: std_logic_vector(3 downto 0):= "0000"; signal D0, D1, D2, D3:integer range 0 to 9; begin BCD_Counter_4Digit: Four_Digit_BCD_Counter port map (Clk, Qout1, Qout2, Qout3, Qout4); BCD_7Segment_Converter1: BCD_to_Seven_Segment_Converter port map (Qout1(0), Qout1(1), Qout1(2), Qout1(3), D0); BCD_7Segment_Converter2: BCD_to_Seven_Segment_Converter port map (Qout2(0), Qout2(1), Qout2(2), Qout2(3), D1); BCD_7Segment_Converter3: BCD_to_Seven_Segment_Converter port map (Qout3(0), Qout3(1), Qout3(2), Qout3(3), D2); BCD_7Segment_Converter4: BCD_to_Seven_Segment_Converter port map (Qout4(0), Qout4(1), Qout4(2), Qout4(3), D3); Count <= D3 * 1000 + D2 * 100 + D1 * 10 + D0; end architecture; ``` The problem is that, `Count` stays `0` forever and does not change and count up. Could you help me to figure out the problem? ==================================== Well, after I edited the problems that @MRAB and @Tomi Junnila mentioned the problem does not fixed! Also, I have tried to test `IC_74163` alone, and I think it is the source of the problem, it gives me `Qout` as `X` !! Can you guys test it for me please? I am using Active-HDL btw. ==================================== Here is the waveform for `IC_74163`: [http://img851.imageshack.us/img851/8117/52226324.png](http://img851.imageshack.us/img851/8117/52226324.png) ![enter image description here](https://i.stack.imgur.com/LV8y5.png) ==================================== OK, the counter is working very well but I still have very small issue. I have four `std_logic_vector(3 downto 0)` which are `Qout1`, `Qout2`, `Qout3` and `Qout4` .. How can I convert them to an integer of 4 digits ? `std_logic_vector(3 downto 0):= "0000"` does not work well. ==================================== OK guys, the counter is working as required and there is no issue. Thank you for your help, I really appreciate it. Here is the final source code for anyone interested: ``` library IEEE; use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_UNSIGNED.ALL; entity IC_74163 is port(LdN, ClrN, P, T, ClK: in std_logic:='0'; D: in std_logic_vector(3 downto 0):="0000"; Cout: out std_logic; Qout: inout std_logic_vector(3 downto 0):="0000"); end entity; architecture IC_74163_1 of IC_74163 is begin Cout <= Qout(3) and Qout(2) and Qout(1) and Qout(0) and T; process (CLK) begin if CLK'event and CLK = '1' then -- change state on rising edge if ClrN = '0' then Qout <= "0000"; elsif LdN = '0' then Qout <= D; elsif (P and T) = '1' then Qout <= Qout+1; end if; end if; end process; end architecture; ``` ============================== ``` library IEEE; use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_UNSIGNED.ALL; entity Four_Digit_BCD_Counter is port(Clk: in std_logic; Q1, Q2, Q3, Q4: inout std_logic_vector(3 downto 0):= "0000"); end entity; architecture Four_Digit_BCD_Counter_1 of Four_Digit_BCD_Counter is component IC_74163 is port(LdN, ClrN, P, T, ClK: in std_logic; D: in std_logic_vector(3 downto 0); Cout: out std_logic; Qout: inout std_logic_vector(3 downto 0) ); end component; signal ClrN1, ClrN2, ClrN3, ClrN4: std_logic; signal T2, T3, T4: std_logic; begin ClrN1 <= Q1(3) NAND Q1(0); ClrN2 <= Q2(3) NAND Q2(0); ClrN3 <= Q3(3) NAND Q3(0); ClrN4 <= Q4(3) NAND Q4(0); T2 <= not (Q1(3) NAND Q1(0)); T3 <= not (Q2(3) NAND Q2(0)); T4 <= not (Q3(3) NAND Q3(0)); IC_1: IC_74163 port map ('1',ClrN1,'1','1',Clk,"ZZZZ",open,Q1); IC_2: IC_74163 port map ('1',ClrN2,'1',T2,Clk,"ZZZZ",open,Q2); IC_3: IC_74163 port map ('1',ClrN3,'1',T3,Clk,"ZZZZ",open,Q3); IC_4: IC_74163 port map ('1',ClrN4,'1',T4,Clk,"ZZZZ",open,Q4); end architecture; ``` ============================== ``` library IEEE; use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_UNSIGNED.ALL; entity BCD_to_Seven_Segment_Converter is port(B3, B2, B1, B0 :in std_logic; output:out integer range 0 to 9); end entity; architecture BCD_to_Seven_Segment_Converter_1 of BCD_to_Seven_Segment_Converter is signal ss:std_logic_vector(6 downto 0); signal a, b, c, d, e, f, g:std_logic; begin a <= B3 or ((not B0) and (not B2)) or B1 or (B0 and B2); b <= (not B2) or ((not B0) and (not B1)) or (B0 and B1); c <= (not B1) or B0 or B2; d <= B3 or ((not B0) and (not B2)) or ((not B0) and B1) or (B0 and (not B1) and B2) or (B1 and (not B2)); e <= ((not B0) and B1) or ((not B0) and (not B2)); f <= B3 or ((not B0) and B2) or ((not B0) and (not B1)) or ((not B1) and B2); g <= B3 or ((not B1) and B2) or (B1 and (not B2)) or ((not B0) and B1); ss <= a&b&c&d&e&f&g; process(ss) begin case ss is when "1111110" => output <= 0; when "0110000" => output <= 1; when "1101101" => output <= 2; when "1111001" => output <= 3; when "0110011" => output <= 4; when "1011011" => output <= 5; when "1011111" => output <= 6; when "1110000" => output <= 7; when "1111111" => output <= 8; when "1111011" => output <= 9; when others => null; end case; end process; --process(input) --begin --case input is --when "0000" => output <= "1111110"; --when "0001" => output <= "0110000"; --when "0010" => output <= "1101101"; --when "0011" => output <= "1111001"; --when "0100" => output <= "0110011"; --when "0101" => output <= "1011011"; --when "0110" => output <= "1011111"; --when "0111" => output <= "1110000"; --when "1000" => output <= "1111111"; --when "1001" => output <= "1111011"; --when others => null; --end case; --end process; end architecture; ``` ============================== ``` library IEEE; use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_UNSIGNED.ALL; entity Project is port(Clk: in std_logic; Count: out integer range 0000 to 9999 := 0000); end entity; architecture The_Circiut of Project is component Four_Digit_BCD_Counter is port(Clk: in std_logic; Q1, Q2, Q3, Q4: inout std_logic_vector(3 downto 0):= "0000"); end component; component BCD_to_Seven_Segment_Converter is port(B3, B2, B1, B0 :in std_logic; output:out integer range 0 to 9); end component; signal Qout1, Qout2, Qout3, Qout4: std_logic_vector(3 downto 0):= "0000"; signal D0, D1, D2, D3:integer range 0 to 9; begin BCD_Counter_4Digit: Four_Digit_BCD_Counter port map (Clk, Qout1, Qout2, Qout3, Qout4); BCD_7Segment_Converter1: BCD_to_Seven_Segment_Converter port map (Qout1(3), Qout1(2), Qout1(1), Qout1(0), D0); BCD_7Segment_Converter2: BCD_to_Seven_Segment_Converter port map (Qout2(3), Qout2(2), Qout2(1), Qout2(0), D1); BCD_7Segment_Converter3: BCD_to_Seven_Segment_Converter port map (Qout3(3), Qout3(2), Qout3(1), Qout3(0), D2); BCD_7Segment_Converter4: BCD_to_Seven_Segment_Converter port map (Qout4(3), Qout4(2), Qout4(1), Qout4(0), D3); Count <= D3 * 1000 + D2 * 100 + D1 * 10 + D0; end architecture; ```
My counter "4-digit BCD Counter" does not work well!
CC BY-SA 3.0
0
2011-05-31T18:11:57.513
2011-06-17T19:53:27.247
2011-06-17T19:53:27.247
20,147
597,657
[ "counter", "vhdl" ]
6,191,992
1
6,192,066
null
4
14,421
Here's a screenshot of the problem: ![enter image description here](https://i.stack.imgur.com/jjk1h.png) Notice that we're on the `stalk` page. The CSS I wrote is supposed to change the color of the active page. Here is the CSS: ``` #nav { border-top:10px solid #A7C1D1; height:45px; padding-left:100px; padding-top:20px; margin-left:0; color:#000; } #nav a { color:#000; text-decoration:none; } #nav a:visited { color:#000; } #nav a:hover { color:#93AFBF; } #nav .active { color:#93AFBF; } ``` Before, I had the CSS for `#nav .active` to create a border around the active page. This worked and I could see the border around the word "stalk" when I was on the /stalk page. But this time around, I decided to just change the color of the word. This is where I ran into the issue. Here is the HTML rendered for the page: ``` <div id="nav"> <a href="/">home</a> &middot; <a href="/stalk" class="active">stalk</a> &middot; <a href="#">link3</a> &middot; <a href="#">link4</a> </div> ``` If I take away the CSS for `#nav a:visited` then the CSS for `#nav .active` works, but now the visited links are blue when I want them to stay black.
Can't seem to change color of link
CC BY-SA 3.0
0
2011-05-31T18:39:51.260
2018-04-05T11:55:32.250
null
null
177,541
[ "css" ]
6,192,025
1
6,193,252
null
0
418
In my application I parsed the data through NSXMLParser and made separate class to store that data from which i usually display the data. Everything works fine in simulator except the the title which is display in table cell with image. Images appears properly but the title not appear properly. This is my code:- ``` - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { static NSString *CellIdentifier = @"Cell"; UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier]; if (cell == nil) { [[NSBundle mainBundle] loadNibNamed:@"TableCell3" owner:self options:NULL]; cell = nibLoadedCell; } NewsInfo *aNewsInfo = [appDelegate.newsArray objectAtIndex:indexPath.row]; titleLabel.text = aNewsInfo.title; imageLabel.image = aNewsInfo.smallImageData; return cell; } ``` and in this way i configured my TableCell3.xib![TableCell3.xib](https://i.stack.imgur.com/DHCvX.png) Now i want my title data in 2 rows in label of the TableCell3. I already used both the way through xib attributes settings or through code. Code which i used instead of this xib attributes settings are:- ``` titleLabel.lineBreakMode = UILineBreakModeWordWrap; titleLabel.numberOfLines = 2; titleLabel.text = aNewsInfo.title; ``` Now Can any one help me to figure out this prob i want to display my title in two rows of the table view cell. Thanks in Advance. My Data is showing in this way...![enter image description here][2] So i want to display this title fully it show's partially right now... i want to display in two lines...
Problem in displaying properly in tableView cell by using label
CC BY-SA 3.0
null
2011-05-31T18:42:16.373
2011-06-01T06:30:47.780
2011-06-01T06:30:47.780
755,278
755,278
[ "iphone", "objective-c", "ios", "xcode4" ]
6,192,624
1
6,192,684
null
1
442
In Chrome, notice that that `input` area under "Your contact info" lines up with the border for `div#contact`. Also notice that the textarea under "Message" does not line up with that border; it's moved in a couple pixels. This is not the behavior I prefer. ![Chrome screencap](https://i.stack.imgur.com/cFaSj.png) In Firefox, everything lines up on the left. It's a little difficult, but you can see that in this screencap. This is the behavior I prefer. ![Firefox screencap](https://i.stack.imgur.com/t40yv.png) My problem is obvious: how do I get those input areas to line up on the left (as in the Firefox image)? Here is the HTML (non-working skeleton `form` code) that's rendered for that portion of the page (which resides in the footer of the page). ``` <div id="footer"> <div id="contact"> <h1>Talk to me</h1> <div id="email-me">You can email me at <a href="mailto:[email protected]">[email protected]</a><br/> or fill out the form below! </div> <form> <div id="email"> <h2>Your contact info</h2> <input type="text"/><br/> </div> <div id="message"> <h2>Message</h2> <textarea rows="10" cols="75"></textarea><br/> </div> <input class="buttons" type="submit" value="Send"/> </form> </div> </div> ``` Here's the CSS. It's quite long, so I was going to edit out some parts, but I decided against it in case some small piece makes the difference. ``` #footer { clear:both; background-color:#8BA5B5; min-height:400px; font-size:13px; font-family:Helvetica,Verdana,Arial,sans-serif; color:#fff; padding-left:105px; padding-top:30px; padding-bottom:45px; position:relative; top:5px; overflow:hidden; } #footer h1 { font-size:15px; margin:0px; margin-bottom:5px; } #footer a { color:#DAEBF5; text-decoration:none; margin-bottom:5px; } #footer a:visited { color:#333; text-decoration:none; } #footer a:hover { text-decoration:underline; } #email-me { font-size:16px; padding-left:2px; margin-bottom:10px; text-align:center; } #email-me a { font-size:18px; font-style:normal; } #contact { float:left; overflow:hidden; font-style:oblique; font-family:georgia,times,serif; } #contact h1 { font-size:44px; font-style:normal; text-align:center; font-family:helvetica,verdana,arial,sans-serif; } #contact h2 { margin:0px; font:inherit; } #contact input { background-color:transparent; border:1px solid #fff; color:#fff; width:50%; } #contact textarea { background-color:transparent; border:1px solid #fff; color:#fff; } #contact #message { margin-top:5px; margin-bottom:5px; } #contact .buttons { font-family:inherit; font-weight:800; font-size:12px; padding:5px; width:100%; background-color:#fff; color:#8BA5B5; } ```
Box issue in Chrome versus Firefox
CC BY-SA 3.0
null
2011-05-31T19:36:39.223
2011-05-31T19:43:50.173
null
null
177,541
[ "css" ]
6,193,014
1
6,195,125
null
2
3,602
what is this kind of window that pops up referred to as? and is there a way to apply it to my webview for popups? (I can ask this in a separate question if needed) ![enter image description here](https://i.stack.imgur.com/iYkzL.png)
What is this webview popup dialog?
CC BY-SA 3.0
0
2011-05-31T20:13:07.207
2013-09-17T01:29:05.330
2011-05-31T22:12:32.987
683,085
683,085
[ "android", "popup" ]
6,193,384
1
6,193,437
null
2
3,752
![Visual Studio Tools > Options Dialog](https://i.stack.imgur.com/cB68m.jpg) We have a source safe server in LAN. I want to connect VSS but I cannot see "Visual Source Safe" entry in this Visual Studio 2010 dialog.
Visual Source Safe Add-In Missing on Visual Studio 2010
CC BY-SA 3.0
null
2011-05-31T20:49:19.170
2011-05-31T20:53:48.730
null
null
253,401
[ "visual-sourcesafe" ]
6,193,387
1
6,193,727
null
4
5,833
I'm populating datagrid with collection of anonymous types (I'm setting `DataGrid's DataContext` property). And there are no errors. And nothing dsiplayed in datagrid. I've tried to make the same with defined object collection, but again nothing is displayed. Please could you instruct me what to do. Thanks! ## EDIT 1 Ok. I tried to set ItemsSource property and it works. But I'm getting strange result.. ![enter image description here](https://i.stack.imgur.com/XPWZN.png) ## EDIT 2 I don't know how but after 3d launch it now's working properly? ``` private void ShowABCResultsButtonOnClick(Object sender, RoutedEventArgs e) { var anonArray = new List<NormalizedResult> { new NormalizedResult { Key = 1, Title = "Колос", Volume = 1322.01m, Weighted = 6.7840m, Result = 6.7840m, Group = "A" }, new NormalizedResult { Key = 2, Title = "Украинский Новый", Volume = 1250.47m, Weighted = 6.4169m, Result = 13.2009m, Group = "A" }, new NormalizedResult { Key = 3, Title = "Ржано-Пшеничный", Volume = 1202.1m, Weighted = 6.1687m, Result = 19.3695m, Group = "A" } }; this.dataGrid2.ItemsSource = anonArray; } ``` this is my code. And again I've launched.. and it displayed properly only the third time? --- ---
Populating DataGrid in WPF with anonymous type collection
CC BY-SA 3.0
0
2011-05-31T20:49:29.817
2011-05-31T21:43:06.983
2011-05-31T21:29:09.187
532,675
532,675
[ "c#", "wpf", "datagrid", "datacontext", "anonymous-types" ]
6,194,442
1
6,194,459
null
0
655
I'm looking for HTML list tag where user can select several options from the list, similar to `<select>` tag with the exception of selecting several options at once What I'm looking for exactly is something very similar to jList in Java, which the list displays several options at once (unlike the `select` tag) and contains a scrollbar, and the user can select multiple options at once, like this: ![enter image description here](https://i.stack.imgur.com/Dtkqa.png) Is there such thin HTML or Javascript? or is it available as a plugin? Thanks in advance
HTML select tag with multiple selections? possible?
CC BY-SA 3.0
null
2011-05-31T22:51:54.730
2011-05-31T22:53:27.613
null
null
134,824
[ "html" ]
6,194,568
1
6,194,694
null
1
3,898
Given an instance of [System.Data.SqlDbType](http://msdn.microsoft.com/en-us/library/system.data.sqldbtype.aspx) how can I convert it to an instance of [Microsoft.SqlServer.Management.Smo.SqlDataType](http://msdn.microsoft.com/en-us/library/microsoft.sqlserver.management.smo.sqldatatype.aspx) and vice-versa? The enums don't match up. ![Comparing enums](https://i.stack.imgur.com/Qv3Wx.png)
Convert between System.Data.SqlDbType and Microsoft.SqlServer.Management.Smo.SqlDataType
CC BY-SA 3.0
null
2011-05-31T23:07:42.023
2012-06-01T20:56:22.083
2011-05-31T23:13:25.950
54,026
54,026
[ "c#", "sql-server", "enums" ]
6,194,934
1
null
null
1
897
I'm using MPMoviePlayerController with streaming with m3u8. I Have big problem that the end of playing my screen change to such as audio controller. Here are my screenshots. ![this screenshot is playing](https://i.stack.imgur.com/j45u6.png) After playing change to ![end of playing screeshot](https://i.stack.imgur.com/pKuS5.png) My m3u8 file is.. ``` #EXTM3U #EXT-X-STREAM-INF:PROGRAM-ID=1,BANDWIDTH=1148390 http://ex.com:1935/vod/mp4:1306651297327_3302.mp4/playlist.m3u8?wowzasessionid=65455083 ``` and follow [http://ex.com...playlist.m3u8?wowzasessionid=65455083](http://ex.com...playlist.m3u8?wowzasessionid=65455083) ``` #EXTM3U #EXT-X-TARGETDURATION:10 #EXT-X-MEDIA-SEQUENCE:1 #EXTINF:10, media_1.ts?wowzasessionid=65455083 #EXTINF:10, media_2.ts?wowzasessionid=65455083 #EXT-X-ENDLIST ``` I don't know why screen change. any idea?
MPMoviePlayerController end of play my screen change to audio streaming controller
CC BY-SA 3.0
null
2011-06-01T00:12:46.210
2011-09-07T06:56:28.017
null
null
396,569
[ "iphone", "objective-c", "streaming", "mpmovieplayercontroller" ]
6,195,027
1
6,198,131
null
1
1,997
My question first. It worked with `onclick` defined. But now I used a jQuery handler for a click on buttons. Works fine. See sample [http://jsfiddle.net/radek/5xym7/4/](http://jsfiddle.net/radek/5xym7/4/) I copied the handler definition (below) to my existing code (bit big to copy it here & not sure which part I need to provide to debug the issue) ``` $('button[type=button]').click(function(){ var params = $(this).val(); document.getElementById("results").innerHTML+="<BR>"+params.split('|')[0]+" - "+ params.split('|')[1]+" - "+ $(this).next().prop('checked'); }); ``` how the page look like ![how the page look like](https://i.stack.imgur.com/V1EqE.png) But it doesn't work for buttons that are inside [jsTree](http://jstree.com), On the other hand buttons outside `<div id='jstree'></div>` work with my handler. html for buttons inside jsTree ``` <button value="login|basic" class="run square_button button_background" type="button"> run </button> <input name="restore" title="restore before ant run" type="checkbox"> ``` html for buttons outside jsTree ``` <button class='run square_button button_background button' id='search' type='button' value='Search'> Search </button> ```
jQuery click handler doesn't work if inside jsTree
CC BY-SA 3.0
null
2011-06-01T00:31:02.767
2011-06-01T08:19:11.907
2011-06-01T07:23:07.657
250,422
250,422
[ "jquery", "jquery-plugins", "jquery-selectors" ]
6,195,206
1
6,195,288
null
1
2,421
I have been attempting to do this for about a week. Every single time I have tried something it failed. So I turned to copying others code... they said the code worked for them... yet it failed for me. The piece of code that I ended up liking came from the following. [How To Crop Image in Java (StackOverflow)](https://stackoverflow.com/questions/2386064/how-to-crop-to-the-image-in-java) So then from that I basically copied / made this. ``` import java.awt.Graphics; import java.awt.Rectangle; import java.awt.image.BufferedImage; public class ImageEditor { public BufferedImage crop(BufferedImage src, Rectangle rect) { BufferedImage dest = new BufferedImage(rect.getWidth(), rect.getHeight(), BufferedImage.TYPE_INT_RGB); Graphics g = dest.getGraphics(); g.drawImage(src, 0, 0, rect.getWidth(), rect.getHeight(), rect.getX(), rect.getY(), rect.getX() + rect.getWidth(), rect.getY() + rect.getHeight(), null); g.dispose(); return dest; } } ``` I got the following errors with this code. ![Error 2](https://i.stack.imgur.com/O6GdD.png) ![Error 1](https://i.stack.imgur.com/D7nqn.png) Thanks for the help in advance!
Crop image in Java with a class?
CC BY-SA 3.0
0
2011-06-01T01:04:29.603
2011-06-01T01:18:59.440
2017-05-23T12:19:48.617
-1
516,664
[ "java", "bufferedimage", "symbols", "drawimage" ]
6,195,446
1
6,195,578
null
3
6,983
![enter image description here](https://i.stack.imgur.com/TjcXp.jpg) here in above screen, i have two linear layouts, one for two TextView and two EditText and other layout for Three Button as shown in figure, Now I want to set these two layouts as below: 1) The first layout is required to set at the center of the screen 2) The all buttons or second layout have to be set on the bottom of screen So I want to ask how i can do this. My XML file is ``` <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical" android:background="#000044"> <ScrollView android:id="@+id/scrollView1" android:layout_height="wrap_content" android:layout_width="match_parent"> <LinearLayout android:id="@+id/linearLayout1" android:layout_width="match_parent" android:orientation="vertical" android:layout_height="wrap_content" android:layout_gravity="center"> <TextView android:text="Login Phone" style="@style/TextStyle.Default" android:id="@+id/loginphone"></TextView> <EditText android:layout_height="wrap_content" android:id="@+id/login" android:layout_width="match_parent" android:text="" android:inputType="number" android:numeric="integer" android:phoneNumber="true"></EditText> <TextView android:text="Mobile Pin" android:id="@+id/mobilepin" style="@style/TextStyle.Default"></TextView> <EditText android:layout_height="wrap_content" android:id="@+id/pin" android:inputType="number" android:numeric="integer" android:layout_width="match_parent" android:text="" android:password="true"></EditText> </LinearLayout> </ScrollView> <LinearLayout android:id="@+id/linearLayout2" android:layout_height="match_parent" android:layout_gravity="bottom" android:layout_width="fill_parent" android:orientation="horizontal" android:gravity="bottom"> <Button android:id="@+id/preference" android:text="Preferences" android:layout_weight="1" android:layout_height="wrap_content" android:layout_width="fill_parent"></Button> <Button android:id="@+id/loginbutton" android:text="Login" android:layout_weight="1" android:layout_height="wrap_content" android:layout_width="fill_parent"></Button> <Button android:id="@+id/exit" android:text="Exit" android:layout_weight="1" android:layout_height="wrap_content" android:layout_width="fill_parent"></Button> </LinearLayout> </LinearLayout> ```
set layout component to center
CC BY-SA 3.0
0
2011-06-01T01:51:04.960
2012-01-01T08:58:55.353
null
null
705,474
[ "android" ]
6,195,524
1
6,195,919
null
0
506
I thought that I was really close to release this new App of mine when I ran into a dead end. My code works without memory leaks in the simulator (Xcode 4.0.2) but reports memory leaks on my devices. I my issue is related to that I copy an object, because in my troubleshooting attempts I tried without a copy, and then the memory leak goes away (but of course so do my functionality!). What I do is that I add a number of instances of a subclass of UIView to an array . This subclass(Cities of which cityToAdd is an instance) has two UIViews and some variables that I need to access at a later stage. If I do this I get memory leaks on my devices: ``` [arrayOfCities addObject:[[cityToAdd mutableCopy] autorelease]]; ``` But if I do this I don't (but loose functionality) ``` [arrayOfCities addObject:cityToAdd]; ``` In the subclass I have this to handle the copying: ``` - (id)mutableCopyWithZone:(NSZone *)zone{ Cities *newCity = [[Cities allocWithZone:zone] init]; [newCity initWithCityName:cityName onRing:ring withTimeZone:timeZone withTimeZoneOffset:timeZoneOffset withDSTAngle:DSTAngle andDST:isDST]; return newCity; ``` } From Instruments I get this when testing on a device: ![enter image description here](https://i.stack.imgur.com/Sjcs3.gif) and when I drill down on the second row it shows this: ![enter image description here](https://i.stack.imgur.com/iCm8O.gif) Finally my initWithCityName method (sorry for such a long post!!) I put it as a picture to get the colors and messages from Instruments... ![enter image description here](https://i.stack.imgur.com/4Maps.jpg) Finally the UIIMage imageNamedUniversal is an extension to give me @2x images on the iPad (but I have tried with the normal imageNamed and get the same memory leaks). I dont know where to start!! Appreciate any ideas. Thanks
Memory Leak on device when using mutableCopy
CC BY-SA 3.0
null
2011-06-01T02:07:30.850
2011-06-01T03:21:21.470
null
null
350,622
[ "iphone", "xcode", "memory-leaks", "nsmutablearray", "nscopying" ]
6,195,587
1
null
null
1
1,527
i am developing an application which requires the distribution of files to several peers. as i understand about p2p is that it downloads chunks of the file from peers who has the same file which makes the download process faster. my example is: there is Peer A(which acts as server),Peer B,Peer C and Peer D. Peer B,C and D will need to update or receive new file at a certain period. so if there's any changes or new files on peer A(server), peer B,C and D will need to retrieve it for update purpose. so what im picturing here is that p2p should work like this for my situation: Peer B receives/pulls the files from server A, peer C than will also pull/receives chunk of the files from Peer A AND peer B(like p2p tech like torrent and etc.). same goes with peer D which will pull/receive chunk of the files from peer A,B and C. so in a sense, it's p2p. my question is, is there a tech out there that will help me do this kind of file distribution? i was hoping there to ease this networking part. is there such library out there? ![the graphical representation of my application](https://i.stack.imgur.com/5FWIw.jpg)
c# p2p library to share files like p2p programs out there?
CC BY-SA 3.0
0
2011-06-01T02:24:54.957
2011-06-01T02:27:55.423
null
null
692,957
[ "c#", "p2p", "share", "file-transfer" ]
6,195,791
1
6,195,849
null
2
1,144
I'm trying to increment a variable in JavaScript by clicking on a link, it works the first time but then every other time if I click on it once it will show up 3 times, then 4, 5 and so on. A screenshot of the console: ![enter image description here](https://i.stack.imgur.com/cWa4M.png) The numbers in the blue (right) are as expected, there is nothing wrong with this but as you can see on the left, each line is one click. the first log is fine but then it logs 1 three times, then 10 four times. Here is the code thats doing the work. ``` $('.here').live('click', function(eve) { eve.preventDefault(); var curpop = $(this).attr('rel') ++curpop $('.pop').html(curpop); console.log(curpop) }) ``` `$(this).attr('rel')` is just a number (in the blue, right, in the picture) once you click the link it is meant to increment the number. Thanks for you help. I have set up the same thing in jsfiddle but it seems to work there, and all the suggestions still dont work on my project even though they should. ``` <h4 class='left'>Click <a class="here" href="#" rel="1">here</a></h4> <h4 class='right'> <span class='pop'> 1 </span> </h4> ``` This is the html, now there are multiple of these but are loaded via ajax, I am guessing that it would have something to do with the multiple instances of the class with no identifier to separate them? As I suspected the problem was with the "multiple instances of the class with no identifier to separate them" so I just made each one like this: ``` <span id="<?php echo $thereID; ?>_span" class='pop'> 1 </span> ``` then `$('#' + thereID + '_span').html(curpop);` Thanks for all the help
JavaScript incrementing a variable
CC BY-SA 3.0
null
2011-06-01T02:58:40.790
2011-06-04T00:59:06.750
2011-06-03T03:42:29.593
536,129
536,129
[ "javascript", "jquery" ]
6,195,840
1
null
null
0
317
I'm struggling with a mysql import issue and the usual remedies don't seem to be working. I'm trying to copy fields from one database to another (both Drupal systems). Running "show table status on the databases" I notice that the origin table is utf8_bin and the destination table is utf8_general_ci. I'm currently doing the import like this: ``` $olddb = mysql_connect("localhost", "user", "password"); mysql_select_db("origin", $olddb); $result = mysql_query("set names utf8", $olddb); $newdb = mysql_connect("localhost", "user", "password"); mysql_select_db("destination", $newdb); $result = mysql_query("set names utf8", $newdb); $result = mysql_query("select first_name from origin_table", $olddb); $row = mysql_fetch_array($result); $query = "update destination_table set first_name = \"".$row["first_name"]."\""; $result = mysql_query($query, $olddb); ``` The text looks like its importing correctly but when I try and edit the same fields in Drupal, I get the following weird question-mark characters between every character. Fields in Safari browser ![Fields in Safari browser](https://i.stack.imgur.com/Trqgj.png) Fields in Firefox browser ![Fields in Firefox browser](https://i.stack.imgur.com/ajoxX.png) Any ideas?
How to resolve mysql text encoding issue
CC BY-SA 3.0
0
2011-06-01T03:08:06.187
2011-06-01T03:55:38.350
null
null
207,107
[ "php", "mysql", "encoding", "drupal-6" ]
6,196,079
1
6,196,083
null
2
2,198
I used Visual Studio 2010 to create a new project based on the Web Application template. I changed nothing. Note that Login.aspx and Default.aspx both reference the same Site.Master master page in the website root folder. And the Site.Master refers to the CSS sheet using a relative URL "~/Styles/Site.css" Doesn't the tilde refer to "your current location" as identified by the web page? Since the Login.aspx page and the Default.aspx pages are both in different folders and yet they both use the same Master page, how can this relative url correctly point to the CSS page be correct in both cases? ![enter image description here](https://i.stack.imgur.com/vzP27.png) ![Note the solution explorer:](https://i.stack.imgur.com/LP8hR.png)
Relative paths with Master Pages are confusing me
CC BY-SA 4.0
null
2011-06-01T03:52:58.397
2020-11-13T00:45:24.597
2020-11-13T00:44:56.120
707,111
109,676
[ "asp.net", "css", "visual-studio-2010" ]
6,196,216
1
6,196,294
null
0
382
I just saw something unusual behavior in Google Chrome's inbuilt spell check feature. This feature highlights wrong spellings with a red underline while typing in a textbox. But my doubt is, how can it under-line a the same word when all letters in the word are in small case, eg - facebook and again when i type the same word with the first alphabet in Uppercase, eg - Facebook, the word is not underlined. Here is the snapshot: ![enter image description here](https://i.stack.imgur.com/G0zK1.png)
Google Chrome spell check confusion
CC BY-SA 3.0
null
2011-06-01T04:17:00.957
2011-06-01T04:30:20.033
null
null
668,008
[ "google-chrome" ]
6,196,387
1
6,196,420
null
0
813
As you can kind of see in the image below, my menu is dropping down below my photo viewer. The photo viewer is jquery and CSS. The menu is a implemented as an asp Menu. If anyone has any suggestions please let me know. Thanks ``` <asp:Menu ID="NavigationMenu" StaticDisplayLevels="1" MaximumDynamicDisplayLevels="5" DataSourceID="menu" runat="server" CssClass="menu" EnableViewState="false" IncludeStyleBlock="false" Orientation="Horizontal"> div.menu { padding: 0px 0px 0px 0px; width:100%; } div.menu ul { list-style: none; } div.menu ul.nav li { display: inline; } div.menu ul li a, div.menu ul li a:visited { background-color: #CC1111; color: #ffffff; display: block; line-height: 1.35em; padding: 4px 20px; text-decoration:none; white-space: nowrap; font-size:large; } div.menu ul li a:hover { background-color: #CC1111; color: #ffffff; } div.menu ul li a:active { background-color: #465c71; color: #cfdbe6; text-decoration: none; } ``` ![Dropdown getting hidden by image](https://i.stack.imgur.com/A2mRY.png)
Navigation menu being hidden by jquery picture viewer
CC BY-SA 3.0
null
2011-06-01T04:46:49.323
2011-06-01T13:57:07.633
null
null
117,664
[ "jquery", "asp.net-mvc-3", "menu" ]
6,196,509
1
6,455,174
null
5
216
I came across some weird behaviour when using `GroebnerBasis`. In `m1` below, I used a Greek letter as my variable and in `m2`, I used a Latin letter. Both of them have no rules associated with them. Why do I get vastly different answers depending on what variable I choose? ### Image: ![enter image description here](https://i.stack.imgur.com/fTkbV.png) ### Copyable code: ``` Clear["Global`*"] g = Module[{x}, x /. Solve[ z - x (1 - b - b x ( (a (3 - 2 a (1 + x)))/(1 - 3 a x + 2 a^2 x^2))) == 0, x]][[3]]; m1 = First@GroebnerBasis[\[Kappa] - g, z] m2 = First@GroebnerBasis[k - g, z] ``` --- ### EDIT: As pointed out by belisarius, my usage of `GroebnerBasis` is not entirely correct as it requires a polynomial input, whereas mine is not. This error, introduced by a copy-pasta, went unnoticed until now, as I was getting the answer that I expected when I followed through with the rest of my code using `m1` from above. . Consider the example below: ``` x = (-b+Sqrt[b^2-4 a c])/2a; p = First@GroebnerBasis[k - x,{a,b,c}]; (*get relation or cover for Riemann surface*) q = First@GroebnerBasis[{D[p,k] == 0, p == 0},{a,b,c},k, MonomialOrder -> EliminationOrder]; Solve[q==0, b] (*get condition on b for double root or branch point*) {{b -> -2 Sqrt[a] Sqrt[c]}, {b -> 2 Sqrt[a] Sqrt[c]}} ``` which is correct. So my interpretation is that it is to use `GroebnerBasis` in such cases, but I'm not all too familiar with the deep theory behind it, so I could be completely wrong here. `GroebnerBasis`
Weird behaviour with GroebnerBasis in v7
CC BY-SA 3.0
0
2011-06-01T05:03:09.963
2011-06-23T13:54:18.170
2020-06-20T09:12:55.060
-1
null
[ "wolfram-mathematica", "mathematica-7" ]
6,196,571
1
7,429,522
null
1
2,805
I have been wondering if I can add custom web services with the wsdl or asmx file extension via the Research Pane in Microsoft Word 2010. I have searched just about every site that has those services, but no luck finding instructions. Rather than trial and error, I felt more confident if I were to ask someone here. Basically, what I would like to be able to do is add a site like [http://www.ebi.ac.uk/Tools/webservices/wsdl](http://www.ebi.ac.uk/Tools/webservices/wsdl) or some other source and be able to send queries via the research pane. ![Research Pane in Microsoft Word 2010 after unsuccessful addition](https://i.stack.imgur.com/l8NpQ.png)
Is there a way to add custom web services to Word 2010 via the Research Pane?
CC BY-SA 3.0
0
2011-06-01T05:11:55.490
2017-09-08T14:09:33.223
2017-09-08T14:09:33.223
1,000,551
337,574
[ "web-services", "ms-word", "office-2010", "word-2010" ]
6,196,649
1
6,196,885
null
5
675
Is there any component to create graphical `Tab Pages` like this? ![enter image description here](https://i.stack.imgur.com/O6ohL.png)
Is there any component to create graphical tab pages? (according to the picture)
CC BY-SA 3.0
0
2011-06-01T05:23:13.503
2011-06-01T06:32:56.637
2011-06-01T06:32:56.637
18,061
381,979
[ "delphi", "tabs" ]
6,196,653
1
null
null
4
1,367
Recently, I implemented parallelisation in my [MATLAB](http://en.wikipedia.org/wiki/MATLAB) program, much to the suggestions offered in [Slow xlsread in MATLAB](https://stackoverflow.com/questions/6173198). However, implementing the parallelism has cropped up another problem - . The culprit seems to be the `java.util.concurrent.LinkedBlockingQueue` method as can be seen from the attached images of profiler and the corresponding condensed graphs. How do I remove this non-linearity as my work involves processing more than 1000 sheets in single run - which would take an insanely long time? The parallelised part of the program involves just reading all the `.xls` files and storing them in matrices, after which I start the remainder of my program. `dlmwrite` is used towards the end of the program and optimization on its time is not really required, although could also be suggested. --- ![Profiler details for reading a single Excel sheet from a file having n sheets.](https://i.stack.imgur.com/le5y0.png) ![Graph for the times in the above tables.](https://i.stack.imgur.com/9bF7v.png) --- ![Processing multiple sheets from file containing multiple sheets.](https://i.stack.imgur.com/Cisyd.png) ![Processing multiple sheets from file containing multiple sheets.](https://i.stack.imgur.com/1pzOl.png) --- ![Enter image description here](https://i.stack.imgur.com/FiA5a.png) ``` parfor i = 1:runs sin = 'Sheet'; sno = num2str(i); sna = strcat(sin, sno); data(i, :, :) = xlsread('Processes.xls', sna, '' , 'basic'); end ```
Non-linear performance of Java function in parallel MATLAB
CC BY-SA 3.0
null
2011-06-01T05:23:57.327
2011-07-27T10:50:03.337
2017-05-23T12:30:14.647
-1
127,212
[ "performance", "matlab", "file-io", "parallel-processing" ]
6,196,770
1
6,196,884
null
7
5,182
I could export data of datagridview to excel. But the actual format of datagridview was not exported i.e., font, color and space. So, is there any best way to export datagridview to excel i.e. not only data but also the look. The sample look is this: ![enter image description here](https://i.stack.imgur.com/HRstj.png)
datagridview export to excel
CC BY-SA 4.0
0
2011-06-01T05:39:59.087
2020-11-03T19:05:32.343
2020-11-03T19:05:32.343
1,783,163
665,440
[ "c#" ]
6,196,773
1
6,717,866
null
5
1,068
Now a day i am doing a project related to image processing with the fallowing feature 1)Stretch 2)Scale 3)Twist I am not understand how to achieve it in android. Here i am putting some screen shot related to this project for makeing more clarity in my question.![enter image description here](https://i.stack.imgur.com/uwKaw.jpg) The above image is the real image i want to apply image processing over this image for making it like blow image. ![enter image description here](https://i.stack.imgur.com/28ohV.jpg) Please me any suggestion,help url ,tutorial and other thinks for achieve this task.
Image processing in android with stretch scale and Twist effect
CC BY-SA 3.0
0
2011-06-01T05:40:41.787
2011-07-16T16:07:28.833
null
null
588,763
[ "android", "image", "image-processing" ]
6,196,894
1
6,197,145
null
3
895
One of my views looks like this right now. Near the big 5, specifically above and below it, there is considerable margin. How can I reduce or remove this margin? ![enter image description here](https://i.stack.imgur.com/yYxhS.png) The related XML code looks like this: ``` <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent"> <TextView style="@style/medText" android:id="@+id/whenSee" android:text="@string/whenSee" android:layout_alignParentLeft="true" android:layout_above="@+id/newViewValue" android:gravity="center" android:layout_alignRight="@+id/button_to_press"></TextView> <TextView style="@style/numberSelect" android:id="@+id/newViewValue" android:text="9" android:layout_above="@+id/press_text" android:layout_alignParentLeft="true" android:gravity="center" android:layout_alignRight="@+id/button_to_press"></TextView> <TextView style="@style/medText" android:id="@+id/press_text" android:layout_above="@+id/button_to_press" android:layout_alignParentLeft="true" android:text="@string/press" android:gravity="center" android:layout_alignRight="@+id/button_to_press"></TextView> </RelativeLayout> ``` Styles are here: ``` <style name="medText"> <item name="android:textSize">22sp</item> <item name="android:layout_height">wrap_content</item> <item name="android:layout_width">wrap_content</item> </style> <style name="numberSelect"> <item name="android:textSize">80sp</item> <item name="android:layout_height">wrap_content</item> <item name="android:layout_width">wrap_content</item> </style> ```
How can I reduce the margin?
CC BY-SA 3.0
0
2011-06-01T05:57:53.517
2011-06-01T06:53:48.163
null
null
544,198
[ "android", "android-layout", "android-xml" ]
6,197,192
1
6,278,433
null
0
435
I would like to have a MovieClip that has a bit of depth. I can't use rotationX, rotationY or rotationZ because I have to use Flash CS3. The first image is what I have now, a flat movieclip. The second is what I should have. ![enter image description here](https://i.stack.imgur.com/Jn9p8.jpg) ![enter image description here](https://i.stack.imgur.com/kO8Ai.jpg) I already tried using a matrix, but that didn't work. I posed [a question](https://stackoverflow.com/questions/6184199/as3-simulating-rotationx-with-matrix) about it, and there somebody sugested that I should use a 3D engine to get the result I want. Since it was a MovieClip that had to be in 3D I used now a MovieClipSprite. ``` var movieClipSprite:MovieClipSprite = new MovieClipSprite(myMC); var view:View3D = new View3D({x:200,y:200}); var cam:Camera3D = new Camera3D(); cam.zoom = 1; cam.y = 100; view.camera = cam; cam.lookAt(new Number3D(0, 0, 0)); this.addChild(view); view.scene.addSprite(movieClipSprite); view.render(); ``` It didn't matter how I changed the camera, I always have got the same result. The flat movieclip. Then I read in the Away3D documentation > MovieClipSprite: Spherical billboard (always facing the camera) sprite object that uses a movieclip as it's texture. Draws individual display objects inline with z-sorted triangles in a scene. I think that's why it always gives the same result. I also tried something with MovieMaterial, but I never have got that working. Can you please help me to put my movieclip in perspective? Thanks a lot! Vincent
MovieClip in perspective
CC BY-SA 3.0
null
2011-06-01T06:36:33.717
2011-06-08T12:07:17.507
2020-06-20T09:12:55.060
-1
99,360
[ "flash", "actionscript-3", "away3d" ]
6,197,236
1
6,197,461
null
1
2,534
I have made custom listview in android activity which has progressbar. On top of that listview there is another progress bar which shows progress as day passes in the month. Now i want to set a bar according to the progress of the month progress bar in custom listview which has four progress bars. Please see the attached image. ![ProgressBarUpdate](https://i.stack.imgur.com/dR0JJ.png) The progress of the month progress bar and the bar which we put in listview progress bar should be at same position means aligned and this bar which we put should move when the top progress increases as day passes. In Layout file I have used LinearLayout where I want to put the bar. ``` <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginTop="5dip"> <RelativeLayout android:id="@+id/Top" android:layout_centerHorizontal="true" android:layout_width="250dip" android:layout_height="wrap_content"> <TextView android:id="@+id/LeftText" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="O" android:textColor="#FFFFFF" android:textStyle="normal" android:layout_alignParentLeft="true" /> <RelativeLayout android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentRight="true"> <TextView android:id="@+id/TextOne" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="O" android:textColor="#FFFFFF" android:textStyle="normal" android:layout_marginRight="5dip" /> <TextView android:id="@+id/TextTwo" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/outof" android:textColor="#FFFFFF" android:textStyle="normal" android:layout_toRightOf="@+id/TextOne" android:layout_marginRight="5dip" /> <TextView android:id="@+id/RightText" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="O" android:textColor="#FFFFFF" android:textStyle="normal" android:layout_toRightOf="@+id/TextTwo" /> </RelativeLayout> </RelativeLayout> <RelativeLayout android:id="@+id/Bottom" android:layout_below="@+id/Top" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerHorizontal="true"> <ProgressBar android:id="@+id/CustomPro" android:layout_width="250dip" android:layout_height="wrap_content" android:progress="0" android:max="100" android:secondaryProgress="0" style="?android:attr/progressBarStyleHorizontal" android:progressDrawable="@drawable/accountdataprogress" android:layout_centerHorizontal="true" /> <TextView android:id="@+id/MiddleText" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="0%" android:textColor="#000000" android:textStyle="bold" android:layout_centerHorizontal="true" /> </RelativeLayout> <RelativeLayout android:id="@+id/Middle" android:layout_centerHorizontal="true" android:layout_width="250dip" android:layout_height="wrap_content" android:layout_below="@+id/Top"> <LinearLayout android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/PuttingBar" android:layout_alignParentLeft="true"> </LinearLayout> </RelativeLayout> <View android:layout_width="fill_parent" android:layout_height="10dip" android:background="#00000000" android:layout_below="@+id/Bottom" /> </RelativeLayout> ``` In Java I have done something like this. ``` import java.util.ArrayList; import android.content.Context; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.BaseAdapter; import android.widget.ProgressBar; import android.widget.TextView; public class ProgressListAdapter extends BaseAdapter { private Context mContext; private ArrayList<ProgressList> mPList; private TextView mLeft, mMiddle, mRight, mTextOne; private ProgressBar mCustomProgressBar; private LinearLayout mLinearLayout; public ProgressListAdapter(Context nContext, ArrayList<ProgressList> nPList) { this.mContext = nContext; this.mPList = nPList; } @Override public int getCount() { return mPList.size(); } @Override public Object getItem(int nPosition) { return mPList.get(nPosition); } @Override public long getItemId(int nPosition) { return nPosition; } @Override public View getView(int position, View convertView, ViewGroup parent) { ProgressList mEntry = mPList.get(position); if (convertView == null) { LayoutInflater mInflater = (LayoutInflater) mContext.getSystemService(Context.LAYOUT_INFLATER_SERVICE); convertView = mInflater.inflate(R.layout.customprogress, null); } mLeft = (TextView) convertView.findViewById(R.id.LeftText); mLeft.setText(mEntry.getValueText()); mMiddle = (TextView) convertView.findViewById(R.id.MiddleText); mCustomProgressBar = (ProgressBar) convertView.findViewById(R.id.CustomPro); int mBarPosition = Usage.mElapsed; mLinearLayout = (LinearLayout) convertView.findViewById(R.id.PuttingBar); View mView = new View(mContext); LinearLayout.LayoutParams layoutParams = new LinearLayout.LayoutParams(2, 25); layoutParams.setMargins(mBarPosition, 0, 0, 0); mView.setMinimumHeight(25); mView.setMinimumWidth(2); mView.setBackgroundColor(Color.rgb(12, 56, 99)); mLinearLayout.addView(mView, layoutParams); mView.invalidate(); if(mEntry.getValueNumber() > mBarPosition) { mCustomProgressBar.setProgress(mBarPosition); mCustomProgressBar.setSecondaryProgress(mEntry.getValueNumber()); } else if(mEntry.getValueNumber() <= mBarPosition) { mCustomProgressBar.setProgress((mEntry.getValueNumber())); mCustomProgressBar.setSecondaryProgress(0); } mMiddle.setText(Integer.toString(mEntry.getValueNumber()) + "%"); mTextOne = (TextView) convertView.findViewById(R.id.TextOne); mTextOne.setText(mEntry.getValue()); mRight = (TextView) convertView.findViewById(R.id.RightText); mRight.setText(mEntry.getValueOne()); return convertView; } } ``` But When I run It shows extra bar in progress bar like this ![ProgressBar](https://i.stack.imgur.com/TUj7g.png) Anybody has done kind of work please give me your hand. Waiting for fruitful reply. Thanks.
How to add a view to custom listview in android?
CC BY-SA 3.0
null
2011-06-01T06:41:47.163
2011-06-02T11:29:36.127
2011-06-01T07:04:50.990
null
null
[ "android", "listview", "view", "add" ]
6,197,375
1
6,197,647
null
0
246
In my application I parsed the data through NSXMLParser and made separate class to store that data from which i usually display the data. Everything works fine in simulator except the the title which is display in table cell with image. Images appears properly but the title not appear properly. This is my code:- ``` - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { static NSString *CellIdentifier = @"Cell"; UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier]; if (cell == nil) { [[NSBundle mainBundle] loadNibNamed:@"TableCell3" owner:self options:NULL]; cell = nibLoadedCell; } NewsInfo *aNewsInfo = [appDelegate.newsArray objectAtIndex:indexPath.row]; titleLabel.text = aNewsInfo.title; imageLabel.image = aNewsInfo.smallImageData; return cell; } ``` and in this way i configured my TableCell3.xib![enter image description here](https://i.stack.imgur.com/tNPgL.png) Now i want my title data in 2 rows in label of the TableCell3. I already used both the way through xib attributes settings or through code. Code which i used instead of this xib attributes settings are:- ``` titleLabel.lineBreakMode = UILineBreakModeWordWrap; titleLabel.numberOfLines = 2; titleLabel.text = aNewsInfo.title; ``` Now Can any one help me to figure out this prob i want to display my title in two rows of the table view cell. Thanks in Advance.
Data not display UITableView?
CC BY-SA 3.0
null
2011-06-01T06:57:32.110
2011-06-01T07:25:42.740
null
null
755,278
[ "iphone", "objective-c", "xcode4" ]
6,197,386
1
null
null
0
2,205
There is a serious issue I am facing with flash builder charts. When I load the chart the first time I get this - ![First Load](https://i.stack.imgur.com/cR6og.png) But if I refresh the page immediately in the same browser, I get this - ![Second Load](https://i.stack.imgur.com/kTY0v.png) The second one is the expected one. This issue just repeats if I close the browser window and open it in a new browser window. For explaining properly, I am attaching the source code here - ``` <?xml version="1.0" encoding="utf-8"?> <s:Group xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark" xmlns:defaultstatistics="services.defaultstatistics.*" xmlns:mx="library://ns.adobe.com/flex/mx" width="800" height="800" xmlns:Examples="Examples.*" creationComplete="start();" > <!--<fx:Style source="styles/Golibaje.css"/>--> <fx:Script> <![CDATA[ import CustomEvents.ChartLoadedEvent; import mx.collections.ArrayCollection; import mx.controls.Alert; import mx.rpc.events.ResultEvent; import mx.utils.object_proxy; import org.axiis.core.AxiisSprite; import org.axiis.data.DataSet; private var ds:DataSet = new DataSet(); public var loaded:Boolean = false; //Set this variable to the appropriate time period used by the data. [Bindable] public var timeIncrement:String = "month"; [Bindable] private var performanceData:ArrayCollection = new ArrayCollection([ {month:"January", correct:100, correctOutsideBase:50, incorrect:50, skipped:25}, {month:"February", correct:110, correctOutsideBase:40, incorrect:50, skipped:30}, {month:"March", correct:120, correctOutsideBase:40, incorrect:25, skipped:30}, {month:"April",correct:110, correctOutsideBase:45, incorrect:20, skipped:20}, {month:"May", correct:135, correctOutsideBase:25, incorrect:25, skipped:15}, {month:"June", correct:150, correctOutsideBase:15, incorrect:15, skipped:5}, {month:"July", correct:155, correctOutsideBase:10, incorrect:10}, {month:"August", correct:160, correctOutsideBase:5, incorrect:15}, {month:"September",correct:170, correctOutsideBase:5, incorrect:10} ]); [Bindable] private var pointsData:ArrayCollection = new ArrayCollection([ {month:"January", points:1000}, {month:"February", points:1200}, {month:"March", points:1400}, {month:"April",points:1500}, {month:"May", points:1600}, {month:"June", points:1650}, {month:"July", points: 1800}, {month:"August", points: 2000}, {month:"September", points: 2500} ]); public function start():void { var t:Timer = new Timer(2000, 1); t.addEventListener(TimerEvent.TIMER_COMPLETE, fireChartLoaded); t.start(); } private function fireChartLoaded(event){ loaded = true; dispatchEvent(new Event("chartLoaded")); } ]]> </fx:Script> <fx:Declarations> </fx:Declarations> <mx:CartesianChart id="PerformanceTimeChart" dataProvider="{performanceData}" showDataTips="true" width="800" height="700" verticalCenter="0" horizontalCenter="0"> <mx:verticalAxisRenderers> <mx:AxisRenderer placement="left" axis="{columnAxis}"/> <mx:AxisRenderer placement="right" axis="{pointsAxis}"/> </mx:verticalAxisRenderers> <mx:horizontalAxis> <mx:CategoryAxis categoryField="{timeIncrement}"/> </mx:horizontalAxis> <mx:series> <mx:ColumnSet type="stacked"> <mx:verticalAxis> <mx:LinearAxis id="columnAxis" title="Result"/> </mx:verticalAxis> <mx:ColumnSeries yField="correct" displayName="Correct" verticalAxis="{columnAxis}"/> <mx:ColumnSeries yField="correctOutsideBase" displayName="Outside Base" verticalAxis="{columnAxis}"/> <mx:ColumnSeries yField="incorrect" displayName="Wrong Answer" verticalAxis="{columnAxis}"/> <mx:ColumnSeries yField="skipped" displayName="Skipped Question" verticalAxis="{columnAxis}"/> </mx:ColumnSet> <mx:LineSeries dataProvider="{pointsData}" yField="points" displayName="Points"> <mx:verticalAxis> <mx:LinearAxis id="pointsAxis" title="Points"/> </mx:verticalAxis> </mx:LineSeries> </mx:series> </mx:CartesianChart> <mx:Legend dataProvider="{PerformanceTimeChart}" direction="horizontal"/> </s:Group> ``` Anyone has any ideas why this might be happening?
Flex chart with multiple series and multiple axes giving weird results
CC BY-SA 3.0
0
2011-06-01T06:58:32.827
2011-09-16T10:15:34.013
2011-09-16T10:15:34.013
256,196
297,964
[ "apache-flex", "charts", "flash-builder" ]
6,197,599
1
6,277,846
null
2
1,162
I have some radio buttons on which I have applied css to align them. Here is the image: ![enter image description here](https://i.stack.imgur.com/kolUB.png) These are all placed in a table and third column of table contains one listbox or dropdown list against each pair of radio button and when I click the second radio button, hidden listbox or dropdown appears in the third column. As I have applied css on it to set its height and width, when I click the second radio button of each pair and listbox appears, third column doesn't grow dynamically. See the image: ![enter image description here](https://i.stack.imgur.com/mFZmR.png) I can't remove CSS because alignment will suffer. There is another table on the right side which I want also grow or shrink on the basis of clicking radio buttons. But it was not fitting in first table because I have not much idea of css, so I separate it but I really wish this to merge in first table somehow without affecting table structure. Code of aspx left table is: ``` <div class="formBroadLeftCol"> <table border="1"> <tr> <td class="tdShortLeft"> <asp:RadioButton ID="rdoAllStaff" runat="server" Text="All Staff" AutoPostBack="true" Checked="true" GroupName="grpStaff" OnCheckedChanged="rdoAllStaff_CheckedChanged" /> </td> <td class="tdShortRight"> <asp:RadioButton ID="rdoStaff" runat="server" Text="Staff" AutoPostBack="true" GroupName="grpStaff" OnCheckedChanged="rdoStaff_CheckedChanged" /> </td> <td class="tdShortMiddle"> <div id="divStaff" runat="server" visible="false" class="divListBox" style="width: 175px; height: 80px;"> <asp:ListBox ID="lstStaff" runat="server" SelectionMode="Multiple" Width="175px" Height="81" CssClass="SingleColumnlist"></asp:ListBox> </div> </td> </tr> <tr> <td class="tdShortLeft"> <asp:RadioButton ID="rdoAllService" runat="server" Text="All Services" AutoPostBack="true" Checked="true" GroupName="grpService" OnCheckedChanged="rdoAllService_CheckedChanged" /> </td> <td class="tdShortRight"> <asp:RadioButton ID="rdoService" runat="server" Text="Service" AutoPostBack="true" GroupName="grpService" OnCheckedChanged="rdoService_CheckedChanged" /> </td> <td class="tdShortMiddle"> <div id="divService" runat="server" visible="false" class="divListBox" style="width: 175px; height: 80px;"> <asp:ListBox ID="lstService" runat="server" SelectionMode="Multiple" Width="175px" Height="81" CssClass="SingleColumnlist"></asp:ListBox> </div> </td> </tr> <tr> <td class="tdShortLeft"> <asp:RadioButton ID="rdoAllServiceType" runat="server" Text="All Service Types" AutoPostBack="true" Checked="true" GroupName="grpServiceType" OnCheckedChanged="rdoAllServiceType_CheckedChanged" /> </td> <td class="tdShortRight"> <asp:RadioButton ID="rdoServiceType" runat="server" Text="Service Type" AutoPostBack="true" GroupName="grpServiceType" OnCheckedChanged="rdoServiceType_CheckedChanged" /> </td> <td class="tdShortMiddle"> <div id="divServiceType" runat="server" visible="false" class="divListBox" style="width: 175px; height: 80px;"> <asp:ListBox ID="lstServiceType" runat="server" SelectionMode="Multiple" Width="175px" Height="81" CssClass="SingleColumnlist"></asp:ListBox> </div> </td> </tr> <tr> <td class="tdShortLeft"> <asp:RadioButton ID="rdoAllServiceStatus" runat="server" Text="All Service Statuses" AutoPostBack="true" Checked="true" GroupName="grpServiceStatus" OnCheckedChanged="rdoAllServiceStatus_CheckedChanged" /> </td> <td class="tdShortRight"> <asp:RadioButton ID="rdoServiceStatus" runat="server" Text="Service Status" AutoPostBack="true" GroupName="grpServiceStatus" OnCheckedChanged="rdoServiceStatus_CheckedChanged" /> </td> <td class="tdShortMiddle"> <div id="divServiceStatus" runat="server" visible="false" class="divListBox" style="width: 175px; height: 80px;"> <asp:ListBox ID="lstServiceStatus" runat="server" SelectionMode="Multiple" Width="175px" Height="81" CssClass="SingleColumnlist"></asp:ListBox> </div> </td> </tr> <tr> <td class="tdShortLeft"> <asp:RadioButton ID="rdoAllTreatmentProvider" runat="server" Text="All Treatment Provider" AutoPostBack="true" Checked="true" GroupName="grpTreatmentProvider" OnCheckedChanged="rdoAllTreatmentProvider_CheckedChanged" /> </td> <td class="tdShortRight"> <asp:RadioButton ID="rdoTreatmentProvider" runat="server" Text="Treatment Provider" AutoPostBack="true" GroupName="grpTreatmentProvider" OnCheckedChanged="rdoTreatmentProvider_CheckedChanged" /> </td> <td class="tdShortMiddle"> <div id="divTreatmentProvider" runat="server" visible="false" class="divListBox" style="width: 175px; height: 80px;"> <asp:ListBox ID="lstTreatmentProvider" runat="server" SelectionMode="Multiple" Width="175px" Height="81" CssClass="SingleColumnlist" DataSourceID="dtsTreatmentProviders" DataTextField="FirstName" DataValueField="ServiceId"></asp:ListBox> </div> </td> </tr> <tr> <td class="tdShortLeft"> <asp:RadioButton ID="rdoAllConsumerStatus" runat="server" Text="All Consumer Statuses" AutoPostBack="true" Checked="true" GroupName="grpConsumerStatus" OnCheckedChanged="rdoAllConsumerStatus_CheckedChanged" /> </td> <td class="tdShortRight"> <asp:RadioButton ID="rdoConsumerStatus" runat="server" Text="Consumer Status" AutoPostBack="true" GroupName="grpConsumerStatus" OnCheckedChanged="rdoConsumerStatus_CheckedChanged" /> </td> <td class="tdShortMiddle"> <div id="divConsumerStatus" runat="server" visible="false" class="divListBox" style="width: 175px; height: 80px;"> <asp:ListBox ID="lstConsumerStatus" runat="server" SelectionMode="Multiple" Width="175px" Height="81" CssClass="SingleColumnlist" DataSourceID="dtsClientStatus" DataTextField="Status" DataValueField="Id"></asp:ListBox> </div> </td> </tr> <tr> <td class="tdShortLeft"> <asp:RadioButton ID="rdoAllEhnicity" runat="server" Text="All Ehnicities" AutoPostBack="true" Checked="true" GroupName="grpEhnicity" OnCheckedChanged="rdoAllEhnicity_CheckedChanged" /> </td> <td class="tdShortRight"> <asp:RadioButton ID="rdoEhnicity" runat="server" Text="Ehnicity" AutoPostBack="true" GroupName="grpEhnicity" OnCheckedChanged="rdoEhnicity_CheckedChanged" /> </td> <td class="tdShortMiddle"> <div id="divEhnicity" runat="server" visible="false" class="divListBox" style="width: 175px; height: 80px;"> <asp:ListBox ID="lstEhnicity" runat="server" SelectionMode="Multiple" Width="175px" Height="81" CssClass="SingleColumnlist" DataSourceID="dtsEthnicity" DataTextField="LookupItem" DataValueField="Id"></asp:ListBox> </div> </td> </tr> </table> ``` Code of Right table: ``` <div class="formShortRightCol"> <table border="1"> <tr> <td> <asp:CheckBoxList ID="chkStaff" runat="server" RepeatDirection="Horizontal"> <asp:ListItem Text="Display" Value="Display"></asp:ListItem> <asp:ListItem Text="Sub Totals" Value="Sub Totals"></asp:ListItem> </asp:CheckBoxList> </td> </tr> <tr> <td> <asp:CheckBoxList ID="chkService" runat="server" RepeatDirection="Horizontal"> <asp:ListItem Text="Display" Value="Display"></asp:ListItem> <asp:ListItem Text="Sub Totals" Value="Sub Totals"></asp:ListItem> </asp:CheckBoxList> </td> </tr> <tr> <td> <asp:CheckBoxList ID="chkServiceType" runat="server" RepeatDirection="Horizontal"> <asp:ListItem Text="Display" Value="Display"></asp:ListItem> <asp:ListItem Text="Sub Totals" Value="Sub Totals"></asp:ListItem> </asp:CheckBoxList> </td> </tr> <tr> <td> <asp:CheckBoxList ID="chkServiceStatus" runat="server" RepeatDirection="Horizontal"> <asp:ListItem Text="Display" Value="Display"></asp:ListItem> <asp:ListItem Text="Sub Totals" Value="Sub Totals"></asp:ListItem> </asp:CheckBoxList> </td> </tr> <tr> <td> <asp:CheckBoxList ID="chkTreatmentProvider" runat="server" RepeatDirection="Horizontal"> <asp:ListItem Text="Display" Value="Display"></asp:ListItem> <asp:ListItem Text="Sub Totals" Value="Sub Totals"></asp:ListItem> </asp:CheckBoxList> </td> </tr> <tr> <td> <asp:CheckBoxList ID="chkConsumerStatus" runat="server" RepeatDirection="Horizontal"> <asp:ListItem Text="Display" Value="Display"></asp:ListItem> <asp:ListItem Text="Sub Totals" Value="Sub Totals"></asp:ListItem> </asp:CheckBoxList> </td> </tr> <tr> <td> <asp:CheckBoxList ID="chkEthnicity" runat="server" RepeatDirection="Horizontal"> <asp:ListItem Text="Display" Value="Display"></asp:ListItem> <asp:ListItem Text="Sub Totals" Value="Sub Totals"></asp:ListItem> </asp:CheckBoxList> </td> </tr> </table> </div> ``` Relevant CSS classes are: ``` .formBroadLeftCol { padding: 0px 0px 0px 0px; float:left; width:450px; } .formShortRightCol { padding: 0px 0px 0px 0px; float:right; /*width:180px;*/ } .tdShortLeft { width:150px; height:20px; float:left; padding: 5.5px 0px 5.5px 0px; } .tdShortRight { width:150px; height:20px; /*float:right; */ padding: 5.5px 0px 5.5px 0px; } .tdShortMiddle { width:100px; height:20px; float:right; margin:0px 25px 0px 0px; padding: 5.5px 0px 5.5px 0px; } ```
CSS is conflicting with ASP.NET table control
CC BY-SA 3.0
null
2011-06-01T07:21:20.790
2018-01-20T17:04:14.173
2018-01-20T17:04:14.173
4,370,109
669,448
[ "css", "asp.net", "html-table" ]
6,197,922
1
null
null
0
1,184
I want to learn socket programming in C#, and related settings. I've download a demo from a site. when i set Remote Host IP address to my local address it connect to server (my pc) and send receive works. ![enter image description here](https://i.stack.imgur.com/h44GC.png) however when i set Remote Host IP address to my router external IP, i doesn't connect and throw exception: "No connection could be made because the target machine actively refused it 91.99.166.161:300" ![enter image description here](https://i.stack.imgur.com/odlWW.png) i set port forwarding in my router. what's wrong? Thanks in advance.
socket.connect throw exception
CC BY-SA 3.0
null
2011-06-01T07:52:58.390
2011-06-02T09:14:34.760
null
null
522,964
[ "sockets", "c#-4.0", "system.net" ]
6,197,938
1
6,200,689
null
48
3,693
> # I have started a bounty for this question ...because I really want the community's input. I can (and have) looked at several languages / frameworks and think 'well, this will probably work okay' -- but I would really appreciate advice that's based specifically on the problem I face, and especially from anyone with experience integrating / using what you recommend. --- I work on scientific analysis software. It provides a lot of tools for mathematical transformation of data. One tool allows the user to enter in their own equation, which is run over the data set (a large 2D or 3D matrix of values) and evaluated. This tool has a graphical equation editor, which internally builds an object-oriented expression tree with a different object for each operation (there would be an instance of the Logarithm class, for example, which is the node in the tree for adding calculating a logarithm of a value to a base; it has two children which are its inputs.) A screenshot of part of it: ![enter image description here](https://i.stack.imgur.com/AbLGP.png) You can see the tree it's building on the left, and a few of many (fifty?) potential operations in the menu on the right. This has a few downsides: - - - It was neat when it was much simpler, but not any more, for the kind of stuff our users want to be able to do with it. If I wrote it now I'd do it quite differently - and this is my chance :) I would like to give user something more powerful, and let them write code - script or compiled - that can perform much more advanced operations. The rest of this question is quite long - I'm sorry. I've tried to describe the problem in detail. Thanks in advance for reading it :) ## Important constraints: - Our math operates on large matrices. In the above equation, V1 represents the input (one of potentially many) and is 2D or 3D, and each dimension can be large: on the order of thousands or hundreds of thousands. (We rarely calculate all of this at once, just slices / segments. But if the answer involves something which requires marshalling the data, be aware size and speed of this is a consideration.)- The operations we provide allow you to write, say, `2 x V`, which multiplies every element in `V` by 2. The result is another matrix the same size. In other words, a scripting or programming language which includes standard math primitives isn't enough: we need to be able to control primitives are available, or they are implemented.These operations can be complex: the input can be as simple as a number (2, 5.3, pi) or as complex as a 1, 2 or 3-dimensional matrix, which contains , or (paired values) data. My current thinking is a language powerful enough to which we can expose our data types as classes and can implement standard operators. A simple evaluator won't be enough.- - Our audience is primarily research scientists who either are not used to coding, or are probably used to a language like Matlab or R.- We use [Embarcadero C++ Builder 2010](http://www.embarcadero.com/products/cbuilder) for development, with small amounts of Delphi. This may restrict what we can make use of - just because something's C++, say, doesn't mean it will work if it's only been coded against VC++ or GCC. It also has to be suitable for use with commercial software.- Our software currently has a COM interface, and part of the application can be automated with our app being the out-of-process COM server. We could add COM interfaces to some internal objects, or make a second COM framework specifically for this, if required.- The 'tools', including this one, are being migrated to a multithreaded framework. The end solution needs to be able to be , and . This may affect a hosted language runtime - Python 2.x, for example, has a global lock.- It would be great to use a language that comes with libraries for math or scientific use.- Backwards compatibility with the old expression tool is not important. This is version 2: clean slate! ## Current ideas: - [RemObjects Pascal Script](http://www.remobjects.com/ps.aspx)[DWScript](http://code.google.com/p/dwscript/)`TObject`- - [RemObjects Hydra](http://www.remobjects.com/hydra/mixedmode.aspx)- [Python, which is doable from RAD Studio](https://stackoverflow.com/questions/3446799/how-should-i-embed-python-in-a-c-builder-delphi-2010-application)- - Thanks for your input! I appreciate all answers even if they aren't quite perfect - I can research, I am just after pointers on where to go, and opinions (please, opinions with reasons included in the answer :p) on how to approach it or what might be suitable. Every answer, no matter how short, will be appreciated. But if you recommend something in detail rather than just "use language X" I'll be very interested in reading it :) Cheers, David ## Updates: The following have been recommended so far: - Python: 2.6 has a global lock, that sounds like a game-killer. 3 (apparently) doesn't yet have wide support from useful libraries. It sounds to me (and I know I'm an outsider to the Python community) like it's fragmenting a bit - is it really safe to use?- Lua: doesn't seem to be directly OO, but [provides "meta-mechanisms for implementing features, instead of providing a host of features directly in the language"](http://www.lua.org/about.html). That sounds very cool from a programmer point of view, but this isn't targeted at programmers wanting cool stuff to play around with. I'm not sure how well it would work given the target audience - I think a language which provides more basics built in would be better.- MS script / ActiveScript. We already provide an external COM interface which our users use to automate our software, usually in VBScript. However, I would like a more powerful (and, frankly, better designed) language than VBS, and I don't think JScript is suited either. I am also uncertain of what issues there might be marshalling data over COM - we have a lot of data, often very specifically typed, so speed and keeping those types are important.- Lisp: I hadn't even thought of that language, but I know it has lots of fans.- Hosting .Net plugins: not mentioned by anyone. Is this not a good idea? You get C#, F#, Python... Does it have the same marshalling issues COM might? (Does hosting the CLR work through COM?) by "matrix", I mean matrix in the Matlab variable sense, ie a huge table of values - not, say, a 4x4 transformation matrix as you might use for 3D software. It's data collected over time, thousands and thousands of values often many times a second. We're also not after a computer algebra system, but something where users can write full plugins and write their own math - although the system having the ability to handle complex math, like a computer algebra system can, would be useful. I would take 'full language' over 'algebra' though if the two don't mix, to allow complex branches / paths in user code, as well as an OO interface.
Recommendations for a scripting or plugin language for highly math-dependent user coding?
CC BY-SA 3.0
0
2011-06-01T07:53:43.087
2023-02-12T19:00:24.513
2017-05-23T10:27:23.413
-1
121,689
[ "c++", "delphi", "api", "plugins" ]
6,198,030
1
6,198,091
null
0
119
I'm trying to figure out the way to get all records from a table that have a specific column value AND that are NOT into a relational (many to many) table. Here's the model view: ![enter image description here](https://i.stack.imgur.com/mcCzZ.png) [http://i.stack.imgur.com/mcCzZ.png](https://i.stack.imgur.com/mcCzZ.png) I need all "testaction" with UserGroups_ID X, which can be done with: ``` from ta in qasEntities.TestActions where ta.UserGroups_ID.Equals(selectedUsergroupsId) select ta ``` How can I add a clause which would state: and where testaction has no relation to testcase Thanks
Linq to Entities: getting data with no relation (NOT IN)
CC BY-SA 3.0
null
2011-06-01T08:01:47.407
2011-06-01T08:08:15.973
2011-06-01T08:02:47.400
657,974
706,058
[ "asp.net", "linq-to-entities" ]
6,198,120
1
null
null
0
851
I have a NSPopUpButton which contains either English or Japanese Strings read from a plist file according to the System's Language. Now when the Language is English I am able to change the font size by using code such as - ``` [auxStatePopup setFont: [NSFont fontWithName:@"Helvetica-BoldOblique" size:10.0]]; ``` but Using such technique I am not able to change Japanese font size even if I tried by setting some Japanese font name which I googled and found out. I want to do that because Japanese characters move slightly up when used. I intend to manipulate that upward movement by decreasing font size. Thanks for any help.. ![Japanese alignement problem](https://i.stack.imgur.com/M1BL5.jpg) ![](https://i.stack.imgur.com/M1BL5.jpg) OR any way to move text in NSPopupButton downwards?
Changing Font Size of Japanese (Unicode) characters
CC BY-SA 3.0
null
2011-06-01T08:10:56.853
2012-04-29T21:56:32.073
2012-04-29T21:56:32.073
1,079,354
571,653
[ "cocoa", "unicode", "font-size", "nspopupbutton" ]
6,198,157
1
6,198,334
null
2
258
I am looking for help with generating this plot from a sequence of ones and zeros, in R. I am using it as one of a battery of tests to investigate whether a sequence is random or not (by looking for patterns in the noise). E.g., ``` > y <- rnorm(3000, 1, 2) > plot(y) >plot(y~y) ``` My data is in this form: ``` >str(hv10k) num [1:100000] 0 1 1 1 0 0 1 0 0 0 ... ``` ![rand1](https://i.stack.imgur.com/KbTFC.png) Update: Following @Roman Luštrik suggestions this is what I've got so far: 700 approx coin toss: ![700 approx coin toss](https://i.stack.imgur.com/jSXgv.png) 100,000 coin toss: ![100,000 coin toss](https://i.stack.imgur.com/22JGW.png)
Plot randomness
CC BY-SA 3.0
null
2011-06-01T08:14:48.533
2011-06-01T11:02:06.333
2011-06-01T09:45:09.270
471,431
471,431
[ "r", "random", "plot" ]
6,198,175
1
6,198,303
null
1
3,801
I need to be able to clone a drop down list and filter only those options that were NOT yet selected in the group of select lists. For example, having the following: ``` <select name="SelectService" class="selService"> <option value="1">Some service</option> <option value="2">Another one</option> <option value="3">One more</option> </select> ``` When i click the "clone" button it would clone the select list with ONLY those options that have NOT been yet selected. ex: select option "Some service" -> hit clone -> new select list is added with only option values: 2 and 3. etc..cloning and removing select lists would re-fill the select lists based on options selected so far. EDIT: to better visualize it here is the screen shot: ![enter image description here](https://i.stack.imgur.com/87eLJ.png) SCENARIO: 1. i start off with only 1 drop down list (that has 5 options) => 1,2,3,4,5 -> first options is selected by default. 2. I hit clone -> new list is added with ONLY options 2,3,4,5. 3. i select option 5 (in select list 2) 4. I hit clone -> new list (#3) is added with ONLY options 2,3,4 5. i select option 2 (in select list 3) 6. I hit clone -> new list (#4) is created with options 3,4 ..and so on. Now, When I remove Select list #2 (or any other select list) that means ALL select lists should re-fresh and include the selected option from deleted select list (in our case #2) Help. thanks
jquery remove/add select options after cloning select list
CC BY-SA 3.0
null
2011-06-01T08:16:30.957
2011-06-01T09:52:57.507
2011-06-01T09:25:00.403
455,042
455,042
[ "javascript", "jquery", "jquery-selectors" ]
6,198,277
1
6,199,565
null
20
12,770
What do the red and flesh coloured bars represent? ![Enter image description here](https://i.stack.imgur.com/PlHUA.png)
What do the colours mean in the TortoiseGit log window?
CC BY-SA 4.0
0
2011-06-01T08:26:47.093
2020-04-17T08:45:59.363
2018-08-21T08:11:56.630
63,550
775,390
[ "version-control", "tortoisegit" ]
6,198,317
1
6,198,357
null
1
157
How to communicate between my two web projects. 1) Firstly; You should look below pic which has got ddlCustomer(Dropdownlist) i will select a Customer. 2) i have a iframe which has a page i Want to write this customer to add this textbox... ![enter image description here](https://i.stack.imgur.com/FjYC1.png)
How to access any other web application's TextBox?
CC BY-SA 3.0
null
2011-06-01T08:30:23.490
2011-07-09T18:09:59.723
2011-07-09T18:09:59.723
213,550
298,875
[ "c#", "javascript", ".net", "asp.net", "iframe" ]
6,198,524
1
6,223,916
null
1
1,738
i'm using jqplot 1.0.0b1_r746. i want to display some time periods using the date axis renderer. the chart looks like as follows: ![chart](https://i.stack.imgur.com/SHfgY.png) now i would like to show the begin and end date as labels of one period. i have tried to use the pointLables plugin, but with no success.
jqplot show labels using date axis renderer
CC BY-SA 3.0
null
2011-06-01T08:49:20.063
2011-06-03T06:50:33.863
2011-06-01T12:16:54.007
455,070
455,070
[ "jquery", "jquery-plugins", "graph", "charts", "jqplot" ]
6,198,547
1
6,200,150
null
6
1,734
I'm currently trying to come up with a good and accessible way to format a status indicator which should be rendered within a set of wizard-like pages on a website. The website should provide a multipage form with a status indicator on top of it as demonstrated in the wireframe below: ![enter image description here](https://i.stack.imgur.com/szaQM.png) Given the new [progress](http://www.w3.org/TR/html5/the-button-element.html#the-progress-element)-tag in HTML my first thought was to do something like this: ``` <progress value="2" max="3"> <ul> <li>Beginning</li> <li class="now">Right now</li> <li>End</li> </ul> </progress> ``` ... but since <progress> only accepts phrasing content using a list is not really an option. So right now I would probably go with something like this, integratinng the ARIA [progressbar](http://www.w3.org/TR/wai-aria/roles#progressbar)-role: ``` <ul aria-role="progressbar" aria-valuenow="2" aria-valuemin="1" aria-valuemax="3" aria-describedby="state2" aria-valuetext="Right now"> <li id="state1">Beginning</li> <li id="state2" class="now">Right now</li> <li id="state3">End</li> </ul> ``` But again, I'm not really sure if the progressbar role can be applied in such a way to a list. Another problem is, that <progress> is rendered as progress bar in Opera, for instance, so >progress> itself is probably not really a viable solution altogether :-( Can anyone perhaps recommend an accessible status bar that does only rely on using a single image? ## Current solution For now I will go with following markup: ``` <section class="progress"> <h1 class="supportive">Your current progress</h1> <ol> <li><span class="supportive">Completed step:</span> Login</li> <li class="now"><span class="supportive">Current step:</span> Right now</li> <li><span class="supportive">Future step:</span> End</li> </ol> </section> ``` All elements of the class "supportive" will be positioned off-screen. IMO this way we should have a nice compromise of semantic markup (the state succession is in my opinion really an ordered list ;-)) and accessibility thanks to the additional header and status text for each step.
How to markup a complex status indicator in HTML5?
CC BY-SA 3.0
0
2011-06-01T08:52:02.537
2011-06-01T13:54:15.083
2011-06-01T13:54:15.083
22,312
22,312
[ "html", "accessibility", "wai-aria" ]
6,198,837
1
6,198,967
null
0
793
I want to create an application where I'll create an image from the application user's friends profile image. ![This is what i want](https://i.stack.imgur.com/reYmN.jpg) In this image there are 4 photos of friends, I want to create a new [single] image in that image all of the images will be pasted. What is the best way to go about doing this?
Create image from Friend's profile images - Facebook/PHP
CC BY-SA 3.0
null
2011-06-01T09:16:55.400
2012-10-29T12:49:13.257
2012-01-01T14:37:03.480
99,401
683,233
[ "php", "facebook", "facebook-graph-api" ]
6,198,917
1
6,199,179
null
3
4,257
i am trying to sign an apk by following [this](http://www.anddev.org/advanced-tutorials-f21/signing-your-apk-application-for-release-keytool-jarsigner-t3069.html) guide. 1. I created a keytools folder in C:\Users\Family\workspace\ and a keys folder in the newly created keytools folder. So now i have C:\Users\Family\workspace\keytools and C:\Users\Family\workspace\keytools\keys folders. 2. I copied the debug.keystore into the keys folder and copied the keytool.exe and jli.dll into the keytools folder. 3. I ran cmd.exe and navigated to C:\Users\Family\workspace\keytools and ran keytool -genkey -alias anddev.keystore -keyalg RSA -validity 20000 -keystore keys/anddev.keystore 4. The anddev.keystore file is created in the keys folder. 5. I copied the apk to be signed into the keytools folder. I also copied jarsigner.exe into the keytools folder. 6. In cmd.exe I am at C:\Users\Family\workspace\keytools and trying to run: jarsigner -verbose -keystore C:\Users\Family\workspace\keytools\keys\anddev.keystore -signedjar sampleapp_signed.apk sampleapp.apk anddev.keystore. It gives me this error: I also tried to run: jarsigner -verbose -keystore C:\Users\Family\workspace\keytools\keys\anddev.keystore -signedjar sampleapp_signed.apk sampleapp.apk C:\Users\Family\workspace\keytools\keys\anddev.keystore I have also tried to run: `jarsigner -verbose -keystore C:\Users\Family\workspace\keytools\keys\anddev.keystore -signedjar C:\Users\Family\workspace\keytools\sampleapp_signed.apk C:\Users\Family\workspace\keytools\sampleapp.apk C:\Users\Family\workspace\keytools\keys\anddev.keystore` When i navigate to c:\program files\java\jdk1.6.0_23\bin and run that code it asks for the keystore password and when I write the keystore pass (123456), it gives me an error: When i write anddev.keystore pass (=asdfgh, the second pass that keytool asked for at the end of the process) i get this error: (However, i am pretty sure this is rightful error, cause the pass is not this, but the 123456). I am pretty sure i am getting closer and that certificate chain error is the problem. Right? Am i missing a step or what? One another thing: in the command line when keytool asked for any password the cursor was not moving. I wrote the password but i didn't see any numbers or stars, or the cursor moving. It then asked for a reenter password, same happened. I guess this is ok, and a feature of the command line, i am just writing this to be sure. Based on the help of Hades and Saasha, it was extremely easy to sign the apk. For anyone interested here are my steps: For this i created a MyKeys folder into C:\Users\Family\workspace. After the process the sample.keystore and the samplesigned.apk appeared in that folder.![enter image description here](https://i.stack.imgur.com/lyzXU.png)
Android signing problem
CC BY-SA 3.0
null
2011-06-01T09:22:26.533
2011-08-26T03:19:55.327
2011-06-01T10:17:44.923
571,648
571,648
[ "android", "sign" ]
6,198,979
1
6,199,398
null
0
1,619
If I type a method name that does not exist, Eclipse always offers me a quick fix (ctrl+1 or cmd+1) to create the method. For example, if I type `handleIntent` which is a non-existant method, Eclipse suggests . However, in certain cases, Eclipse also suggests a quick fix that offers a different method as if I typed the name wrongly. In the above example Eclipse suggests as the first suggestion. After using Eclipse for so long, I'm accustomed to pressing ctrl+1 (or cmd+1) then Enter to create a new method. The spelling fix suggestion prevents me from doing that, and I can't predict beforehand whether Eclipse would offer me that spelling fix. I'm looking for a way to disable that spelling fix suggestion. ![Unwanted suggestion](https://i.stack.imgur.com/yUU1F.png)
Disabling Eclipse's spelling error quick fix
CC BY-SA 3.0
null
2011-06-01T09:26:15.643
2011-06-02T17:50:35.617
2011-06-01T19:18:20.190
21,234
11,238
[ "java", "eclipse" ]
6,198,997
1
6,199,202
null
1
173
I have an ImageView, it shows an image from resource. ImageView's widht is fixed (60dp). Height is set as wrap_content. The image is resized to fit to this width (saving aspect ration - this is perfect) The problem is that android sets actual height to the image's heights before resizing. But I want this image to have exactly 60dp in width and height should be equal to image's height after resizing. Here is layout ``` <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent"> <ImageView android:layout_width="60dp" android:layout_height="wrap_content" android:src="@drawable/sample" android:background="#F0F0"/> </LinearLayout> ``` ![enter image description here](https://i.stack.imgur.com/uVt77.png)
Actual view's height is not fitted to proper content
CC BY-SA 3.0
0
2011-06-01T09:27:46.213
2011-06-01T09:44:38.507
null
null
120,574
[ "android", "imageview", "scale" ]
6,199,063
1
6,199,141
null
0
471
I have a list view with a custom layout. In the layout I display a series of comments. The problem is the image I've set as the background gets stretched when the comments are too long. I know I could probably use a nine patch but the question is would it really work? If not what alternative do I have? Could someone recommend the best of handling this. ![what happens to the image](https://i.stack.imgur.com/c8m2Y.png) ![enter image description here](https://i.stack.imgur.com/LifSc.png) `<TextView android:id="@+id/txtCommentBody" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="" android:textColor="@color/black" android:paddingTop="25dip" android:paddingLeft="5dip" android:paddingRight="5dip" android:layout_marginTop="10dip" android:background="@drawable/comment_bg"> </TextView>`
image rendering nine patch
CC BY-SA 3.0
null
2011-06-01T09:32:19.233
2012-10-28T19:02:21.297
2011-06-01T10:51:59.687
311,001
311,001
[ "android", "graphics", "nine-patch" ]
6,199,129
1
6,199,216
null
1
298
below error message pop-ups whenever i start any .....of what should i have to do for come out of it??? ![Error Message Every time i start any solutions of VS2010](https://i.stack.imgur.com/29g4U.png)
Error messag pop up, when i start any solution in VS2010
CC BY-SA 3.0
null
2011-06-01T09:37:35.420
2011-06-01T12:12:47.433
2011-06-01T12:12:47.433
468,968
468,968
[ "visual-studio-2010" ]
6,199,380
1
15,593,782
null
1
850
Several of my customers asked me to implement graphical password checker like ![like here](https://i.stack.imgur.com/jISLm.png) Any ideas how to implement this kind of UI?
Android graphical login/passcode
CC BY-SA 3.0
0
2011-06-01T09:58:46.220
2013-03-24T00:38:40.520
null
null
472,270
[ "android", "graphics", "authentication", "password-protection" ]
6,199,622
1
6,203,355
null
3
5,840
Hey. A lot of my colleagues use the Netbeans IDE for a few reasons and I would like to as well, however unlike them, I can't get over the look of the menus: ![Comparison of Eclipse and Netbeans](https://i.stack.imgur.com/I9xPj.png) Is there anything I can do to make the Netbeans menus look the same as the Eclipse menus? Thanks.
Netbeans menu is awful in Ubuntu - completely unreadable and bleh to look at. Any fixes?
CC BY-SA 3.0
0
2011-06-01T10:20:13.480
2012-08-13T07:10:52.070
null
null
null
[ "linux", "eclipse", "netbeans", "ubuntu" ]
6,199,658
1
6,199,883
null
1
285
I'm using the following code to find the newest .zip file in a directory but it doesn't seem to be coping with the switch to June and still shows the newest file as yesterdays. When I ran the script today it showed a file from 31/05/2011 06:05 as the latest but there are two newer files than this (see screenshot) ``` For Each aFile In ImportFldr.Files sExtension = fso.GetExtensionName(aFile.Name) If sExtension = "log" Then 'Msgbox "The file extension is a " & sExtension Else 'Msgbox "The file extension is a " & sExtension If fileNewest = "" Then Set fileNewest = aFile Else If fileNewest.DateCreated < aFile.DateCreated Then Set fileNewest = aFile End If End If End If Next ``` ![screenshot of the directory showing files and there timestamps](https://i.stack.imgur.com/5BlvX.png) Thanks
vbscript .DateCreated not coping with new month
CC BY-SA 3.0
null
2011-06-01T10:23:19.813
2011-06-01T10:42:36.067
null
null
523,938
[ "vbscript" ]
6,199,680
1
null
null
2
1,954
I am trying to sign my webworks application in SDK 2.0.4 and following steps from [http://docs.blackberry.com/en/developers/deliverables/27280/Configure_signing_for_tablet_applications_1476061_11.jsp](http://docs.blackberry.com/en/developers/deliverables/27280/Configure_signing_for_tablet_applications_1476061_11.jsp). When i execute following command ``` blackberry-keytool -genkeypair -keystore -torepass xxxxx -dname "My Company Name" -alias author ``` I get the following error ``` keytool error : java.io.IOExceotion: Incorrect AVA format ``` as you can see in the screenshot ![enter image description here](https://i.stack.imgur.com/VRabZ.png) I have no idea what does it means, it would be nice if someone can help.
Incorrect AVA Format : BlackBerry WebWorks SDK
CC BY-SA 3.0
null
2011-06-01T10:24:59.260
2011-11-21T15:07:36.943
2011-11-21T15:07:36.943
310,760
295,463
[ "java", "blackberry", "keytool", "jar-signing" ]
6,200,070
1
6,206,229
null
0
537
![Database](https://i.stack.imgur.com/KKXbC.png) I am implementing a database so I have coded like... ``` string MyConString = ConfigurationManager.ConnectionStrings["College_Management_System.Properties.Settings.cmsConnectionString"].ConnectionString; MySqlConnection connection = new MySqlConnection(MyConString); MySqlCommand command = connection.CreateCommand(); MySqlDataReader Reader; command.CommandText = "select * from menu_right"; connection.Open(); Reader = command.ExecuteReader(); while (Reader.Read()) { if (Reader[2].ToString() == Convert.ToString(0)) { treeView1.Nodes.Add(Reader[3].ToString(), Reader[1].ToString()); } if (Reader[2].ToString() == Convert.ToString(1)) { treeView1.Nodes[0].Nodes.Add(Reader[3].ToString(), Reader[1].ToString()); } if (Reader[2].ToString() == Convert.ToString(4)) { treeView1.Nodes[1].Nodes.Add(Reader[3].ToString(), Reader[1].ToString()); } if (Reader[2].ToString() == Convert.ToString(18)) { treeView1.Nodes[1].Nodes[0].Nodes.Add(Reader[3].ToString(), Reader[1].ToString()); } } connection.Close(); ``` but it throw an error, > Specified argument was out of the range of valid values. Parameter name: index at, ``` treeView1.Nodes[1].Nodes[0].Nodes.Add(Reader[3].ToString(), Reader[1].ToString()); ``` what is the problem in my code.?. Is any other way to simplify code for my requirement?
How to generate 3 node treeview in winforms with mysql?
CC BY-SA 3.0
null
2011-06-01T10:59:26.083
2012-12-18T06:37:29.203
2012-12-18T06:37:29.203
1,887,603
776,226
[ "c#", "winforms", "treeview" ]
6,200,088
1
6,200,272
null
13
19,521
Here is a short part of my data: ``` dat <-structure(list(sex = structure(c(1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 1L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L, 2L), .Label = c("male", "female"), class = "factor"), A = c(1, 2, 0, 2, 1, 2, 2, 0, 2, 0, 1, 2, 2, 0, 0, 2, 0, 0, 0, 2), B = c(0, 0, 0, 0, 0, 2, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0), C = c(1, 2, 1, 0, 0, 2, 1, 1, 0, 1, 1, 0, 1, 2, 1, 2, 0, 2, 1, 2), D = c(2, 2, 0, 2, 2, 2, 1, 0, 1, 1, 1, 0, 1, 2, 0, 0, 1, 1, 1, 0), E = c(0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 2, 0, 0, 0, 1, 2, 2), F = c(2, 2, 1, 2, 1, 2, 2, 0, 1, 2, 0, 1, 2, 2, 0, 1, 2, 2, 2, 2)), .Names = c("sex", "A", "B", "C", "D", "E", "F"), variable.labels = structure(c("sex", "zenuwac", "panieke", "gespann", "rustelo", "angstig", "onzeker" ), .Names = c("sex", "anx01", "anx02", "anx03", "anx04", "anx05", "anx06")), codepage = 20127L, row.names = c(NA, 20L), class = "data.frame") ``` A data frame with scores of males and females on six 3-point variables. Now I want to create a plot which shows the histograms of the scores of each variable of both males and females in a grid. For example, I can do: ``` layout(matrix(1:12,6,2,byrow=TRUE)) par(mar=c(2,1,2,1)) for (i in 1:6) for (s in c("male","female")) hist(dat[dat$sex==s,i+1],main=paste("item",names(dat)[i+1],s)) ``` which results in: ![Histogram with base R graphics](https://i.stack.imgur.com/OnI4X.png) I could make this look better but I am more interested in learning how to use ggplot2. So my question is, how do I create a pretty version of this using ggplot2? One thing I got working is: ``` library("ggplot2") grid.newpage() pushViewport(viewport(layout = grid.layout(6, 2))) for (s in 1:2) { for (i in 1:6) { p <- qplot(dat[dat$sex==c("male","female")[s],i+1]+0.5, geom="histogram", binwidth=1) print(p, vp = viewport(layout.pos.row = i, layout.pos.col = s)) } } ``` But I guess there is a much easier way to do this?
Multiple histograms in ggplot2
CC BY-SA 3.0
0
2011-06-01T11:00:59.373
2011-06-01T15:12:50.270
null
null
567,015
[ "r", "ggplot2", "histogram" ]
6,200,175
1
null
null
0
2,279
I have been using Yii with MAMP for the last week without problem. However, today, I set up a new project, created a database and tried to use Gii to create a new model but it's giving me a message "table name doesn't exist." I have confirmed many times that such a table exists in PHP MY Admin. I also did a reinstall on MAMP and have the same problem Can anyone see what the problem might be ![databse test1](https://i.stack.imgur.com/5Q5N0.png) This is my configuration in the Yii config file ``` 'db'=>array( 'connectionString' => 'mysql:host=localhost;port:8889;dbname=test1', 'emulatePrepare' => true, 'username' => 'root', 'password' => 'root', 'charset' => 'utf8', ), ``` ![enter image description here](https://i.stack.imgur.com/aL1as.png)
says table doesn't exist
CC BY-SA 3.0
null
2011-06-01T11:08:25.757
2011-06-01T11:14:08.730
null
null
588,498
[ "php", "mysql", "yii", "mamp" ]
6,200,228
1
6,200,331
null
2
2,021
after spending hours of figuring out how to sign an app (at last i used eclipse, and not the command line), i want to create a key hash to my app described [here](https://developers.facebook.com/docs/guides/mobile/#android_key_hash). For this i have in the C:\Users\Family\workspace\MyKeys folder the created sample.keystore and the samplesigned.apk, as well as the keytool.exe and the jli.dll. In cmd.exe i navigated to C:\Users\Family\workspace\MyKeys and when i run this command: `keytool -exportcert -alias samplekey -keystore sample.keystore` i get this jibberish:![enter image description here](https://i.stack.imgur.com/sqFxp.png) The samplekey is the alias of the key created in eclipse: ![enter image description here](https://i.stack.imgur.com/OCjNX.png) I download open ssl from [here](http://gnuwin32.sourceforge.net/packages/openssl.htm) and installed it into C:\Program Files\GnuWin32. Navigating here in the command line i tried this command: openssl -help, which resulted in a list of commands which means i installed it properly (i hope). Now i try this code: ``` C:\Users\Family\workspace\MyKeys>keytool -exportcert -alias samplekey -keystore sample.keystore | c:\program files\gnuwin32\bin\openssl sha1 -binary | c:\program f iles\gnuwin32\bin\openssl base64 ``` Error: I have also added C:\Program Files\GnuWin32\bin to the PATH in Environmental Variables. I'm kind of lost.
Android facebook key hash
CC BY-SA 3.0
0
2011-06-01T11:12:37.837
2011-07-12T11:43:12.187
null
null
571,648
[ "android", "sign" ]
6,200,486
1
6,201,390
null
2
452
is it possible to limit number of copies (from code) which user is allowed to print? ![iOS Printing UI](https://i.stack.imgur.com/oQQtj.png)
iOS Printing UI - limit number of copies
CC BY-SA 3.0
0
2011-06-01T11:37:41.213
2011-06-01T12:48:42.890
null
null
299,063
[ "iphone", "ios", "ipad", "printing" ]
6,200,601
1
null
null
0
181
I am building an Webpage that uses SVG, Canvas and, of course, HTML. The idea of this page is to animate the redrawing of some of svg-paths on the canvas. The paths I like to redraw are annotated with an namespace Attribute, all other paths are just displayed as they are. That is all working fine! The performance leak appeared the last two hours while I was adding some content to the page. But at first a little illustration of the page setup: ![decription of the page setup](https://i.stack.imgur.com/RvXd7.png) The SVG and the Canvas are both 4000 * 4000 px wide and lie directly over each other in one container div. Going from one "page" to another means to tween the upper left edge of this container. This was also working fine since the discussion of inserting text turned in the direction of using html div container, instead of the svg itself. So i inserted a third container div in which all the texts are stored and after svg is loaded they are positioned absolutly. With every div I added the "pan-tween" and even the drawing performance decreased to a Point that is just too low. I am searching for way to bring the performance back to a level that is acceptable for the user. One of my ideas is to set text divs to display : none, or visibility : hidden, as long as they are not displayed actually. Another option is to tween only svg and canvas, after this is finished placing the text-div-container in one step. But I am currently not sure which solution is better, or if there isn't something much better. So if anybody has an Idea, please let me know. Thanks for reading! Greetings Philipp
Performance Issue on an HTML5 Website
CC BY-SA 3.0
null
2011-06-01T11:47:33.627
2011-06-03T19:26:28.207
null
null
687,901
[ "javascript", "html", "canvas", "svg" ]
6,200,670
1
6,200,727
null
0
270
I'm trying to create a simple layout but can't find a propper way to do it. Layout should have 3 elements: TextView on top, EditText (with scrollview) in the middle and button on bottom. I made this code: ``` <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:weightSum="1" android:orientation="vertical" android:layout_height="fill_parent" android:layout_width="fill_parent"> <LinearLayout android:layout_weight="0.97" android:layout_height="wrap_content" android:layout_width="fill_parent" android:id="@+id/linearLayout18" android:orientation="vertical"> <TextView android:layout_width="fill_parent" android:layout_height="wrap_content" android:text="Text:" android:gravity="center_vertical"/> <ScrollView android:layout_width="fill_parent" android:layout_height="fill_parent"> <EditText android:layout_width="fill_parent" android:layout_height="fill_parent" android:id="@+id/txtMessage" android:text=""/> </ScrollView> </LinearLayout> <LinearLayout android:layout_weight="0.03" android:layout_height="wrap_content" android:layout_width="fill_parent" android:id="@+id/linearLayout1" android:orientation="vertical"> <Button android:text="Next" android:id="@+id/button1" android:layout_width="fill_parent" android:layout_height="wrap_content" /> </LinearLayout> </LinearLayout> ``` But it gives me layout like this: ![Layout](https://i.stack.imgur.com/32CCU.jpg) As you can see the problem is that EditText won't take all available vertical space (all the way to button). How to solve this?
Android layout problem
CC BY-SA 3.0
null
2011-06-01T11:52:32.380
2015-12-05T09:32:16.470
2011-06-01T11:54:11.317
463,721
551,588
[ "android", "layout" ]
6,200,932
1
null
null
3
9,023
I am trying to build a demo application to test how can i debug or launch my android application on real device. I have Froyo Android, OSX laptop and Flash Builder 4 IDE. I build a very simple application, please have a look on image below: ![enter image description here](https://i.stack.imgur.com/N8BDg.jpg) in this when user click on "Click Me" button an email and address will be display in bottom textArea. Application is working fine on Flash Builder 4 emulator but when i try to debug application on my device, it prompt me the error below: > Error occurred while installing the application: 1580 KB/s (6108444 bytes in 3.773s) pkg: /data/local/tmp/Runtime.apk Failure [INSTALL_FAILED_INVALID_APK] or when i create .apk file and try to install it on my device, Again it says me "Error in installation". Please guide me, how can i fix that issue. Many Thanks
Prompting INSTALL_FAILED_INVALID_APK while debugging Flash Builder 4 mobile app on real device
CC BY-SA 3.0
null
2011-06-01T12:13:39.187
2013-10-08T10:56:01.733
null
null
171,336
[ "android", "air", "flash-builder", "flashbuilder4", "flex4.5" ]
6,200,951
1
6,200,971
null
12
4,614
I am using TortoiseSVN I imported some file to the server. Then I deleted all imported files from server. But my folder in windows explorer is diplayed with SVN icon. How can I removed it? ![enter image description here](https://i.stack.imgur.com/jXXNS.jpg)
Need to unbind local folder from SVN
CC BY-SA 3.0
0
2011-06-01T12:14:54.490
2018-12-06T04:54:27.580
null
null
207,047
[ "svn", "tortoisesvn" ]
6,200,942
1
6,257,617
null
0
201
I have a table containing some data which needs to be displayed in a certain format on screen. The table structures are as follows: ``` CREATE TABLE [dbo].[JobSheet]( [JobSheetID] [bigint] IDENTITY(1,1) NOT NULL, [SheetNumber] [bigint] NULL, [JobSheetDate] [datetime] NULL, [ContractID] [bigint] NULL, [ContractCode] [varchar](50) NULL, [ContractTitle] [varchar](100) NULL, [ProjectID] [bigint] NULL, [ProjectCode] [varchar](50) NULL, [ProjectTitle] [varchar](100) NULL, [JobID] [bigint] NULL, [JobCode] [varchar](50) NULL, [JobTitle] [varchar](100) NULL, [SageDatabaseID] [bigint] NULL, [SageDatabaseName] [varchar](50) NULL, [EnteredByID] [bigint] NULL, [EnteredByUsername] [varchar](50) NULL, [DocumentStatus] [varchar](50) NULL, [Deleted] [bit] NULL, [Reference] [varchar](50) NULL, [UpdatedDate] [datetime] NULL, [UpdatedUser] [varchar](50) NULL, [SentToSage] [bit] NULL, [UpdateStatus] [varchar](50) NULL, CONSTRAINT [PK_JobSheet] PRIMARY KEY CLUSTERED ( [JobSheetID] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY] ) ON [PRIMARY] GO CREATE TABLE [dbo].[JobSheetLine]( [JobSheetLineID] [bigint] IDENTITY(1,1) NOT NULL, [JobSheetID] [bigint] NULL, [LineType] [varchar](50) NULL, [TSHumanResourceID] [bigint] NULL, [SageDatabaseID] [bigint] NULL, [Surname] [varchar](50) NULL, [Initial] [varchar](1) NULL, [TimeOn] [datetime] NULL, [TimeOff] [datetime] NULL, [Deleted] [bit] NULL, [B1] [decimal](18, 5) NULL, [B15] [decimal](18, 5) NULL, [B2] [decimal](18, 5) NULL, [HB] [decimal](18, 5) NULL, [S1] [decimal](18, 5) NULL, [S15] [decimal](18, 5) NULL, [S2] [decimal](18, 5) NULL, [HS] [decimal](18, 5) NULL, [O1] [decimal](18, 5) NULL, [T] [decimal](18, 5) NULL, [TS] [decimal](18, 5) NULL, [TT] [decimal](18, 5) NULL, [TP] [decimal](18, 5) NULL, [OT] [decimal](18, 5) NULL, [OS] [decimal](18, 5) NULL, [D] [decimal](18, 5) NULL, [POA] [decimal](18, 5) NULL, [PT1] [decimal](18, 5) NULL, [PT2] [decimal](18, 5) NULL, [CustomCostRate1] [decimal](18, 5) NULL, [CustomCostRate1ID] [bigint] NULL, [CustomCostRate2] [decimal](18, 5) NULL, [CustomCostRate2ID] [bigint] NULL, [CustomCostRate3] [decimal](18, 5) NULL, [CustomCostRate3ID] [bigint] NULL, [CustomCostRate4] [decimal](18, 5) NULL, [CustomCostRate4ID] [bigint] NULL, [CustomCostRate5] [decimal](18, 5) NULL, [CustomCostRate5ID] [bigint] NULL, [CustomCostRate6] [decimal](18, 5) NULL, [CustomCostRate6ID] [bigint] NULL, [UpdatedDate] [datetime] NULL, [UpdatedUser] [varchar](50) NULL, [RejectReason] [varchar](255) NULL, [CurrentStepApprovalCount] [bigint] NULL, [CustomRouteID] [bigint] NULL, [CustomRoute] [bit] NULL, [CurrentStep] [bigint] NULL, [WaitingForType] [varchar](50) NULL, [WaitingForID] [bigint] NULL, [RequestedByID] [bigint] NULL, [LineStatus] [varchar](50) NULL, CONSTRAINT [PK_JobSheetLine] PRIMARY KEY CLUSTERED ( [JobSheetLineID] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY] ) ON [PRIMARY] GO ``` The data is entered on a screen like this which may show the format of the JobSheetLineTable better: ![enter image description here](https://i.stack.imgur.com/dpSf2.png) The required format I need to get the data out is like the screenshot below: ![enter image description here](https://i.stack.imgur.com/Q74Uh.jpg) The Data needs to be filtered by employee (RequestedByID in the JobSheetLine table) and each unique, Contract and Project, and Cost Rate (the cost rates run from B1, B15, B2 etc all the way to CustomCostRate6). The total number of hours for each cost rate needs to be per day. I have got as far as the query below until I relized this is not going to work. I think the problem is caused due to the cost rates being Columns in the JobSheetLine table, but the required output has the cost rate as a single column and rates and values appear on the rows. I looked into using the PIVOT keyword in SQL but I couldn't work out what I was doing with it. Here is the query I have come up with so far (which wont work) ``` DECLARE @Deleted AS BIT DECLARE @RequestedByID AS BIGINT DECLARE @WeekStartDate AS DATETIME DECLARE @WeekEndDate AS DATETIME DECLARE @WaitingForUserID AS BIGINT DECLARE @WaitingForUserTypeID AS BIGINT DECLARE @WaitingForTypeUser AS VARCHAR(50) DECLARE @WaitingForTypeUserType AS VARCHAR(50) SET @Deleted = 0 SET @RequestedByID = 2 SET @WeekStartDate = '2011/05/23 00:00' SET @WeekEndDate = '2011/05/29 00:00' SELECT [JobSheet].[JobSheetDate], [JobSheet].[ContractID], [JobSheet].[ContractCode], [JobSheet].[ContractTitle], [JobSheet].[ProjectID], [JobSheet].[ProjectCode], [JobSheet].[ProjectTitle], [JobSheet].[JobID], [JobSheet].[JobCode], [JobSheet].[JobTitle], [JobSheet].[SageDatabaseID], ISNULL(SUM([JobSheetLine].[B1]),0) AS B1, ISNULL(SUM([JobSheetLine].[B15]),0) AS B15, ISNULL(SUM([JobSheetLine].[B2]),0) AS B2, ISNULL(SUM([JobSheetLine].[HB]),0) AS HB, ISNULL(SUM([JobSheetLine].[S1]),0) AS S1, ISNULL(SUM([JobSheetLine].[S15]),0) AS S15, ISNULL(SUM([JobSheetLine].[S2]),0) AS S2, ISNULL(SUM([JobSheetLine].[HS]),0) AS HS, ISNULL(SUM([JobSheetLine].[O1]),0) AS O1, ISNULL(SUM([JobSheetLine].[T]),0) AS T, ISNULL(SUM([JobSheetLine].[TS]),0) AS TS, ISNULL(SUM([JobSheetLine].[TT]),0) AS TT, ISNULL(SUM([JobSheetLine].[TP]),0) AS TP, ISNULL(SUM([JobSheetLine].[OT]),0) AS OT, ISNULL(SUM([JobSheetLine].[OS]),0) AS OS, ISNULL(SUM([JobSheetLine].[D]),0) AS D, ISNULL(SUM([JobSheetLine].[POA]),0) AS POA, ISNULL(SUM([JobSheetLine].[PT1]),0) AS PT1, ISNULL(SUM([JobSheetLine].[PT2]),0) AS PT2, ISNULL(SUM([JobSheetLine].[CustomCostRate1]),0) AS CustomCostRate1, ISNULL(SUM([JobSheetLine].[CustomCostRate2]),0) AS CustomCostRate2, ISNULL(SUM([JobSheetLine].[CustomCostRate3]),0) AS CustomCostRate3, ISNULL(SUM([JobSheetLine].[CustomCostRate4]),0) AS CustomCostRate4, ISNULL(SUM([JobSheetLine].[CustomCostRate5]),0) AS CustomCostRate5, ISNULL(SUM([JobSheetLine].[CustomCostRate6]),0) AS CustomCostRate6, ISNULL(SUM([JobSheetLine].[B1] + [JobSheetLine].[B15] + [JobSheetLine].[B2] + [JobSheetLine].[HB] + [JobSheetLine].[S1] + [JobSheetLine].[S15] + [JobSheetLine].[S2] + [JobSheetLine].[HS] + [JobSheetLine].[O1] + [JobSheetLine].[T] + [JobSheetLine].[TS] + [JobSheetLine].[TT] + [JobSheetLine].[TP] + [JobSheetLine].[OT] + [JobSheetLine].[OS] + [JobSheetLine].[D] + [JobSheetLine].[POA] + [JobSheetLine].[PT1] + [JobSheetLine].[PT2] + [JobSheetLine].[CustomCostRate1] + [JobSheetLine].[CustomCostRate2] + [JobSheetLine].[CustomCostRate3] + [JobSheetLine].[CustomCostRate4] + [JobSheetLine].[CustomCostRate5] + [JobSheetLine].[CustomCostRate6]),0) AS TotalHours FROM [JobSheet] INNER JOIN [JobSheetLine] ON [JobSheetLine].[JobSheetID]=[JobSheet].[JobSheetID] WHERE [JobSheet].[Deleted]=@Deleted AND [JobSheet].[JobSheetDate] >= @WeekStartDate AND [JobSheet].[JobSheetDate] <= @WeekEndDate AND [JobSheetLine].[Deleted]=@Deleted AND [JobSheetLine].[RequestedByID]=@RequestedByID GROUP BY [JobSheet].[JobSheetDate], [JobSheet].[ContractID], [JobSheet].[ContractCode], [JobSheet].[ContractTitle], [JobSheet].[ProjectID], [JobSheet].[ProjectCode], [JobSheet].[ProjectTitle], [JobSheet].[JobID], [JobSheet].[JobCode], [JobSheet].[JobTitle], [JobSheet].[SageDatabaseID] ``` Is it possible to achieve the output I want with the structure of the data as it is at the moment? I would rather do all the calculation in SQL as its faster but I can do some of the calculation in C# as this is an asp.net project.
Is this possible in SQL?
CC BY-SA 3.0
null
2011-06-01T12:14:25.700
2011-06-06T20:26:08.413
2011-06-01T12:26:50.583
125,981
428,404
[ "asp.net", "sql", "sql-server" ]
6,200,992
1
6,341,637
null
1
301
I have downloaded latest openframeworks library from github. I am able to run all mac examples. But I dont know whats wrong with iphone samples. None of the iphone examples are running. Showing lots of error everytime. Is it problem with existing code or I have to do some settings ? > Update: These are list of few errors: ![enter image description here](https://i.stack.imgur.com/NQgPI.png)
openframeworks library problem with iphone apps only not with mac apps
CC BY-SA 3.0
null
2011-06-01T12:18:01.393
2011-06-14T09:35:26.943
2011-06-14T08:40:00.217
213,532
213,532
[ "iphone", "opencv", "openframeworks" ]
6,201,018
1
6,201,086
null
30
6,210
is there a way to REMOVE COMPLETELY the pin tab option in visual studio 2010 (how?), i keep clicking it by accident :( i never use it and always click it by accident. ![pin that i need removed](https://i.stack.imgur.com/yApFZ.png) thnx p.s. right clicking on the PIN icon does bring up some customize dialog, but was unable to remove it - couldn't recognize the option. ![config dialog that appears on right clicking the PIN icon](https://i.stack.imgur.com/KAksW.png)
how to remove visual studio PIN TAB icon (on tabs, obviously)
CC BY-SA 3.0
0
2011-06-01T12:19:44.890
2019-04-03T20:41:44.023
2011-06-01T12:41:35.127
32,746
101,055
[ "visual-studio", "visual-studio-2010", "user-interface", "productivity-power-tools" ]
6,201,236
1
null
null
0
158
i created Wpf projext but i can see blue icon at my home but at my company undefined icon. Where is blue icon? ![enter image description here](https://i.stack.imgur.com/FS5qQ.png)
Where is My Xaml icon?
CC BY-SA 3.0
0
2011-06-01T12:35:31.470
2011-06-01T13:11:34.540
null
null
298,875
[ "wpf", "visual-studio-2010", "silverlight-4.0" ]
6,201,231
1
6,202,936
null
1
921
I'm working on QTP with web-adding. There are some buttons in type "Winbutton" on the page. The "click" action on most of the buttons works very well except one. In fact this winbutton is a checkbox. But I don't know why it is recognized as Winbutton. But when click on it, it just gets focused but not really clicked. The checkbox is not checked. So I would like to know if anyone met the similar problem before and if anyone knows how to solve this. Many thanks in adavance Allen ![The Winbutton](https://i.stack.imgur.com/B5eLZ.png) [http://i.stack.imgur.com/B5eLZ.png](https://i.stack.imgur.com/B5eLZ.png) ![Description](https://i.stack.imgur.com/XZDwl.png) [http://i.stack.imgur.com/XZDwl.png](https://i.stack.imgur.com/XZDwl.png)
QTP click on winbutton with failure
CC BY-SA 3.0
null
2011-06-01T12:35:05.103
2011-06-06T14:34:23.017
2011-06-01T15:41:41.347
284,960
284,960
[ "click", "qtp" ]
6,201,249
1
6,201,320
null
2
5,256
Hi I have my own ServiceBehavior: ``` public class StructureMapServiceBehavior : IServiceBehavior { public void ApplyDispatchBehavior(ServiceDescription serviceDescription, ServiceHostBase serviceHostBase) { foreach (ChannelDispatcherBase cdb in serviceHostBase.ChannelDispatchers) { ChannelDispatcher cd = cdb as ChannelDispatcher; if (cd != null) { foreach (EndpointDispatcher ed in cd.Endpoints) { ed.DispatchRuntime.InstanceProvider = new StructureMapInstanceProvider(serviceDescription.ServiceType); } } } } public void AddBindingParameters(ServiceDescription serviceDescription, ServiceHostBase serviceHostBase, Collection<ServiceEndpoint> endpoints, BindingParameterCollection bindingParameters) { } public void Validate(ServiceDescription serviceDescription, ServiceHostBase serviceHostBase) { } } ``` How i can add it in App.config with WCF configuration tool ? : ![WCF configuration tool](https://i.stack.imgur.com/MRnQ1.png)
WCF: How add me custom ServiceBehavior into WCF configuration
CC BY-SA 3.0
null
2011-06-01T12:36:31.580
2011-06-01T17:16:40.643
2011-06-01T17:16:40.643
751,090
600,082
[ "wcf", "app-config" ]
6,201,272
1
6,201,394
null
15
9,499
Sometimes I start a MATLAB script and realize too late that it is going to output way too many figures. Eventually I get an > Exception in thread "AWT-EventQueue-0" java.lang.OutOfMemoryError: Java heap space which can easily be reproduced on my machine using ``` for i=1:inf figure; end ``` I get to around ~90 figures before it crashes with the standard setting ([Preferences / Java Heap Memory](http://www.mathworks.com/help/techdoc/matlab_env/brjh09y-1.html#bsemees-1)) of 128 MB Java heap, while doubling the Heap to 256 MB gives me around 200 figures. If there is not enough memory for another figure, I'd like my script to be rather than crash. Maybe I could have a wrapper for `figure` which (somehow?) checks how much Java heap is available and which refuses to open a new figure if there is not enough space left? Using the answers below, I get a nice graph for how much free Memory Java has: ![figure;plot(freeMem/1E6,'x');ylabel('java.lang.Runtime.getRuntime.freeMemory [MB]');xlabel('number of empty figures created');](https://i.stack.imgur.com/EMnHC.png) This was produced using ``` for i=1:inf java.lang.Runtime.getRuntime.gc fprintf('%3.0f: %1.0f Byte free\n',i,java.lang.Runtime.getRuntime.freeMemory); figure; end ``` I assume the increase in the beginning means that garbage collection only does a certain effort every time I call it? Using the help I got here, I implemented the following solution as a `figure.m` which overloads and calls the build-in `figure` command: ``` function varargout=figure(varargin) memcutoff = 10E6; % keep at least this amount of bytes free memkeyboard= 3E6; % if memory drops below this, interrupt execution and go to keyboard mode global refuse_new_figures if refuse_new_figures warning('jb:fig:lowjavamem2','Java WAS memory low -> refusing to create a new figure. To reset, type "global refuse_new_figures ; refuse_new_figures = [];"'); return end freemem=java.lang.Runtime.getRuntime.freeMemory; if freemem < memcutoff fprintf('Free memory is low (%1.0f Bytes) -> running garbace collector...\n',freemem); java.lang.Runtime.getRuntime.gc end freemem=java.lang.Runtime.getRuntime.freeMemory; % fprintf('Free memory is %1.0f Bytes.\n',freemem); if freemem < memkeyboard warning('jb:fig:lowjavamem','Java memory very low -> going into interactive mode. Good luck!'); keyboard; end if freemem < memcutoff warning('jb:fig:lowjavamem','Java memory low -> refusing to create a new figure!'); refuse_new_figures=true; else if nargin > 0 if nargout > 0 varargout{1}=builtin('figure',varargin{:}); else builtin('figure',varargin{:}); end else if nargout > 0 varargout{1}=builtin('figure'); else builtin('figure'); end end end ```
How to avoid MATLAB crash when opening too many figures?
CC BY-SA 3.0
0
2011-06-01T12:38:46.883
2016-08-16T07:29:35.527
2011-06-20T08:44:47.517
669,202
669,202
[ "java", "matlab", "heap-memory", "jvm-crash" ]
6,201,651
1
null
null
2
5,443
Facebook like button with "button_count" layout shows rounded number e.g 13K. ![enter image description here](https://i.stack.imgur.com/ABusE.png) The current standard also shows something else. How to show full number of likes?
How to show full number of likes near facebook like button with "button_count" layout
CC BY-SA 3.0
0
2011-06-01T13:08:18.317
2013-08-25T11:45:56.847
2013-08-25T11:45:56.847
569,677
779,337
[ "facebook", "button", "facebook-like" ]