Search Results

Search found 464 results on 19 pages for 'segments'.

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

  • Trouble adding success flag to onbeforeunload

    - by Dirty Bird Design
    having issues with onbeforeunload. I have a long form broken into segments via a jquery wizard plug in. I need to pop a confirm dialog if you hit back, refresh, close etc on any step but need it to NOT POP the confirm dialog on click of the submit button. had it working, or at least I thought, it doesn't now. <script type="text/javascript"> var okToSubmit = false; window.onbeforeunload = function() { document.getElementById('Register').onclick = function() { okToSubmit = true; }; if(!okToSubmit) return "Using the browsers back button will cause you to lose all form data. Please use the Next and Back buttons on the form"; }; </script> 'Register' is the submit button ID. Please help!

    Read the article

  • How can I use a single UIToolbar with multiple different UIViewControllers?

    - by Aeonaut
    I have a simple app with two basic screens, a UIMapView and a UITableView. I'd like to have a toolbar at the bottom with a couple of buttons and a UISegmentedControl with two segments: "Map" and "Table". (The layout is similar to the Google Maps app that ships with the iPhone.) How can I keep the same toolbar while presenting either the UIMapView (with a UIMapViewController) or the UITableView (with a UITableViewController) when the user switches back and forth on the segmented control? Of course, I can just create an identical toolbar for each of the two different views and display them separately, but is there a better way?

    Read the article

  • JQuery delegate what may cause it to not function

    - by Jafin
    I have a webpage using jquery 1.42 The following 2 segments of code live in my page. $('body').delegate('h2', 'click', function() { $(this).after("<p>delegate paragraph!<\/p>"); }); $('body h2').live('click', function() { $(this).after("<p>live paragraph!<\/p>"); }); The live method always works, yet the delegate doesn't fire at all. If I create a trivial page with simple html <body><h2>blah</h2></body> both approaches work. So I'm assuming there is something else going on in my page. With firebug I am seeing no javascript errors, no html errors. and breakpoints on the delegate method definately do not get hit. What else might be the cause of delegate not triggering?

    Read the article

  • Calculate angle of moving ball after collision with angled or sloped wall that is a 2D line segment

    - by Ben Mc
    If you have a "ball" inside a 2D polygon, made up of say, 4 line segments that act as bounding walls, how do you calculate the angle of the ball after the collision with the irregularly sloped wall? I know how to make the ball bounce if the wall is horizontal, vertical, or at a 45 degree angle. I also have my code setup to detect a collision with the wall. I've read about dot products and normals, but I cannot figure out how to implement these in Java / Android. I'm completely stumped and feel like I've looked up everything 10 pages deep in Google 10 times now. I'm burned out trying to figure this out, I hope someone can help.

    Read the article

  • Increasing TCP/IP Window size

    - by Lior
    I am trying to send messages over tcp/ip between two servers. I want to send a message that is 30KB. But I want to send it with as a whole. I don't want tcp protocol to break it into segments. I am using communication between 2 Windows Server 2008 R2. The client and the server are coded using c#. I tryed using tcpclnt.SendBufferSize = 100000; tcpclnt.Client.DontFragment = true; and the same at the server. I also tried configuring the window size of the server(editing the registry).

    Read the article

  • Matlab: Randomize and Split

    - by Null-Hypothesis
    I have following data matrix in Matlab, I am trying to actually split this into multiple segments by passing a variable to a matlab function. But before splitting I would like to shuffle the matrix. The size of my matrix is 150X4 s.data 5.1000 3.5000 1.4000 0.2000 4.9000 3.0000 1.4000 0.2000 4.7000 3.2000 1.3000 0.2000 4.6000 3.1000 1.5000 0.2000 5.0000 3.6000 1.4000 0.2000 .. s = data: [150x4 double] labels: [150x1 double] Coming from R environment I find MatLab is very strange. Initially I thought the columns in matrix has a relationshop like in a R dataframe but thats wrong in my assumption.

    Read the article

  • syntax to express mathematical formula concisely in your language of choice

    - by aaa
    hello. I am developing functional domain specific embedded language within C++ to translate formulas into working code as concisely and accurately as possible. Right now my language looks something like this: // implies two nested loops j=0:N, i=0,j (range(i) < j < N)[T(i,j) = (T(i,j) - T(j,i))/e(i+j)]; // implies summation over above expression sum(range(i) < j < N))[(T(i,j) - T(j,i))/e(i+j)]; I am looking for possible syntax improvements/extensions or just different ideas about expressing mathematical formulas as clearly and precisely as possible. Can you give me some syntax examples relating to my question which can be accomplished in your language of choice which consider useful. In particular, if you have some ideas about how to translate the above code segments, I would be happy to hear them Thank you

    Read the article

  • Reason for not properly closed socket?

    - by gc
    Here is what I am trying to do: The server sends message to connected clients when new messages are available. The client, on the other hand, when connected, tries to send a message to the server using send() and then receive message using recv(), right after that, the client calls close() to close the connection. Sometimes, after the client finishes, the server tries to receive message from client will result in a 104 - "connection reset by peer" error. When this happens, Wireshark reveals that the last two segments sent by the client is: 1. an ACK acknowledging the receipt of the message sent by the server 2. a RST/ACK No FIN is sent by the client. Why is this happening and how can I close the socket "properly" at the client?

    Read the article

  • ASP.NET URL Re-writing; Is this possible?

    - by James Evans
    My app is currently written to accept vendor and product information like this. http://www.mydomain.com/foo.aspx?v=1&p=100 could this be re-written like this? http://www.mydomain.com/1/100/foo Since the values in the original query string are database IDs, how would I express newly created IDs as segments of the "path" in the re-written version of the URL? My goal would be to create more of an automated solution that would accomplish this. EDIT: The app is written using ASP.NET webforms, .NET 4.0 and IIS 7

    Read the article

  • Parsing HTML "Visually"

    - by Midhat
    OKay I am at loss how to name this question. I have some HTML files, probably written by lord Lucifier himself, that I need to parse. It consists of many segments like this, among other html tags <p>HeadingNumber</p> <p style="text-indent:number;margin-top:neg_num ">Heading Text</p> <p>Body</p> Notice that the heading number and text are in seperate p tags, aligned in a horizontal line by css. the css may be whatever Lucifier fancies, a mixture of indents, paddings, margins and positions. However that line is a single object in my business model and should be kept as such. So How do I detect whether two p elements are visually in a single line and process them accordingly. I believe the HTML files are well formed if it helps.

    Read the article

  • troulbe adding success flag to onbeforeunload

    - by Dirty Bird Design
    having issues with onbeforeunload. I have a long form broken into segments via a jquery wizard plug in. I need to pop a confirm dialog if you hit back, refresh, close etc on any step but need it to NOT POP the confirm dialog on click of the submit button. had it working, or at least I thought, it doesn't now. <script type="text/javascript"> var okToSubmit = false; window.onbeforeunload = function() { document.getElementById('Register').onclick = function() { okToSubmit = true; }; if(!okToSubmit) return "Using the browsers back button will cause you to lose all form data. Please use the Next and Back buttons on the form"; }; </script> 'Register' is the submit button ID. Please help!

    Read the article

  • Abstract Classes and ReadOnly Properties

    - by serhio
    Let's have three classes; Line PoliLine SuperPoliLine for all that three classes a Distance is defined. But only for the Line a Distance can be Set. Is there a possibility to build a common abstract (MustInherit) class Segment, having a Distance as (abstract +? ReadOnly) member? Question for VB.NET, but C# answers welcomed too. Business Background Imagine a Bus. It has a lot of Stations, MainStations, and 2 TerminalStations. So Line is between 2 Stations, PoliLine is between 2 MainStations, and SuperPoliLine is between 2 TerminalStations. All "lines" are "Segments", but only the distance A-B between 2 stations - Line can be defined.

    Read the article

  • how to tesselate bezier triangles?

    - by Cheery
    My concern are quadratic bezier triangles which I'm trying to tesselate for rendering them. I've managed to implement this by subdividing the triangle recursively like described in a wikipedia page. Though I'd like to get more precision to subdivision. The problem is that I'll either get too few subdivisions or too many because the amount of surfaces doubles on every iteration of that algorithm. In particular I would need an adaptive tesselation algorithm that allows me to define the amount of segments at the edges. I'm not sure whether I can get that though so I'd also like to hear about uniform tesselation techniques. Hardest trouble I have trouble with calculating normals for a point in bezier surface, which I'm not sure whether I need, but been trying to solve out.

    Read the article

  • Quick CPU ring mode protection question

    - by b-gen-jack-o-neill
    Hi, me again :) I am very curious in messing up with HW. But my top level "messing" so far was linked or inline assembler in C program. If my understanding of CPU and ring mode is right, I cannot directly from user mode app access some low level CPU features, like disabling interrupts, or changing protected mode segments, so I must use system calls to do everything I want. But, if I am right, drivers can run in ring mode 0. I actually don´t know much about drivers, but this is what I ask for. I just want to know, is learning how to write your own drivers and than call them the way I should go, to do what I wrote? I know I could write whole new OS (at least to some point), but what I exactly want to do is acessing some low level features of HW from standart windows application. So, is driver the way to go?

    Read the article

  • WPF, convert Path.DataProperty to Segment objects

    - by user275587
    I was wondering if there was a tool to convert a path data like "M 0 0 l 10 10" to it's equivalent line/curve segment code. Currently I'm using: string pathXaml = "<Path xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\" xmlns:x=\"http://schemas.microsoft.com/winfx/2006/xaml\" Data=\"M 0 0 l 10 10\"/>"; Path path = (Path)System.Windows.Markup.XamlReader.Load(pathXaml); It appears to me that calling XamlParser is much slower than explicitly creating the line segments. However converting a lot of paths by hand is very tedious.

    Read the article

  • TypeError: Cannot find function 1.0.

    - by Newtopian
    Hi, I have a script and I'm almost done but I get this error and frankly I have no idea what is wrong here. I'm rather new to Javascript so I suspect I did something wrong in the syntax somewhere. Here is an extract from the script containing the offending line : var gc = 0; var seg; var segCount = 0; var groupCount = 0; var groupLevel = 0; var segments = new Array(); var sk = ""; for(gc = 0; gc = groupDelimiters.length) break; if(seg.name() == groupDelimiters[gc]) { //ok we start another group grKeys.startNewGroup(groupLevel, groupCriterionExtractors[groupLevel](segCount), groupCount); groupLevel = gc + 1; //This line is flagged with the error in the title groupCount++; } } ideas, pointers, any help would be appreciated.

    Read the article

  • Determining if two rays intersect

    - by Faken
    I have two rays on a 2D plane that extend to infinity but both have a starting point. They are both described by a starting point and a vector in the direction of the ray extending to infinity. I want to find out if the two rays intersect but i don't need to know where they intersect (its part of a collision detection algorithm). Everything i have looked at so far describes finding the intersection point of two lines or line segments. Anyone know a fast algorithm to solve this?

    Read the article

  • Is it possible to use bindModel to bind 3 different nested tables in CakePHP

    - by paullb
    I have a segment which can have many comments and each comment can have many tags. I can bind the comments to the segments using code like the below which is a function in the segment model class. function prepareForGettingSegmentsWithComments() { $this->bindModel( array('hasMany' => array( 'Comment' => array( 'className' => 'Comment', 'foreignKey' => 'segmentID' ) ) ) ); } However how can I bind in the Tags as well?

    Read the article

  • PHP Extract Values From One String Based on a Pattern Defined in Another

    - by ironkeith
    I have two strings: $first = '/this/is/a/string'; $second = '/this/:param1/a/:param2'; And I'm trying to get this: $params = array('param1' => 'is', 'param2' => 'string'); But getting from point a to b is proving more than my tired brain can handle at the moment. Anything starting with a ':' in the second string defines a variable name/position. There can be any number of variables in $second which need to be extracted from $first. Segments are separated by a '/'. Thanks.

    Read the article

  • Apple HTML5 progressive streaming

    - by seanc
    Is there a copy of the file saved to the ipad/ipod when using progressive http download (apple segmented) that the user could potentially copy off the device? meaning, is this scenario considered 'safe' from a content protection pov: 1. user comes to websites with movies behind paywall 2. user selects a movie to watch online (progressively downloaded or 'pseudo-streamed') 3. segments are downloaded seamlessly by html5 video tag as part of .m3u8 4. movie plays/ends. is there any full copy of this movie on the device that can be transferred off? anyone know apple's stance on this?

    Read the article

  • Return segmented average from SQL Query?

    - by Guillaume Filion
    Hi, I measure the load on DNS servers every minute and store that into an SQL DB. I want to draw a chart of the load for the last 48 hours. That's 69120 (48*24*60) data points but my chart's only 800 pixels wide so to make things faster I would like my SQL query to return only ~800 data points. It's seems to me like a pretty standard thing to do, but I've been searching the web and in books for such a thing for a while now and the closest I was able to find was a rolling average. What I'm looking for a more of a "segmented average": divide the 69120 data points in ~800 segments, then average each segment. My SQL table is: CREATE TABLE measurements ( ip int, measurement_time int, queries int, query_time float ) My query looks like this SELECT ip, queries FROM measurements WHERE measurement_time>(time()-172800) Thanks a lot!

    Read the article

  • Cure for puzzle piece programming habbits?

    - by Recursion
    Even though I went to a decent CS school, I was still taught with the mentality of programming with puzzle pieces. By puzzle pieces I mean, looking up code segments at each step of the development process and adding them together as needed. Eventually gathering all of the pieces and having a properly working program. So as an example, if in my program the next step is to tokenize a string, I go to google and search "how do I tokenize a string in language". All instead of critically thinking about its implementation. I personally don't think its a very good way to program and I always seem to forget everything that I have searched for. So how can I get out of this puzzle piece mode of programmer that I was taught.

    Read the article

  • How do i find out in sql what db name I'm connect to

    - by gjutras
    We have a change control environment where the developers give scripts to change control people to run. we have dev,qa, & production environments. I want to conditionalize a couple segments to do some different things depending on what database the change control person is running my script. If @dbname='dev' then begin --do some dev stuff end If @dbname='QA' then begin --do some qa stuff end If @dbname='Prod' then begin --do some production stuff end How do I get at what the current connected database is and fill @dbname?

    Read the article

  • Adding Descriptive Flex Field (DFF) through OAF Personalization

    - by Manoj Madhusoodanan
    In this blog I will explain how to add a DFF to a existing OAF page through personalization.I am using Supplier Quick Update Page ( /oracle/apps/pos/supplier/webui/SuppSummPG ). If you want to see how to create DFF please click here. In this scenario I am using a custom DFF. Following are the details. Application -> Payables ( Code: SQLAP )Name -> XXCUST_SUPPLIER_DFFTitle -> XXCUST - Supplier DFFTable Name -> AP_SUPPLIERSDFV View name -> XXCUST_SUPPLIER_DFVReference Fields -> ATTRIBUTE_CATEGORY Following are the Context Field Details. Prompt -> Supplier TypeValue Set -> XXCUST_SUP_TYPE ( Values : External and Internal )Reference Field -> ATTRIBUTE_CATEGORY Below table shows the segment details of XXCUST_SUPPLIER_DFF. Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4 /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin:0in; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:10.0pt; font-family:"Calibri","sans-serif"; mso-bidi-font-family:"Times New Roman";} Code Segments Column Value Set Global Data Elements Identification Number ATTRIBUTE1 15 Characters External Type ATTRIBUTE2 XXCUST_EXT_SUP_TYPE Values          Domestic           International Internal Department ATTRIBUTE2 15 Characters Following steps you need to perform to create flex item in the Quick Update page. 1) Click on Personalize Page.In the Personalize Page click on Complete View. 2) Click on Create Item.( Based on where you want to place the DFF choose appropriate layout). 3) Create flex item with following details. 4) If you want to arrange the item in the page click on Reorder. Following is the output.

    Read the article

  • My VS 2010 and ASP.NET 4 Talks Online

    - by ScottGu
    The past 7 years I’ve done an annual all day event in Arizona – organized by the most excellent Scott Cate (who always does a phenomenal job organizing the event and making it a great one). Earlier this month I visited and presented 4+ hours of content covering VS 2010, ASP.NET 4 and ASP.NET MVC 2.  NextSlide.com – a great .NET shop local to Arizona who has a great product for sharing presentations – volunteered to record the talks and publish them for free using their online presentation tool.  The recordings they did turned out really, really great – and their online player (which combines slides + camera of me + demos in one experience) is awesome.  Below you can watch the first two segments of my event – which cover VS 2010 and ASP.NET 4 – for free online using the NextSlide.com player experience.  I’ll post a link to my ASP.NET MVC 2 segment a little later in a separate blog post.  If you’ve never seen my present these talks before and are interested in the content then I’d recommend checking them out – as these recordings do a really good job capturing them. Part 1 - VS 2010 This is a 49 minute segment that starts the event and covers a bunch of the new improvements in VS 2010.  You can launch the presentation directly here or watch it inline below.  You can download powerpoint versions of my slides here. Part 2- ASP.NET 4 This 61 minute segment comes next and drills into some of the framework improvements with ASP.NET 4.  It also goes further on some of the web specific tooling improvements in VS 2010 – and towards the end demonstrates some of the great new end-to-end web deployment features provided with VS 2010 (which work for both ASP.NET Web Forms and ASP.NET MVC applications). You can launch the presentation directly here or watch it inline below: Learning More about VS 2010 and ASP.NET 4 I’ve been working on a series of blog post about VS 2010 and .NET 4.  Many of the features I covered in my two talks above are described in more detail in posts within the series.  You can read all of them here. I’ll be continuing adding to the series via my blog, so stay tuned for more in-depth posts about a bunch more new features. Hope this helps, Scott P.S. People often ask whether they can re-use the slides+demos I use in my talks for talks of their own.  The answer to this is always absolutely! No need to ask permission.  Feel free to re-use all of my slides for talks of your own. P.P.S. In addition to blogging, I am also now using Twitter for quick updates and to share links. Follow me at: twitter.com/scottgu

    Read the article

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