I have created an up/down arrow segmented control button on the right side of the navigation bar in my detail view. How can I use these up/down arrows to change views?
I'm looking for a regex to search my python program to find all lines where foo, but not bar, is passed into a method as a keyword argument. I'm playing around with lookahead and lookbehind assertions, but not having much luck.
Any help?
Thanks
SUpoose i am in the middle of page length.
Is it possible to find , how much more distance in length or pixels from bottom.
Like when scroll bar hits the bottom then its 0 but if it 500px from the bottom then i need that 500px value.
Thanks
I need to build a custom designed bar chart that displays some simple data. Below are my requirements. Can anyone suggest the best web technology for my requirements.
high browser compatibility
ability to draw shapes
ability to fill shapes with gradients
ability to have onclick and onmouseover events for the different shapes (bars in the chart).
Thanks guys. I was thinking of using svg but looking for suggestions.
Should this bar on the HTML designer show the tag name? It sometimes does!
Here's an image of what I referring to.
I thought for sure it must be a bug but considering that I heard that MS was rewriting the editor (designer too?) I am starting to question whether I know how to use it!
Today I had something weird happen in my copy of Resharper 5. I have a class that looks like this:
public class Foo
{
public string Username { get; private set; }
public Foo (string userName) { Username = userName; }
public void Bar()
{
DoWork(Username);
}
public DoWork(string userName) { }
}
When I start to type DoWork(us I get the following from intellisense:
Notice that it's pulling up the constructor argument, and it ends with a colon: userName:
What's going on here?
I'd like to know how to use XMLHttpRequest to load the content of a remote URL and have the HTML of the accessed site stored in a JS variable.
Say, if I wanted to load and alert() the HTML of http://foo.com/bar.php, how would I do that?
hi,
how can I remove the space between my video and control bar... I tried to change margin and padding to all element without success. There is still a thin white space above the controls.
http://dl.dropbox.com/u/72686/hSliderMargin.png
thanks
I've seen a lot this kind of code recently :
if ($foo = $bar->getFoo())
{
baz($foo);
}
Is this considered good or bad practice ?
For example, Netbeans IDE give a notice if you use this kind of code :
Possible accidental assignment,
assignments in conditions should be
avoided
What do you think ?
what is the best way to make my php code working on one domain
and sure i will encode the whole code by ioncube
i want function like
function domain(){
}
if($this_domain <> domain()){
exit('no');
}
or
$allowed_hosts = array('foo.example.com', 'bar.example.com');
if (!isset($_SERVER['HTTP_HOST']) || !in_array($_SERVER['HTTP_HOST'], $allowed_hosts)) {
header($_SERVER['SERVER_PROTOCOL'].' 400 Bad Request');
exit;
}
now i want know the best way to do that
may be will user strpos
I have a list which contains a number of things:
lista = ['a', 'b', 'foo', 'c', 'd', 'e', 'bar']
I'd like to get the first item in the list that fulfils a predicate, say len(item) > 2. Is there a neater way to do it than itertools' dropwhile and next?
first = next(itertools.dropwhile(lambda x: len(x) <= 2, lista))
I did use [item for item in lista if len(item)>2][0] at first, but that requires python to generate the entire list first.
Hello All,
I know its possible to create a table that has an index on the side and a search bar at the top that a user can type in to find an item, but is it possible to say to the table if array isEqual to "item1" push view1? I would like to push a different view with each cell. Anyone have any advice?
I'd like to make a login bar for an application and I can't figure out how to organize a series of JLabels and JTextFields such that they are organized in a horizontal grid without these same components being resized to fit each cell. How can this be achieved?
Suppose I have:
class myclass:
def __init__(self):
self.foo = "bar"
where the value of foo needs to be available to users of myclass. Is it OK to just read the value of foo directly from an instance of myclass? Should I add a get_foo method to myclass or perhaps add a foo property? What's the best practice here?
I need to show a process of commiting my files to the svn. I use vs2008 C#.I take a progress bar, but when I am starting commiting, I don't know how to show my progress(also I want to look what file is uploading now in a label for example)
The Twitter app is a tab bar app on the iPhone. Nothing in any of the tabs will rotate, yet, when you click on a link from a tweet, the view controller that is pushed on top of it IS allowed to rotate. The only rotations I have ever doe is from tilting the device, landscape or portrait, but I don't understand how to use 2d transformations and animations to rotate views.
How do you rotate any view with that's a subclass of UIView?
My app got rejected by the apple because of the reason "iPhone Apps must also run on iPad without modification, at iPhone resolution, and at 2X iPhone 3GS resolution".Apple suggested that "to support the iPad 3GS 2X, and this issue is usually resolved through settings in "compatibility" mode. "no black bar's or borders"".So,my question is how to set and run the app in compatibility mode.Any one having this issue please help on this issue.I have no idea to go forward. Please any suggestions and help thanks in advance.
template <typename T>
struct Foo
{
void operator()(T& t) { t(); }
};
Is there any standart or boost functor with the similar implementation?
I need it to iterate over container of functors:
std::for_each(beginIter, endIter, Foo<Bar>());
Or maybe there are other way to do it?
I'm making a bookmarklet, but I've encountered some wierd behaviour in IE8. The code causing the problem is this:
var els = document.getElementById("my_id").getElementsByTagName("*");
for(var i in els)
{
alert(i+","+els[i])
}
The first thing that is alerted is "length, n". This isn't the case in chrome: just in IE8.
Interestingly, it seems to behave differently depending on whether the code goes in the console/address bar or the page itself.
Is this standard behaviour?
in my apps i am using a actionresult like as a
public actionresult index(param1)
{
return view();
}
are i can redirect from a other actionresult like a
public actionresult second()
{
return view("index"+current.tostring());
}
but when i rediect it is not worked but when i enter on browser address bar or resend request to him then he work fine. are any sollution for it.
hi
i am making an tabbar application in which i have 4 tabbars. tabbars are working perfectly, my problem is that the title is overlapping over other tab bar. Title are a bit long like Instructional Videos. how can i fix it.
Suppose I have a class
public class Foo
{
public Bar { get; set; }
}
Then I have another class
public class Gloop
{
public List<Foo> Foos { get; set; }
}
What's the easiest way to get a List of Foo.Bars?
I'm using C# 4.0 and can use Linq if that is the best choice.
My first thought was something like
I would like to display the contents of a DataTable, divided into several groups depending on the value of one of the columns. So, if I have a DataTable (from SQL query) with:
GroupID Name Description
1 foo bar
1 one two
2 some thing
I would like to place all records containing GroupID 1 in one div, all records with GroupID 2 in another div, and so on. How can I do this?
I'm writing in ASP.NET 4.0, with C# codebehind.