Search Results

Search found 1056 results on 43 pages for 'f spot'.

Page 3/43 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Auto-Attach EBS-volume to a New Spot Instance?

    - by Jeff
    I am experimenting with EC2 spot instances, and am needing some data to be retained between terminations. Now as I understand it, when the current price goes above my max. bid, it will be automatically terminated. I assume any init scripts I have will be run on shutdown so I can push data off to the EBS before unmounting. My question is, how can I automatically mount the same EBS volume on the new spot instance once the price goes down, since it won't have any of my init scripts that I would've loaded onto the root volume the first time? Do I have to create a custom AMI, or is there some other way to achieve this?

    Read the article

  • How to Program AWS Spot Instances to Strategically Bid So the Auction is Never Lost Until a Competitor Beats the Maximum I'm Willing to Pay?

    - by Taal
    I believe I'm in the right section of stack exchange to ask this. If not, let me know. I only use Amazon Web Services for temporary type hosting services, so the spot instances are quite valuable to me. I would also just make an instance and start and stop it - but - that doesn't necessarily fit my bootstrapped budget sadly. Anyways, it really kills me when someone outbids me on a spot instance I have (I tend to go for the larger ones which there are fewer of available) and I get randomly kicked off. I know or at least I believe there is a way to program in something somehow to dynamically change your bidding price to beat a potential competitor's if their's is higher than yours. Now, I previously believed Amazon would just charge me for the highest price right above the next lowest competitor automatically (eliminating the need for this) - so if I bid too high, then I only pay what I would of needed to in order to win and keep the auction. Essentially, I thought my bid price was my max bid price. Apparently, according to my bills and several experiments I've done - this is not the case. They charge me for whatever I bid even when I know there is no one else around to counter bid me. I needed to clarify that, but let me get back to the main point: Let's say I'm bidding $0.50, competitor comes in and bids 0.55 cents. I get kicked off. I want to have it to where I'd set a maximum I'm willing to pay (let's say $1.00 here), and then when competitor comes in and tries to bid $.55, my bid is dynamically adjusted to beat his at $0.56 up until he breaks my $1.00 threshold. I've been reading the guides and although they are more or less straightforward, I feel like they leave a few holes in them that end up confusing me. Like, for instance, where do I input said command or when do I do it? Maybe I'm just tech illiterate and need help deciphering these guides. A good start for someone willing to answer/help me decipher this problem would be here: http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/spot-as-update-bid.html

    Read the article

  • Why do AWS spot-instance prices spike above the "on demand" pricing?

    - by Laykes
    Amazon Pricing on Spot Instance Inconsistencies This is something which will be best explained through screenshots of a historical chart of instance pricings. If you look at a lot of the instance prices for spot instances, you will notice regular patterns of spikes. See here: As you can see, the price for this compute medium instance, regularly spikes above the on demand price. A c1.medium instance (on demand), would only cost $0.186 per hour. But for a period of a few weeks, in zone B, the price would regularly spike to $1.20. This is some 6 times the actual on demand price. It's also not isolated. If you look at zone-b again for small instances, there is a similar, spike frequently. Which goes 4x the on demand pricing. Does anyone know why this happens? Here are a few suggestions Someone entered $1.2 instead of $0.12 (I would discount this since it happened 20 times over the space of 3 weeks). Amazon regularly artifically inflate their prices by bidding on their own instances to get the most bang for their buck. (I would discount this since it would be ridiculous and bad business) Some company launched 1000 servers at once, and wants to make sure that they all launch. (I would discount this since they would presumably launch them at a price which would be below the minimum on demand price. Why would you pay above on demand for a single server?). It's a bug in their reporting?

    Read the article

  • Where is a good spot to start when writing a LWJGL game engine?

    - by Alcionic
    I'm starting work on a huge game and somewhere along my train of thought I decided it would be a good idea to write my own engine for the game. I was originally going to use JMonkeyEngine but there were some things about it that just didn't work well with me. I wanted full control over every aspect of the entire process. Where would a good place to start be when writing your own engine? I have no experience with LWJGL but I learn quick. Either advice or some place where there is good advice would be nice. Thanks!

    Read the article

  • How Does Windows Confirm Wi-Fi Access and Whether Hot Spot Authentication Is Necessary?

    - by Jason Fitzpatrick
    Windows is quite adept at telling you if you have a properly functioning Internet connection, but how exactly does it do so? Digging into how Windows handles the problem offers insight into Windows connectivity messages. Today’s Question & Answer session comes to us courtesy of SuperUser—a subdivision of Stack Exchange, a community-drive grouping of Q&A web sites. How to Fix a Stuck Pixel on an LCD Monitor How to Factory Reset Your Android Phone or Tablet When It Won’t Boot Our Geek Trivia App for Windows 8 is Now Available Everywhere

    Read the article

  • Are there localization tools which spot content strings in xaml/wpf?

    - by Noel Kennedy
    When globalizing a wpf application with static resx classes, it's very easy to miss the odd label or button that has its Content property set to a hard coded string in a particular language, ie English. These should of course be moved off to a {x:Static ...} so they can be localised for each culture. Are there any tools which can spot this and warn you? Built in to VS would be ideal, but I'm thinking that 'style cop' type build tools would do the job as well.

    Read the article

  • Making only part of an image a hot spot link.

    - by Rkstarcass
    I have a large image and only want a rectangle portion of it to be a hot spot link that goes "Home". Here is my code that is not working. Any help on what I am missing or have done wrong? Thanks! <div id="defaultPic" runat="server"> <img src="Images/boardwise-home.jpg" alt="Boardwise Home" usemap="#map" /> <map name="map" id="boardwise-home"> <area shape="rect" coords="32,23,32,105,275,105,275,23" href="~/default.aspx" title="Boardwise Home" alt="Home" /> </map>

    Read the article

  • Does OneNote have palm rejection or a hand rest spot?

    - by Richard DesLonde
    I just bought an Acer Iconia W500. I really wanted to use it for taking notes and having all the amenities of a full blown computer without the size. Using OneNote to take notes, I notice I can't rest my hand on the screen. I have read some about this and it seems the very best solution is to get a tablet with active digitizer technology, but there aren't too many with this and it is expensive. So barring that, is there any way I can rest my hand on the tablet screen while taking notes in OneNote? Or am I relegated to hovering my hand over the screen while I write notes? Does OneNote have a palm rest area or some sort of palm rejection?

    Read the article

  • What type of webapp is the sweet spot for Scala's Lift framework?

    - by ajay
    What kind of applications are the sweet spot for Scala's lift web framework. My requirements: Ease of development and maintainability Ready for production purposes. i.e. good active online community, regular patches and updates for security and performance fixes etc. Framework should survive a few years. I don't want to write a app in a framework for which no updates/patches are available after 1 year. Has good UI templating engines Interoperation with Java (Scala satisfies this arleady. Just mentioning here for completeness sake) Good component oriented development. Time required to develop should be proportion to the complexity of web application. Should not be totally configuration based. I hate it when code gets automatically generated for me and does all sorts of magic under the hood. That is a debugging nightmare. Amount of Lift knowledge required to develop a webapp should be proportional to the complexity of the web application. i.e I should't have to spend 10+ hours learning Lift just to develop a simple TODO application. (I have knowledge of Databases, Scala) Does Lift satisfy these requirements?

    Read the article

  • Web UI element to represent two different micro-views of data in the same spot?

    - by Chris McCall
    I've been tasked with laying out a portion of a screen for a customer care (call center) app that serves as sort of a header/summary block at the top of the screen. Here's what it looks like: The important part is in the red box. That little tooltip is the biz's vision for how to represent both the numeric SiteId and the textual Site Name all in the same piece of screen real estate. I asked, and the business thinks the Name is more important than the ID, but lists the Id by default, because the Name can't be truncated in the display, and there's only so much horizontal room to put the data. So they go with the Id, because it's fewer characters, and then they have the user mouse-over the Id to display the name (presumably because the tooltip can be of unlimited width and since it's floating over the rest of the screen, the full name will always be displayed. So, here's my question: Is there some better UI metaphor that I don't know about that could get this job done, while meeting the following constraints?: Does not require the mouse (uses a keyboard shortcut to do the "reveal") Allows the user to copy and paste the name Will not truncate the name Provides for the display of both the ID and name in the same spot Works with IE7

    Read the article

  • Assigning a value to a variable gets stored in the wrong spot?

    - by scribbloid
    Hello, I'm relatively new to C, and this is baffling me right now. It's part of a much larger program, but I've written this little program to depict the problem I'm having. #include <stdio.h> int main() { signed int tcodes[3][1]; tcodes[0][0] = 0; tcodes[0][1] = 1000; tcodes[1][0] = 1000; tcodes[1][1] = 0; tcodes[2][0] = 0; tcodes[2][1] = 1000; tcodes[3][0] = 1000; tcodes[3][1] = 0; int x, y, c; for(c = 0; c <= 3; c++) { printf("%d %d %d\r\n", c, tcodes[c][0], tcodes[c][1]); x = 20; y = 30; } } I'd expect this program to output: 0 0 1000 1 1000 0 2 0 1000 3 1000 0 But instead, I get: 0 0 1000 1 1000 0 2 0 20 3 20 30 It does this for any number assigned to x and y. For some reason x and y are overriding parts of the array in memory. Can someone explain what's going on? Thanks!

    Read the article

  • Assigning valid moves on board game

    - by Kunal4536
    I am making a board game in unity 4.3 2d similar to checkers. I have added an empty object to all the points where player can move and added a box collider to each empty object.I attached a click to move script to each player token. Now I want to assign valid moves. e.g. as shown in picture... Players can only move on vertex of each square.Player can only move to adjacent vertex.Thus it can only move from red spot to yellow and cannot move to blue spot.There is another condition which is : if there is the token of another player at the yellow spot then the player cannot move to that spot. Instead it will have to go from red to green spot. How can I find the valid moves of the player by scripting. I have another problem with click to move. When I click all the objects move to that position.But I only want to move a single token. So what can i add to script to select a specific object and then click to move the specific object.Here is my script for click to move. var obj:Transform; private var hitPoint : Vector3; private var move: boolean = false; private var startTime:float; var speed = 1; function Update () { if(Input.GetKeyDown(KeyCode.Mouse0)) { var hit : RaycastHit; // no point storing this really var ray = Camera.main.ScreenPointToRay (Input.mousePosition); if (Physics.Raycast (ray, hit, 10000)) { hitPoint = hit.point; move = true; startTime = Time.time; } } if(move) { obj.position = Vector3.Lerp(obj.position, hitPoint, Time.deltaTime * speed); if(obj.position == hitPoint) { move = false; } } }`

    Read the article

  • How to run sunspots?

    - by user111317
    I am trying to use SUN Spots with Ubuntu, but for some reason the SUN Spot Manager app is not seeing connected spot on USB port. Possibility that cdc_acm driver is not installed has been mentioned elsewhere, but I am complete beginner when it comes to Ubuntu, so I don't know where to find it or how to install it. Any input on this matter would be more than welcome. Addition: ls /dev/tty* returned the list that contains /dev/ttyACM0, but SUN spot is still not recognizing it.

    Read the article

  • different for lusses java

    - by Ayrton
    Hi I'm having some difficulties with the following problem: I'm making a little game where you're at a specific spot and each spot has each some possible directions. The available directions are N(ord),E(ast),S,W . I use the function getPosDirections to get the possible directions of that spot. The function returns the directions into an ArrayList e.g. for spot J3: [E,W] Now the game goes like this: 2 dices will be rolled so you get a number between 2 and 12, this number represents the number of steps you can make. What I want is an ArrayList of all the possible routes e.g.: I throw 3 and I'm currently at spot J3: [[E,N,E],[E,N,S],[E,S,E],[E,S,S],[W,N,E],[W,N,S],[W,S,E],[W,S,S]] How would obtain the last mentioned Array(list) Thanks in advance

    Read the article

  • different for loops java

    - by Ayrton
    I'm having some difficulties with the following problem: I'm making a little game where you're at a specific spot and each spot has each some possible directions. The available directions are N(ord),E(ast),S,W . I use the function getPosDirections to get the possible directions of that spot. The function returns the directions into an ArrayList<String> e.g. for spot J3: [E,W] Now the game goes like this: 2 dice will be rolled so you get a number between 2 and 12, this number represents the number of steps you can make. What I want is an ArrayList of all the possible routes e.g.: I throw 3 and I'm currently at spot J3: [[E,N,E],[E,N,S],[E,S,E],[E,S,S],[W,N,E],[W,N,S],[W,S,E],[W,S,S]] How would obtain the last mentioned Array(list)?

    Read the article

  • Revisiting ANTS Performance Profiler 7.4

    - by James Michael Hare
    Last year, I did a small review on the ANTS Performance Profiler 6.3, now that it’s a year later and a major version number higher, I thought I’d revisit the review and revise my last post. This post will take the same examples as the original post and update them to show what’s new in version 7.4 of the profiler. Background A performance profiler’s main job is to keep track of how much time is typically spent in each unit of code. This helps when we have a program that is not running at the performance we expect, and we want to know where the program is experiencing issues. There are many profilers out there of varying capabilities. Red Gate’s typically seem to be the very easy to “jump in” and get started with very little training required. So let’s dig into the Performance Profiler. I’ve constructed a very crude program with some obvious inefficiencies. It’s a simple program that generates random order numbers (or really could be any unique identifier), adds it to a list, sorts the list, then finds the max and min number in the list. Ignore the fact it’s very contrived and obviously inefficient, we just want to use it as an example to show off the tool: 1: // our test program 2: public static class Program 3: { 4: // the number of iterations to perform 5: private static int _iterations = 1000000; 6: 7: // The main method that controls it all 8: public static void Main() 9: { 10: var list = new List<string>(); 11: 12: for (int i = 0; i < _iterations; i++) 13: { 14: var x = GetNextId(); 15: 16: AddToList(list, x); 17: 18: var highLow = GetHighLow(list); 19: 20: if ((i % 1000) == 0) 21: { 22: Console.WriteLine("{0} - High: {1}, Low: {2}", i, highLow.Item1, highLow.Item2); 23: Console.Out.Flush(); 24: } 25: } 26: } 27: 28: // gets the next order id to process (random for us) 29: public static string GetNextId() 30: { 31: var random = new Random(); 32: var num = random.Next(1000000, 9999999); 33: return num.ToString(); 34: } 35: 36: // add it to our list - very inefficiently! 37: public static void AddToList(List<string> list, string item) 38: { 39: list.Add(item); 40: list.Sort(); 41: } 42: 43: // get high and low of order id range - very inefficiently! 44: public static Tuple<int,int> GetHighLow(List<string> list) 45: { 46: return Tuple.Create(list.Max(s => Convert.ToInt32(s)), list.Min(s => Convert.ToInt32(s))); 47: } 48: } So let’s run it through the profiler and see what happens! Visual Studio Integration First, let’s look at how the ANTS profilers integrate with Visual Studio’s menu system. Once you install the ANTS profilers, you will get an ANTS menu item with several options: Notice that you can either Profile Performance or Launch ANTS Performance Profiler. These sound similar but achieve two slightly different actions: Profile Performance: this immediately launches the profiler with all defaults selected to profile the active project in Visual Studio. Launch ANTS Performance Profiler: this launches the profiler much the same way as starting it from the Start Menu. The profiler will pre-populate the application and path information, but allow you to change the settings before beginning the profile run. So really, the main difference is that Profile Performance immediately begins profiling with the default selections, where Launch ANTS Performance Profiler allows you to change the defaults and attach to an already-running application. Let’s Fire it Up! So when you fire up ANTS either via Start Menu or Launch ANTS Performance Profiler menu in Visual Studio, you are presented with a very simple dialog to get you started: Notice you can choose from many different options for application type. You can profile executables, services, web applications, or just attach to a running process. In fact, in version 7.4 we see two new options added: ASP.NET Web Application (IIS Express) SharePoint web application (IIS) So this gives us an additional way to profile ASP.NET applications and the ability to profile SharePoint applications as well. You can also choose your level of detail in the Profiling Mode drop down. If you choose Line-Level and method-level timings detail, you will get a lot more detail on the method durations, but this will also slow down profiling somewhat. If you really need the profiler to be as unintrusive as possible, you can change it to Sample method-level timings. This is performing very light profiling, where basically the profiler collects timings of a method by examining the call-stack at given intervals. Which method you choose depends a lot on how much detail you need to find the issue and how sensitive your program issues are to timing. So for our example, let’s just go with the line and method timing detail. So, we check that all the options are correct (if you launch from VS2010, the executable and path are filled in already), and fire it up by clicking the [Start Profiling] button. Profiling the Application Once you start profiling the application, you will see a real-time graph of CPU usage that will indicate how much your application is using the CPU(s) on your system. During this time, you can select segments of the graph and bookmark them, giving them mnemonic names. This can be useful if you want to compare performance in one part of the run to another part of the run. Notice that once you select a block, it will give you the call tree breakdown for that selection only, and the relative performance of those calls. Once you feel you have collected enough information, you can click [Stop Profiling] to stop the application run and information collection and begin a more thorough analysis. Analyzing Method Timings So now that we’ve halted the run, we can look around the GUI and see what we can see. By default, the times are shown in terms of percentage of time of the total run of the application, though you can change it in the View menu item to milliseconds, ticks, or seconds as well. This won’t affect the percentages of methods, it only affects what units the times are shown. Notice also that the major hotspot seems to be in a method without source, ANTS Profiler will filter these out by default, but you can right-click on the line and remove the filter to see more detail. This proves especially handy when a bottleneck is due to a method in the BCL. So now that we’ve removed the filter, we see a bit more detail: In addition, ANTS Performance Profiler gives you the ability to decompile the methods without source so that you can dive even deeper, though typically this isn’t necessary for our purposes. When looking at timings, there are generally two types of timings for each method call: Time: This is the time spent ONLY in this method, not including calls this method makes to other methods. Time With Children: This is the total of time spent in both this method AND including calls this method makes to other methods. In other words, the Time tells you how much work is being done exclusively in this method, and the Time With Children tells you how much work is being done inclusively in this method and everything it calls. You can also choose to display the methods in a tree or in a grid. The tree view is the default and it shows the method calls arranged in terms of the tree representing all method calls and the parent method that called them, etc. This is useful for when you find a hot-spot method, you can see who is calling it to determine if the problem is the method itself, or if it is being called too many times. The grid method represents each method only once with its totals and is useful for quickly seeing what method is the trouble spot. In addition, you can choose to display Methods with source which are generally the methods you wrote (as opposed to native or BCL code), or Any Method which shows not only your methods, but also native calls, JIT overhead, synchronization waits, etc. So these are just two ways of viewing the same data, and you’re free to choose the organization that best suits what information you are after. Analyzing Method Source If we look at the timings above, we see that our AddToList() method (and in particular, it’s call to the List<T>.Sort() method in the BCL) is the hot-spot in this analysis. If ANTS sees a method that is consuming the most time, it will flag it as a hot-spot to help call out potential areas of concern. This doesn’t mean the other statistics aren’t meaningful, but that the hot-spot is most likely going to be your biggest bang-for-the-buck to concentrate on. So let’s select the AddToList() method, and see what it shows in the source window below: Notice the source breakout in the bottom pane when you select a method (from either tree or grid view). This shows you the timings in this method per line of code. This gives you a major indicator of where the trouble-spot in this method is. So in this case, we see that performing a Sort() on the List<T> after every Add() is killing our performance! Of course, this was a very contrived, duh moment, but you’d be surprised how many performance issues become duh moments. Note that this one line is taking up 86% of the execution time of this application! If we eliminate this bottleneck, we should see drastic improvement in the performance. So to fix this, if we still wanted to maintain the List<T> we’d have many options, including: delay Sort() until after all Add() methods, using a SortedSet, SortedList, or SortedDictionary depending on which is most appropriate, or forgoing the sorting all together and using a Dictionary. Rinse, Repeat! So let’s just change all instances of List<string> to SortedSet<string> and run this again through the profiler: Now we see the AddToList() method is no longer our hot-spot, but now the Max() and Min() calls are! This is good because we’ve eliminated one hot-spot and now we can try to correct this one as well. As before, we can then optimize this part of the code (possibly by taking advantage of the fact the list is now sorted and returning the first and last elements). We can then rinse and repeat this process until we have eliminated as many bottlenecks as possible. Calls by Web Request Another feature that was added recently is the ability to view .NET methods grouped by the HTTP requests that caused them to run. This can be helpful in determining which pages, web services, etc. are causing hot spots in your web applications. Summary If you like the other ANTS tools, you’ll like the ANTS Performance Profiler as well. It is extremely easy to use with very little product knowledge required to get up and running. There are profilers built into the higher product lines of Visual Studio, of course, which are also powerful and easy to use. But for quickly jumping in and finding hot spots rapidly, Red Gate’s Performance Profiler 7.4 is an excellent choice. Technorati Tags: Influencers,ANTS,Performance Profiler,Profiler

    Read the article

  • Need Help With Finding SEO Company/Individual

    - by three3
    Hi everyone, I am fairly new to SEO and I have done all of the tactics and operations that I know to do to help my site rank to the number 1 spot on Google. I know that no one can guarantee the number 1 spot on Google or on any other search engine but I cannot even seem to get my website to the first page of Google's search results. My company is looking to hire a company or individual to work on our SEO. Does anyone here know of an SEO company or individual that has had good results in the past with getting a website to the front of Google, and preferably to the number 1 spot on Google? We are willing to pay a large sum of money for our keywords to rank on the front of Google search results. Any suggestions are welcome. Thanks John

    Read the article

  • Need Help With Finding SEO Company/Individual

    - by three3
    I am fairly new to SEO and I have done all of the tactics and operations that I know to do to help my site rank to the number 1 spot on Google. I know that no one can guarantee the number 1 spot on Google or on any other search engine but I cannot even seem to get my website to the first page of Google's search results. My company is looking to hire a company or individual to work on our SEO. Does anyone here know of an SEO company or individual that has had good results in the past with getting a website to the front of Google, and preferably to the number 1 spot on Google? We are willing to pay a large sum of money for our keywords to rank on the front of Google search results. Any suggestions are welcome. Thanks John

    Read the article

  • Import images from camera in KDE with particular directory structure

    - by Sergey
    I have been using f-spot for a few years to manage my photo archive, which is about 50K images at the moment. With the development of f-spot slowing down in the recent years and me switching to KDE, I'm looking at using DigiKam, which seems to be very nice and packed with features beyond my wildest hopes :) One thing I'm missing though is the way f-spot was importing the images: it was creating subdirectories based on the image's shooting date: $HOME/Photos/2011/11/12/IMG_1234.jpg $HOME/Photos/2011/11/13/IMG_1235.jpg $HOME/Photos/2011/11/13/IMG_1236.jpg I don't seem to be able to find a way to make DigiKam to behave like this - although it has some settings to change the image filename according to some mask which may include shooting date, I see now way to tell it to create sub-directories. Is there a way to make DigiKam to behave like this? Or, alternatively, what is a good program to import images from a camera and save them on disk in subdirectories according to their shooting date?

    Read the article

  • How do engines avoid "Phase Lock" (multiple objects in same location) in a Physics Engine?

    - by C0M37
    Let me explain Phase Lock first: When two objects of non zero mass occupy the same space but have zero energy (no velocity). Do they bump forever with zero velocity resolution vectors or do they just stay locked together until an outside force interacts? In my home brewed engine, I realized that if I loaded a character into a tree and moved them, they would signal a collision and hop back to their original spot. I suppose I could fix this by implementing impulses in the event of a collision instead of just jumping back to the last spot I was in (my implementation kind of sucks). But while I make my engine more robust, I'm just curious on how most other physics engines handle this case. Do objects that start in the same spot with no movement speed just shoot out from each other in a random direction? Or do they sit there until something happens? Which option is generally the best approach?

    Read the article

  • Looking for a web interaction layer for SmartList

    - by spot
    We run quite a few internal mailing lists with SmartList (procmail). I need to offer a web interaction ability (think Google Groups) to the mailing lists. Is there anything that will do this on top of SmartList? If not, is there anything that will do this in general on another linux mailing list manager?

    Read the article

  • Inheriting from ViewPage forces explicit casting of model in view

    - by Martin Hansen
    I try to inhering from ViewPage as shown in this question http://stackoverflow.com/questions/370500/inheriting-from-viewpage But I get a Compiler Error Message: CS1061: 'object' does not contain a definition for 'Spot' and no extension method 'Spot' accepting a first argument of type 'object' could be found (are you missing a using directive or an assembly reference?) My viewpage, normally I can do Model.ChildProperty(Spot) when I inherit from ViewPage directly, so I do that here too. But it fails. <%@ Page Language="C#" Inherits="Company.Site.ViewPageBase<WebSite.Models.SpotEntity>" %> <h1><%= Html.Encode(Model.Spot.Title) %></h1> To get it working correctly I have to do like this: <%@ Page Language="C#" Inherits="Company.Site.ViewPageBase<WebSite.Models.SpotEntity>" %> <h1><%= Html.Encode(((WebSite.Models.SpotEntity)Model).Spot.Title) %></h1> Here is my classes: namespace Company.Site { public class ViewPageBase<TModel> : Company.Site.ViewPageBase where TModel:class { private ViewDataDictionary<TModel> _viewData; [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly")] public new ViewDataDictionary<TModel> ViewData { get { if (_viewData == null) { SetViewData(new ViewDataDictionary<TModel>()); } return _viewData; } set { SetViewData(value); } } protected override void SetViewData(ViewDataDictionary viewData) { _viewData = new ViewDataDictionary<TModel>(viewData); base.SetViewData(_viewData); } } public class ViewPageBase : System.Web.Mvc.ViewPage { } } So how do I get it to work without the explicit cast?

    Read the article

  • Reverse-engineer a Javascript object?

    - by TruMan1
    I have a Javascript object that I want to pass in more parameters, but the documentation is non-existant. My only option seems to be to reverse engineer the Javascript object to see what parameters and values I can pass in. For example, I want to see if there is a "zoom" parameter for the object and what values I can pass into the "mapType" parameter: <script type="text/javascript" src="http://maps.google.com/maps?oe=utf-8&amp;file=api&amp;v=2&amp;key=your-gmap-key"></script> <script type="text/javascript" src="https://share.findmespot.com/spot-widget/js/SpotMain.js"></script> <script type="text/javascript"> var widget = new Spot.Ui.LiveWidget({ renderTo: "spot-live-widget", feeds: [ "0Wl3diTJcqqvncI6NNsoqJV5ygrFtQfBB" ], height: 400, width: 500, mapType: "physical" }); </script> <div id="spot-live-widget"/> Any ideas on how to do that?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >