How do i set a tag for a button programmatically?
I later want to compare to tags for a conclusion
ive tried this
-(IBAction)buttonPressed:(id)sender{
NSLog(@"%d", [sender tag]);
}
but that just crashes the app.... :(
any other ideas?
Cheers Guys
Sam
I'd like to edit/set icq status with a c# app when a certain action occurs.
I know there's an API that seems much too oversized for that. Can someone suggest a better way e.g. manipulating a registry value or something?
How would you do this?
I have this link
@Ajax.ActionLink("create poll question", "CreatePoll", new { id = Model.DebateID }, new AjaxOptions
{
UpdateTargetId = "poll-entry-box",
InsertionMode = InsertionMode.Replace,
HttpMethod = "GET"
})
which is pointing at a action with the [Authorize] Attribute. The login works, but the returnURL is empty so it just redirects to the index page.
Is there some way to manually set the returnURL ?
NOTE
I am using the method described here http://haacked.com/archive/2011/10/04/prevent-forms-authentication-login-page-redirect-when-you-donrsquot-want.aspx because the login page was loading inside my partial.
I need to write a batch file to set the system environmental variables as shown below
WRD_WF_ROOT=e:\wrd_ntl_v23
WRD_Wld_ROOT=e:\wrd_ntl_v23
and I need to run the script for 250 users .
Programming challenge: Given a set of integers [1, 2, 3, 4, 5] I would like to generate all possible k-combinations in ascending size order in Java; e.g.
[1], [2], [3], [4], [5], [1, 2], [1, 3] ... [1, 2, 3, 4, 5]
It is fairly easy to produce a recursive solution that generates all combinations and then sort them afterwards but I imagine there's a more efficient way that removes the need for the additional sort.
I am trying to set my columns default date time to system datetime.
It shows me an error
Invalid default value for
'InsertionDate'
alter table `vts`.`tblpickpoint`
add column `InsertionDate`
datetime DEFAULT 'Now()' NULL after `PickPointLatLong`
I have two pages one.html and two.html
i am opening a new window using following code
//here popup is a global variable
popup=window.open('two.html','two');
for the first time a popup window open successfully and get the focus but
if i try to open it again without closing already opened popup then two.html is not getting focus for the second time.
note: i have set popup window's name as 'two'
hi
i have a set of point which define a route.
and i must draw their so vehicle moving arrow denoted.
this ponit may be form a curve...
i want to draw arrows on the reout to define witch arrow vehicle goes,
i have a mapviewr java applet and the last i must to do is this work, i want to define arrows on every 10 point on the rout
a thing like this
If I have 'export BLA="hey there"' in .profile in my home directory, how can I change this later in other directories just by cd into the other directory?
Also, is there a way to just set a new environment variable when I cd into a directory.
My first attempt was to just make another .bashrc file in the directory where I want the change but apparently that proved less than effective.
I'm on OS X btw.
Hi,
I am doing a system that require a login page. The problem is I dont know how to set the user level. For an example : if admin, can access all the page and if user can access only certain page. How to do that?
I would like to set the width and the height of the div element dynamically using jQuery.
I was trying to replace
<div id="mainTable" style="width:100px; height:200px;"></div>
with this:
$("#mainTable").css("width", "100");
$("#mainTable").css("height", "200");
but, it does not work for me.
Please help to understand why.
I have a Line Series Chart in Flex with values from 0 to 90. I would like to set the background of the chart in such a way that, 0 - 30 is in green, 31 - 60 is in red and 61 - 90 is in blue.
I am new to Flex. Can someone tell me how this can be done?
Now one Submit button is the default focused control. but I need to set the default focus to another imagebutton. Can only use $(document).ready(function(){ctrl.focus();} ? or has another property to fulfill it?
Hi,
I want to set the Masterpage property in Global.asax.
This is what I have done but I get a NullReferenceException on the first line.. Any ideas how to do this?
protected void Application_PreSendRequestContent(Object sender, EventArgs e)
{
System.Web.UI.Page page = System.Web.HttpContext.Current.Handler as System.Web.UI.Page;
if (Session["lang"] == "eng")
{
page.MasterPageFile = "SideMasterPageEng.master";
}
}
Have a question about Android "android.graphics.Path", I know how to create a Path from a set points as float[], but could not find anyway to get back the array from the Path object. Is it possible? Thanks in advance.
Hi,
I'm using Luntbuild with Subversion and would like to have our svn tagging environment specific (dev, testing, etc.) and I'm wondering if there's a way to use a variable in the VCS Adapters section.
I'm looking for something like this:
Directory for tags: tags/Builds/${env}/Service
Where ${env} is a variable I can set in the Luntbuild builders section or elsewhere. Does anyone know if what I'm wanting is possible?
Thanks.
A spawn off of an existing eclipse product is required for customization for a client. (hence parallel product development)
The intention was to use Eclipse Fragment, but "Fragments are additive, they cannot override content found in the host."
how can we maintain one set of codes in the svn, yet allow customization by overriding some classes?
the current solution is to have a global flag to indicated which product it is and "if" "else" littered everywhere in the codes ...
I have an option for a user to select his/her own theme while logged into the system and this theme is set in a MYSQL Database and called each time the user logs in, this is called by:
<?php $_SESSION['SESS_THEME_NAME']; ?>
Now, I had this working in a PHP file but I need it to work in Javascript instead unfortunately. And I need some help. I looked at the code using the developers tools on Google Chrome and looks like the above code is not resolving within the javascript file. Which makes sense because you can't access session variables within a javascript file (as I found by searching Google.)
The code is basically supposed to set the specific stylesheet based on the value extracted from the MYSQL database. So if the database says Default the script needs to tell the webpage to use the default.css file. And so on and so forth.
My attempt at writing this is as follows:
var themName="<?php $_SESSION['SESS_THEME_NAME']; ?>";
if (themeName == "Default")
{
document.write("<link re='stylesheet' type='text/css' href='css/mws-theme.css'>");
};
if (themeName == "Army")
{
document.write("<link rel='stylesheet' type='text/css' href='css/mws-theme-army.css'>");
};
if (themeName == "Rocky Mountains")
{
document.write("<link rel='stylesheet' type='text/css' href='css/mws-theme-rocky.css'>");
};
if (themeName == "Chinese Temple")
{
document.write("<link rel='stylesheet' type='text/css' href='css/mws-theme-chinese.css'>");
};
if (themeName == "Boutique")
{
document.write("<link rel='stylesheet' type='text/css' href='css/mws-theme-boutique.css'>");
};
if (themeName == "Toxic")
{
document.write("<link rel='stylesheet' type='text/css' href='css/mws-theme-toxic.css'>");
};
if (themeName == "Aquamarine")
{
document.write("<link rel='stylesheet' type='text/css' href='css/mws-theme-aquamarine.css'>");
};
Any help once so ever would be awesome and much much appreciated! I am reaching a deadline :/
I wrote an implementation of the Mandelbrot set in Java using a JComponent but I'm getting strange results when I render it. Besides that everything compiles right. I'm just not for sure what I'm doing wrong with it. Any code review also would be appreciated.
My source is posted on pastebin since it would take up too much room here:
JMandelbrot.java
Mandelbrat.java
I'm in a situation where I want to add the equivalent of the sql statement
SET QUERY_GOVERNOR_COST_LIMIT
to my query I created with linq to entities.
How would I go about that?
Hi,
Does anyone know how to set/change the android:layout_span="" of an EditText in Android at runtime.
I already have the EditText defined in my XML file.
<TableRow android:paddingTop="20dip" android:gravity="center_horizontal"> <EditText android:layout_width="150dip"
android:text="" android:layout_height="40dip"
android:id="@+id/p" android:layout_span="2"></EditText></TableRow>