Search Results

Search found 11674 results on 467 pages for 'adding'.

Page 11/467 | < Previous Page | 7 8 9 10 11 12 13 14 15 16 17 18  | Next Page >

  • Adding a UserControl within another UserControl in Sharepoint 2007

    - by DougJones
    I am using WSPBuilder to create and deploy my web part from a user control, as shown here. This works perfectly well, but I have added another user control to the project. I am adding it in page_init by going the Page.LoadControl("~/_controltemplates/MyControl.ascx"); route. It builds successfully, but after adding it to the page, I get The referenced file '/MyControl.ascx' is not allowed on this page. This control is in the ControlTemplates folder in the hive. In the web.config for this sharepoint 2007 site, all items within _controltemplates are listed as safe, as shown here <SafeControl Src="~/_controltemplates/*" IncludeSubFolders="True" Safe="True" AllowRemoteDesigner="True" /> How do I get the ascx file to be allowed on the page and get this webpart to display successfully?

    Read the article

  • Assigning a group while adding user in django-admin

    - by Lokharkey
    In my application, I have models that have the Users model as a Foreign key, eg: class Doctor(models.Model): username=models.ForeignKey(User, unique=True) ... In the admin site, when adding a new Doctor, I have the option of adding a new User next to the username field. This is exactly what I want, but in the dialog that opens, it asks for a username and password for the new user; I would also like to be able to assign a group to this new user. What would be the best way of doing this ? Thanks, lokharkey

    Read the article

  • Visual Studio 2010: adding a service reference to a 2008 generated wsdl

    - by Snake
    Doesn't produce a app.config . In my team there is a guy who has Visual Studio 2008, he created a webservice. Then there is me, adding this webservice to a console project. Adding the service reference goes without problems but no valid app.config is generated. It's just empty <configuration> </configuration> When I disable 'reuse types' in my service reference it works but then I get an ambiguous error. Is this a bug? I found http://stackoverflow.com/questions/2159107/visual-studio-does-not-generate-app-config-content-when-add-service-reference this one, but there is no solution there, so I thought I bump the problem up again. Thanks

    Read the article

  • Adding video and flash functionality to the Ajax Control Toolkit HTMLEditor

    - by Beerdude26
    Greetings, I'm looking for a way to extend the functionality of the HTMLEditor control that the Ajax Control Toolkit supplies for ASP.net. I would like to add video and flash functionality to the editor (buttons, allowed tags, etc). To my knowledge, this is rather easy: plop in an tag with the correct parameters and it just works; I have videos running in the preview window of the editor. Unfortunately, the tag is stripped away when saving the HTML-code and updating it in the database. Hence, I would like to ask if there is any way of adding this functionality apart from manually adding the changes in the source control repository of the Ajax Control Toolkit and recompiling it. If this is not possible, but can offer some help concerning the implementation of this in the source code, it would also be much appreciated. Thank you for your time :)

    Read the article

  • Adding UIViewController.view to another view causes orientation problems

    - by Bob Vork
    Short version: I'm alloc/init/retaining a new UIViewController in one UIViewControllers viewDidLoad method, adding the new View to self.view. This usually works, but it seems to mess up orientation change handling of my iPad app. Longer version: I'm building a fairly complex iPad application, involving a lot of views and viewcontrollers. After running into some difficulties adjusting to the device orientation, I made a simple XCode project to figure out what the problem is. Firstly, I have read the Apple Docs on this subject (a small document called "Why won't my UIViewController rotate with the device?"), and while I do believe it has something to do with one of the reasons listed there, I'm not really sure how to fix it. In my test project I have an appDelegate, a rootViewController, and a UISplitViewController with two custom viewControllers. I use a button on the rootViewController to switch to the splitViewController, and from there I can use a button to switch back to the rootViewController. So far everything is great, i.e. all views adjust to the device orientation. However, in the right viewController of the splitViewController, I use the viewDidLoad method to initialize some other viewControllers, and add their views to its own view: self.newViewController = [[UIViewController new] autorelease]; [newViewController.view setBackgroundColor:[UIColor yellowColor]]; [self.view addSubview:newViewController.view]; This is where things go wrong. Somehow, after adding this view, adjusting to device orientation is messy. On startup everything is fine, after I switch to the splitViewController everything is still fine, but as soon as I switch back to the rootViewController it's all over. I have tried (almost) everything regarding retaining and releasing the viewcontroller, but nothing seems to fix it. As you can see from the code above, I have declared the newViewController as a property, but the same happens if I don't. Shouldn't I be adding a ViewController's view to my own view at all? That would really mess up my project, as I have a lot of viewControllers doing all sorts of things. Any help on this would be greatly appreciated...

    Read the article

  • Blackberry Development, adding dynamic number of buttons and setting Fieldchangelistener() for them

    - by Nikesh Yadav
    Hi, I am adding dynamic number of buttons in a Blackberry application and trying to get different events on each button click. I am not able to apply the setchangelistener() for these array of buttons as once the loop finishes after adding all the buttons, the events gets generated only for the last indexed button. If I make us of getIndex(), it runs fine only if I am not adding any other fields on my screen, but if I add other fields along with these array of buttons, the getIndex() function count them in the indexing as well. Can anyone please help me out in setting FieldChangeListener to array of ButtonField? Here is a sample code of the way I am using the array of ButtonField. I the code I have added two test LabelField at the top of the screen, if I remove them the code will run fine and I will get different result for each button click, but if I keep them active, the indexing gets effected and the Button wont work. package buttonclickloop; import net.rim.device.api.ui.DrawStyle; import net.rim.device.api.ui.Field; import net.rim.device.api.ui.FieldChangeListener; import net.rim.device.api.ui.component.ButtonField; import net.rim.device.api.ui.component.LabelField; import net.rim.device.api.ui.container.HorizontalFieldManager; import net.rim.device.api.ui.container.MainScreen; public class ButtoncClickLoop extends MainScreen { int i = 0; private ButtonField[] btn = new ButtonField[50]; public ButtoncClickLoop() { // TODO Auto-generated constructor stub LabelField Field1 = new LabelField("Field1"); LabelField Field2 = new LabelField("Field2",DrawStyle.RIGHT | ButtonField.USE_ALL_WIDTH); HorizontalFieldManager FieldHmgr = new HorizontalFieldManager(); FieldHmgr.add(Field1); FieldHmgr.add(Field2); FieldHmgr.setMargin(0,0,10,5); add(FieldHmgr); while (i < 3){ FieldChangeListener listener = new FieldChangeListener() { public void fieldChanged(Field field, int context) { context = field.getIndex(); if (field == btn[context]){ add(new LabelField("Label" + context + "")); } } }; btn[i] = new ButtonField("Button" + i + ""); btn[i].setChangeListener(listener); add(btn[i]); i = i + 1; } } } Thanks, Nikesh

    Read the article

  • Adding a sortcomparefunction to Dynamic Data Grid in flex

    - by Tom
    Hi, I am trying to create a dynamic datagrid in Flex 3, I have a list of columns a list of objects which correspond to datapoints for those columns which I fetch from a url. While the grid works perfectly fine the problem is that sorting on the columns is done in lexical order. I am aware that this can be fixed by adding a sortcomparefunction to a column, which is not easy for this case. I have tried doing var dgc:DataGridColumn = new DataGridColumn(dtf); f1[dtf] = function(obj1:Object, obj2:Object):int { return Comparators.sortNumeric(obj1[dtf],obj2[dtf]); }; dgc.sortCompareFunction = f1[dtf];` But the problem is that the function object that I am creating here is being overwritten in every iteration (as I am adding columns) and eventually all the columns will have sorting done only on the last column added. Suggestions please.

    Read the article

  • Adding simple marker clusterer to google map

    - by take2
    Hi, I'm having problems with adding marker clusterer functionality to my map. What I want is to use custom icon for my markers and every marker has its own info window which I want to be able to edit. I did accomplish that, but now I have problems adding marker clusterer library functionality. I read something about adding markers to array, but I'm not sure what would it exactly mean. Besides, all of the examples with array I have found, don't have info windows and searching through the code I didn't find appropriate way to add them. Here is my code (mostly from Geocodezip.com): <script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script> <script type="text/javascript" src="http://google-maps-utility-library-v3.googlecode.com/svn/trunk/markerclusterer/src/markerclusterer.js"></script> <style type="text/css"> html, body { height: 100%; } </style> <script type="text/javascript"> //<![CDATA[ var map = null; function initialize() { var myOptions = { zoom: 8, center: new google.maps.LatLng(43.907787,-79.359741), mapTypeControl: true, mapTypeControlOptions: {style: google.maps.MapTypeControlStyle.DROPDOWN_MENU}, navigationControl: true, mapTypeId: google.maps.MapTypeId.ROADMAP } map = new google.maps.Map(document.getElementById("map_canvas"), myOptions); var mcOptions = {gridSize: 50, maxZoom: 15}; var mc = new MarkerClusterer(map, [], mcOptions); google.maps.event.addListener(map, 'click', function() { infowindow.close(); }); // Add markers to the map // Set up three markers with info windows var point = new google.maps.LatLng(43.65654,-79.90138); var marker1 = createMarker(point,'Abc'); var point = new google.maps.LatLng(43.91892,-78.89231); var marker2 = createMarker(point,'Abc'); var point = new google.maps.LatLng(43.82589,-79.10040); var marker3 = createMarker(point,'Abc'); var markerArray = new Array(marker1, marker2, marker3); mc.addMarkers(markerArray, true); } var infowindow = new google.maps.InfoWindow( { size: new google.maps.Size(150,50) }); function createMarker(latlng, html) { var image = '/321.png'; var contentString = html; var marker = new google.maps.Marker({ position: latlng, map: map, icon: image, zIndex: Math.round(latlng.lat()*-100000)<<5 }); google.maps.event.addListener(marker, 'click', function() { infowindow.setContent(contentString); infowindow.open(map,marker); }); } //]]> </script>

    Read the article

  • Adding AllowPartiallyTrustedCallersAttribute To Paypal ASP.NET SDK

    - by snwr
    Currently, I cannot use Paypal Pro on my host (GoDaddy) because it requires Full trust level. After digging in Google, it seems a workaround is possible by adding AllowPartiallyTrustedCallersAttribute to the Paypal assembly. I have seen code samples that use AllowPartiallyTrustedCallersAttribute in their AssemblyInfo.cs file, however, I've yet to run into a code example that also happens to be using PayPal. My question is where should the AllowPartiallyTrustedCallersAttribute be added in my project if my objective is to make the PayPal assembly work? I have tried adding it to my AssemblyInfo.cs for the project that contains the entire website, but I have not been successful. At this point, any insight or shot in the dark would be greatly appreciated. Even if someone could point me in the general direction of some documentation I would be grateful. AllowPartiallyTrustedCallersAttribute Reference: http://msdn.microsoft.com/en-us/library/system.security.allowpartiallytrustedcallersattribute.aspx

    Read the article

  • WebConfigurationManager error after adding siteMap

    - by aron
    Hello I'm getting this error: Compiler Error Message: CS0118: 'Configuration' is a 'namespace' but is used like a 'type' Configuration myWebConfig = WebConfigurationManager.OpenWebConfiguration("~/"); This code has been in place for 5+ months without this issues, only today after adding this sitemap code do I have this issue. <siteMap defaultProvider="ExtendedSiteMapProvider" enabled="true"> <providers> <clear/> <add name="ExtendedSiteMapProvider" type="Configuration.ExtendedSiteMapProvider" siteMapFile="Web.sitemap" securityTrimmingEnabled="true"/> </providers> </siteMap> I tried adding "System.Web." before the "Configuration ", but that did not work either: System.Web.Configuration myWebConfig = WebConfigurationManager.OpenWebConfiguration("~/"); Error 1 'System.Web.Configuration' is a 'namespace' but is used like a 'type'

    Read the article

  • Adding two Set[Any]

    - by Alex Boisvert
    Adding two Set[Int] works: Welcome to Scala version 2.8.1.final (Java HotSpot(TM) Server VM, Java 1.6.0_23). Type in expressions to have them evaluated. Type :help for more information. scala> Set(1,2,3) ++ Set(4,5,6) res0: scala.collection.immutable.Set[Int] = Set(4, 5, 6, 1, 2, 3) But adding two Set[Any] doesn't: scala> Set[Any](1,2,3) ++ Set[Any](4,5,6) <console>:6: error: ambiguous reference to overloaded definition, both method ++ in trait Addable of type (xs: scala.collection.TraversableOnce[Any])scala.collection.immutable.Set[Any] and method ++ in trait TraversableLike of type [B >: Any,That](that: scala.collection.TraversableOnce[B])(implicit bf: scala.collection.generic.CanBuildFrom[scala.collection.immutable.Set[Any],B,That])That match argument types (scala.collection.immutable.Set[Any]) Set[Any](1,2,3) ++ Set[Any](4,5,6) ^ Any suggestion to work around this error?

    Read the article

  • Adding an equation or formula to a figure caption in LaTeX

    - by gotgenes
    I have a figure in LaTeX with a caption to which I need to add a formula (equation* or displaymath environments). For example: \documentclass[12pt]{article} \begin{document} \begin{figure}[tbph] \begin{center} %... \end{center} \caption{As you can see \begin{displaymath}4 \ne 5\end{displaymath} } \label{fig:somefig} \end{figure} \end{document} This makes pdflatex angry, though it will produce a PDF. ! Argument of \@caption has an extra }. <inserted text> \par l.9 } What's the right way to go about adding an equation to a figure caption? NOTE: Please do not suggest simply using the $ ... $ math environment; the equation shown is a toy example; my real equation is much more intricate. See also: Adding a caption to an equation in LaTeX (the reverse of this question)

    Read the article

  • Addslashes, mysql_real_escape always adding two slashes?

    - by Zach
    I'm having an issue with inserting JSON into a database, my intention is to take the variables, json_encode them, remove slashes (from magic_quotes), and then addslashes back in to escape the quotes in {"key":"value"} Unfortunately, strip_slashes on the encoded string isn't doing anything, and outputs this {"content":"<p>This string has it\'s downsides</p>","date":1271352514} I have then tried addslashes, and mysql_real_escape_string, both output "{\\"content\\":\\"<p>This string has it\\\'s downsides</p>\\",\\"date\\":1271352514}" I can't work out why it's adding in two slashes? And I'm tearing my hair out over this, everytime I try to stripslashes it leaves one in, and adding slashes adds two. Any help would be hugely appreciated!

    Read the article

  • interactive (adding listeners to) DAE model in flex + papervision

    - by G. Matthieu
    I have a DAE model that is parsed into several parts. I am able to deal with them separately, such as changing their material or colour but I am having problems adding click or hover listeners over the children. For example, lets say I have a model of a kitty where each facial feature is a child. I want to be able to hover or click the features and have a window pop up explaining the feature. I've tried parsing the model and adding listeners but it doesn't seem to work. Thanks in advance! L

    Read the article

  • NullPointerException when adding to BigDecimal

    - by Dan
    String[] toppings = new String[10]; BigDecimal toppingsPrice = null; toppings[0] = req.getParameter("extraCheese"); toppings[1] = req.getParameter("moreTomatoes"); toppings[2] = req.getParameter("extraOnions"); // ... for(int i = 0; i < toppings.length; i++) { if(toppings[i] != null) { toppingsPrice.add(new BigDecimal("0.99")); // <-- NPE is caused here. toppingsPrice = toppingsPrice.setScale(2, BigDecimal.ROUND_HALF_EVEN); } } I am getting a NullPointerException in the above code when adding 0.99 to toppingsPrice. I am working with money values, so I have used BigDecimal. Is there something wrong with how I am adding the 0.99c price?

    Read the article

  • Adding new "columns" to csv data file in Tcl

    - by George
    Hi All, I am dealing with a "large" measurement data, approximately 30K key-value pairs. The measurements have number of iterations. After each iteration a datafile (non-csv) with 30K kay-value pairs is created. I want to somehow creata a csv file of form: Key1,value of iteration1,value of iteration2,... Key2,value of iteration1,value of iteration2,... Key2,value of iteration1,value of iteration2,... ... Now, I was wondering about efficient way of adding each iteration mesurement data as a columns to csv file in Tcl. So, far it seems that in either case I will need to load whole csv file into some variable(array/list) and work on each element by adding new measurement data. This seems somewhat inefficient. Is there another way, perhaps?

    Read the article

  • Adding images to the html with javascript

    - by Anonymous
    I've tried some HTML DOM code from several sites, but it isn't working. It isn't adding anything. Does anyone have a working example on this? this.img = document.createElement("img"); this.img.src = "img/eqp/"+this.apparel+"/"+this.facing+"_idle.png"; src = getElementById("gamediv"); src.appendChild(this.img) But it isn't adding anything to the div. (gamediv) I've tried document.body as well, with no result. Thanks in advance.

    Read the article

< Previous Page | 7 8 9 10 11 12 13 14 15 16 17 18  | Next Page >