|
I recently was given a small USB flash drive as an advertising gimmick. When I plug it in, only one drive appears: a CD drive with 42kb used (just an autorun.inf file which launches the manufacturer's website). I know U3 drives also appear as CD drives...
Started by mmyers on
, 7 posts
by 7 people.
Answer Snippets (Read the full thread at stackoverflow):
Ok, there is 2 questions here :
1) How can I make it appear as a USB drive, if I wanted to do the same thing for myself, how would I make it appear as a CD drive?
Basically same.
Access to the hardware.
|
|
Hi, I have a datagridview and I am writing integers in to one of the columns, I would like these values not to have a comma in them when the value >= 1000. But at the moment, when i enter a value which is >= 1000 they appear in the form '1,000',...
Started by ThePower on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
This may help :
dataGridView1.Columns["NumericColumn"].DefaultCellStyle.Format = "d";
How to: Format Data in the Windows Forms DataGridView Control
Standard Numeric Format Strings
the comma could be translated incorrectly in certain areas
If you mean... .
|
|
I'm looking to do a refresh on some UI code and thought I would take a look at ideas on one of the Web's premier resources: A List Apart . I found this article on creating a layout with a fixed header, a left panel and a main panel using fixed positions...
Started by Mark Brittingham on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
Try putting this:
<!--[if lt IE 7]> <style type="text/css"> #side { height:expression(document.body.clientHeight-120); } #main { height:expression(document.body.clientHeight-120); width:expression(document.body.clientWidth-260); } </style... .
|
Ask your Facebook Friends
|
I've convinced myself that they can't.
Take for example:
4 4 + 4 /
stack: 4 stack: 4 4 4 + 4 = 8 stack: 8 stack: 8 4 8 / 4 = 2 stack: 2
There are two ways that you could write the above expression with the same operators and operands such that the operands...
Started by kanske on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
2 4 + 7 8 + *
No matter how you reorder this, you'll end up with something that ... .
If you can't reorder the stack contents, then the expression (2+4)*(7+8) can't be rearranged .
It is enough to show one that can't in order to tell you the answer to this .
|
|
I need a help in making an algorithm for solving one problem: There is a row with numbers which appear different times in the row, and i need to find the number that appears the most and how many times it's in the row, ex:
1-1-5-1-3-7-2-1-8-9-1-2
That...
Started by ggg on
, 13 posts
by 13 people.
Answer Snippets (Read the full thread at stackoverflow):
You can't get it any faster....
You can sort the array, then look for the longest repeating sequence .
What you're looking for is called the mode.
You could keep hash table and store a count of every element in that structure, like this
h[1] = 5 h[5] = 1 .. .
|
|
I am using resize event, but when scroller appear - it change window size, but event is not called.
Started by dynback.com on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
Unfortunately, there is no event listener for scrollbar ....
You have to check if the content height is higher than the inner height of the browser .
You could keep tabs on the client width - it will reduce by about 20px when the scrollbar appears.
|
|
I have a table with a "Date" column. Each Date may appear multiple times. How do I select only the dates that appear < k number of times?
Started by Jake on
, 9 posts
by 9 people.
Answer Snippets (Read the full thread at stackoverflow):
It's very similar to this, but depending on your database his JOIN will probably run faster, assuming... .
SELECT * FROM [MyTable] WHERE [Date] IN ( SELECT [Date] FROM [MyTable] GROUP By [Date] HAVING COUNT(*) < @Max )
See @[SQLMenace] 's response also .
|
|
Modularity of basic programming first appeared with visual basic? True or False?
Started by PulledBull on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
In general, you can use any programming approach with any syntax, although some syntaxes... .
I've seen examples of clean, modular BASIC code that predate VB .
False, even GW Basic & Quick Basic which have appeared before visual basic have modularity.
|
|
What CSS should I use to make a cell's border appear even if the cell is empty?
IE 7 specifically.
Started by Allain Lalonde on
, 7 posts
by 7 people.
Answer Snippets (Read the full thread at stackoverflow):
Or do you require a pure css solution?
Apparently, IE8 shows the cells by default... .
If you can put a (non breaking space) to fill the void, that will usually work .
If I recall, the cell dosn't exist in some IE's unless it's filled with something.. .
|
|
I want to run a command as soon as a certain text appears in to a log file. How do I do it in bash?
Started by ketorin on
, 6 posts
by 6 people.
Answer Snippets (Read the full thread at stackoverflow):
This should work even without GNU grep:
tail -f -n 0 logfile.out | nawk '/pattern... .
Use command
tail -f file.log | grep --line-buffered "my pattern" | while read line do echo $line done
The --line-buffered is the key here, otherwise the read will fail .
|