I am looking to create a Custom UIButton (not subclass) progrmatically, I would like it to have a background image that will stretch as the UIButton's width increases. How would I do this?
What would be the mechanism to deploy rar artifacts if they are not present in the repository. (e.g. I would like to deploy jackrabbit to my j2ee application, but it is not available as part of the maven repositories. Should I have to store the binary locally in SVN and use the antrun plugin to copy it?
Hi everyone,
I know on how to display a list by using loop.
For example,
choice(a):-write('This is the top 15 countries list:'),nl,
loop(X).
loop(X):-country(X),write(X),nl,fail.
Unfortunately,I don't know on how to display list by using list.anyone can guide me?
This belongs on Meta but I can't ask it there since, well, I can't log in :-)
I'm unable to log into my account using my OpenID, josh.gitlin.name on either StackOverflow or Meta. The error message I receive after entering my OpenID on the login page and pressing "Login" is:
Unable to log in with your OpenID
provider:
Error occurred…
When ever I run make I get this 'uninitialized constant RDoc::RDoc' error
rake -T
(in Main)
rake aborted!
uninitialized constant RDoc::RDoc
C:/Ruby186/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2383:in `raw_load_rakefile'
(See full trace by running task with --trace)
--edit
Running --trace it seems…
Okay, I have decided the only way I can do what I want to do with WiX (thanks to an old installer I didn't write that I now have to upgrade) is with some CUSTOM ACTIONS.
Basically, I need to back up a file before the RemoveExistingProducts and restore that file again after RemoveExistingProducts. I think this is what's called a "type 2…
The following snippet generates create / drop sql for a particular database, whenever there is a modification to JPA entity classes.
How do I perform something equivalent of a 'for' operation where-in the following code can be used to generate sql for all supported databases (e.g. H2, MySQL, Postgres)
Currently I have to modify…
Sometimes in case of a bug in our code, we usually ask the end user to provide the browser configuration and OS configuration to isolate the issue. How can we get this information in case of a problem while the end users are accessing a web application.
Back in 2000, I got a bunch of programming certifications from Brainbench. However, they didn't seem to be doing me any good, and they needed to be renewed every year, so I let them lapse. Recently I've been hearing more about Brainbench, and I've been wondering - do these certifications impress potential employers at all, in…
I am trying to make an if statement which will check whether the users touch is within a UIButton's bounds. I thought this would be an easy affair as UIButton is a subclass of UIView, however my code doesn't seem to work.
This is the code I have been using.
- (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event {
…
I would like to show a different status message, when a suspended user tries to login. If the user is active we return true from the authenticate method, if not we add a custom StatusMessage message mentioning that the "User X has been suspended". The underlying Identity authentication also fails and adds a StatusMessage. I…
I need to change the folder that "relative include paths" are based on.
I might currently be "in" this folder:
C:\ABC\XYZ\123\ZZZ
And in this case, the path "../../Source/SomeCode.php" would actually be in this folder:
C:\ABC\XYZ\Source
And realpath('.') would = 'C:\ABC\XYZ\123\ZZZ';
If however, realpath('.') were…
I've posted this in the CodeIgniter forum and exhausted the forum search engine as well, so apologies if cross-posting is frowned upon.
Essentially, I've got a single input, set up as <input type="text" name="goal">. At a user's request, they may add another goal, which throws a duplicate to the DOM. What I…
Hi Guys;
I am writting an application that autogenerated the data input UI from a java bean.
Now i have a bean that has other beans as a property. eg User has property username, and usertype of type UserType;
Whats the best strategy in java. Do i loop through the fields in an if else loop?
eg. get field list
…
At the root of my d: drive, TortoiseSVN is showing the question mark decorators on all the folders. The d: drive is not a SVN working copy. How do I remove the decorators?
Crux of my problem:
I've got an XML file that returns 20 results. Within these results are all the elements I need to get. Now, I need to return them in a random order, and be able to specifically work with item 1, items 2-5, and items 6-17.
Idea 1: Use this script to convert the object to an array, which I can…
The following C++ program compiles and runs as expected:
#include <stdio.h>
int main(int argc, char* argv[])
{
int* test = new int[10];
for (int i = 0; i < 10; i++)
test[i] = i * 10;
printf("%d \n", test[5]); // 50
printf("%d \n", 5[test]); // 50
return getchar();
}
…
I run a large bulletin board and I get spammers every now and again. My moderation team does a good job filtering them out but every time I IP ban them they seem to come back (I'm pretty sure it's the same person on some occasions, as the post patterns are exactly the same as are the usernames) but I'm afraid to…
How can I validate the cells in a DataGridColumn individually? The validation is configured per-row. For example
FIELD VALUE TYPE
age 13 Integer
height 13x3 Integer
registered true Boolean
temperature 98.G6 Float
In this case, of…
Hi this is fairly simple
I want to know how to use nl2br(); in php, but limit the amount of <br/>'s that are allowed at one time.
//For Example: A user enters
hi
Im a jerk and made 16 more lines. or I could make as many as i want
Is there anyway to have php limit the <br/>'s…
Is there a way to cast dynamically in Actionscript? What I want to accomplish is illustrated by the following code:
var Val:*;
var S:String=SomeTextEdit.text;
switch (DesiredTypeTextEdit.text) {
case 'int':Val=int(S);break;
case 'uint':Val=uint(S);break;
…
Environment: Seam, Richfaces
The following code snippet causes the method getUsers to be called multiple times, how do I avoid this in my application so that it gets called only once.
<c:forEach items="#{userHome.getUsers()}" var="_user">
</c:forEach>
I'm dealing with a Postgres table (called "lives") that contains records with columns for time_stamp, usr_id, transaction_id, and lives_remaining. I need a query that will give me the most recent lives_remaining total for each usr_id
There are multiple users (distinct usr_id's)
time_stamp is not a unique…
Using "introspection" In Flex I can say:
var classInfo:XML=describeType(SomeObject);
Which will list for me the Accessors, Methods And Variables.
(http://livedocs.adobe.com/flex/3/html/help.html?content=usingas_8.html)
But what is the equivalent to programmatically inspect all of an object's possible…
I come from a web development background. I'm good at XHTML, CSS, JavaScript, PHP and MySQL, because I use all of those technologies at my day job.
Recently I've been tinkering with Obj-C in Xcode in the evenings and on weekends. I've written code for both the iPhone and Mac OS X, but I can't wrap my head…