Search Results

Search found 14344 results on 574 pages for 'path'.

Page 55/574 | < Previous Page | 51 52 53 54 55 56 57 58 59 60 61 62  | Next Page >

  • iPhone dev: load a file from resource folder

    - by thomax
    I'm writing an iPhone app with a UIWebView which should display various html files I have in the app resource folder. In xcode my project overview, these html files are displayed like this: dirA |---> index.html |---> a1.html |---> a2.html |---> my.css |---> dirB |---> b1.html |---> b2.html |---> dirC |---> c1.html |---> c2.html These resources where added to the project as such: - Checked "Copy items into destination groups folder (if needed)". - Reference type: Default. - Text encoding: Unicode (utf-8). - Recursively create groups for any added folders. The links in my html are relative, meaning they look like this: <a href="a1.html">a2</a> <a href="a2.html">a2</a> <a href="dirB/b2.html">b2</a> <a href="dirC/c1.html">b2</a> In order to display the index.html when the app starts up, I use the following code: NSString *path = [[NSBundle mainBundle] pathForResource:@"index" ofType:@"html"]; NSURL *url = [NSURL fileURLWithPath:path]; NSURLRequest *request = [NSURLRequest requestWithURL:url]; [webView loadRequest:request]; This works fine. Following links from the index file also works fine, as long as the html files requested are directly under dirA. If the link followed points to a file in a sub-directory, then didFailLoadWithError will catch the situation and report that the requested file does not exist. Note that [webView loadHtmlString:myHtml]; cannot be part of the solution, as I need back and forward buttons to work in my web view. So the question is: How can I follow a relative link to an html file in a sub directory within my resources? I've been all over stackoverflow and the rest of the tubes for the past few days trying to figure this one out, but nowhere have I come across the solution to this exact problem. Any insight at all would be very, very much appreciated!

    Read the article

  • Why does ASP.Net rewrite relative paths in runat=server anchor controls?

    - by Atomiton
    I have UserControls in a Controls folder in my solution: /Controls/TheControl.ascx If specify the following: <a runat="server" href="./?pg=1">link text</a> ASP.Net seems to want to rewrite the path to point to the absolute location. For example, If the control is on site.com/products/fish/cans.aspx the link href will be rewritten to read <a href="../../Controls/?pg=1 Why does Asp.Net rewrite these control paths, and is there an elegant way to fix it?

    Read the article

  • loading wrong jvm.dll

    - by Brittany
    When I run an executable I created, it uses the jvm.dll from C:\Windows\System32. But I want it to use the jvm.dll in C:\Program Files\Java\jdk1.6.0_17\jre\bin\server. C:\Program Files\Java\jdk1.6.0_17\jre\bin\server is in my PATH environment variable. Does anyone know how to accomplish this? Thanks.

    Read the article

  • Ant MXMLC task with arbitrary list of source/lib paths?

    - by sascha
    Does anyone know of a way to use the mxmlc task of the Flex Ant tasks with a user-definable list of source path or library paths? The idea is that the user can define an arbitrary list of source paths and/or library (swc) paths into an Ant properties file and the build file takes these values and evaluates them for use in the mxmlc task. Just wondering if there are any tricks (maybe utilizing filtering/string replacing) to get this working?

    Read the article

  • How do I pass a string or data object between two view controllers?

    - by Jonathan
    In my last question i asked how to best send a string from one view controller to another, both which were on a navigation stack: http://stackoverflow.com/questions/2898860/pass-string-from-tableviewcontroller-to-viewcontroller-in-navigation-stack However I just realised I can either pass the path to the file in the app's document's folder as the first (the table view) has already accessed the data in the file should I pass viewcontroller the data to the pushed VC?

    Read the article

  • How to draw a line between points in google map in Android

    - by wafa.cs1
    Hello I already wrote a program that read locations from android GPS ; each locatin(long , lat) will be sent to remote server to save it and display it in a website map. what I'm trying to do now is to display my path in android by drawing line between the points I didn't find any sufficient answer until this moment! so how this can be done?

    Read the article

  • Makefiles, symlinked folder & relative paths

    - by l.thee.a
    Let say I have the following folders: /A/C /D/B/E /D/B/C (this is a symlink to /A/C created by ln -s) When one of the makefiles tries to use the path /D/B/C/../E it gets a "no file or directory" error. I understand why this happens; /A/E does not exist. However I have to use symlinks to populate the B folder and create the build tree (very long story). Any ideas?

    Read the article

  • Passing a filepath to a R function?

    - by Philipp
    Hi everybody, I tried to pass a filepath to a function in R, but I failed =/ I hope someone here can help me. >heat <- function(filepath) { chicks <- read.table(file=filepath, dec=",", header=TRUE, sep="\t") ... } When I call the function, nothing happens... >heat("/home/.../file.txt") ... and "chicks" is not found >chicks Error: Object 'chicks' not found What is the correct way to pass a path to a function? Best wishes from Germany, Phil

    Read the article

  • How does file creation work in Java

    - by Ankur
    I am trying to create a file using File newFile = new File("myFile"); However no file called "myFile" is created. This is within a Web application Project i.e. proper form to be pakaged as a WAR but I am calling it as part of a main method (just to see how this works). How can I make it so that a new file is created at a location relative to the current one i.e not have to put in an absolute path.

    Read the article

  • ASP.NET MVC routing and paths is js files

    - by HiveHicks
    Hello, we're facing a problem now. We have a pretty big page with a loooong inline script, which does all the work. We now want to obfuscate it and use it as a separate .js file. But the problem is that we have paths which are generated by Url helper (Url.Content()). So what is the best way to separate js file from the page and not using hard-coded path strings?

    Read the article

  • pass string or data of local file between viewcontrollers

    - by Jonathan
    In my last question i asked how to best send a string from one view controller to another, both which were on a navigation stack: http://stackoverflow.com/questions/2898860/pass-string-from-tableviewcontroller-to-viewcontroller-in-navigation-stack However I just realised I can either pass the path to the file in the app's document's folder as the first (the table view) has already accessed the data in the file should I pass viewcontroller the data to the pushed VC?

    Read the article

  • image url helper for sinatra?

    - by yaya3
    I'm looking for an image url helper for sinatra that allows me to do something similar to staticmatic's, where I can shortcut to a relative path like so... =img "me.jpg" Can anybody point me in the direction to where this might be online, or where I could learn how to write one, or provide an example of one they have already written Many thanks

    Read the article

  • What's this setting of MATLAB for(which is causing lots of troubles for lots of people)?

    - by Runner
    This setting in PATH: D:\MATLAB\R2007b\bin\win32 Here is a fresh bad affect by this setting for me: http://stackoverflow.com/questions/2712913/why-does-this-program-require-msvcr80-dll-and-whats-the-best-solution-for-this-k And here's an issue reported by another guy: http://groups.google.com/group/ggobi/browse_thread/thread/dacea0fa93dcaf75 What's that setting for and why it's causing so many problems?

    Read the article

  • AuthSub target path prefix does not match the provided "next" URL

    - by dweebsonduty
    I am trying to use the Gcal API in PHP. I am using the ZEND framework function getAuthSubUrl($company) { $next = "http://$company.mysite.com"; $scope = 'http://www.google.com/calendar/feeds/'; $secure = false; $session = true; return (Zend_Gdata_AuthSub::getAuthSubTokenUri($next, $scope, $secure, $session)); } $authSubUrl = getAuthSubUrl(); echo "<a href=\"$authSubUrl\">login to your Google account"</a> I am not sure what I am doing wrong here. I am following the google example almost exactly. They do have $next = getCurrentUrl(); in their expample but I am getting undefined errors when I try that.

    Read the article

  • Add shadow to UIImage drawn in rounded path

    - by Tom Irving
    I'm drawing a rounded image in a UITableView cell like so: CGRect imageRect = CGRectMake(8, 8, 40, 40); CGFloat radius = 3; CGFloat minx = CGRectGetMinX(imageRect); CGFloat midx = CGRectGetMidX(imageRect); CGFloat maxx = CGRectGetMaxX(imageRect); CGFloat miny = CGRectGetMinY(imageRect); CGFloat midy = CGRectGetMidY(imageRect); CGFloat maxy = CGRectGetMaxY(imageRect); CGContextMoveToPoint(context, minx, midy); CGContextAddArcToPoint(context, minx, miny, midx, miny, radius); CGContextAddArcToPoint(context, maxx, miny, maxx, midy, radius); CGContextAddArcToPoint(context, maxx, maxy, midx, maxy, radius); CGContextAddArcToPoint(context, minx, maxy, minx, midy, radius); CGContextClosePath(context); CGContextClip(context); [self.theImage drawInRect:imageRect]; This looks great, but I'd like to add a shadow to it for added effect. I've tried using something along the lines of: CGContextSetShadowWithColor(context, CGSizeMake(2, 2), 2, [[UIColor grayColor] CGColor]); CGContextFillPath(context); But this only works when the image has transparent areas, if the image isn't transparent at all, it won't even draw a shadow around the border. I'm wondering if there is something I'm doing wrong?

    Read the article

  • making class accessible from class path in dynamic class loading

    - by Noona
    I have a project created in Eclipse, and I defined an interface and a class for dynamic class loading, the class is in the project directory, so I have this code in my project: if (handlerClassName != null) { TypeHandler typeHandler = null; try { typeHandler = (TypeHandler) (Class.forName(handlerClassName).newInstance()); but I get this exception: java.lang.ClassNotFoundException: "handlerClassName" what should I do to make the JVM recognize the class "handlerClassName" in my project? thanks

    Read the article

  • System.InvalidOperationException: Failed to map the path '/sharedDrive/Public'

    - by d03boy
    I'm trying to set up a page that will allow users to download files from a shared drive (where the file is actually sent via the page). So far this is what I have. public partial class TestPage : System.Web.UI.Page { protected DirectoryInfo dir; protected FileInfo[] files; protected void Page_Load(object sender, EventArgs e) { dir = new DirectoryInfo(Server.MapPath(@"\\sharedDrive\Public")); files = dir.GetFiles(); } } The aspx page looks kind of like this: <% Response.Write(System.Security.Principal.WindowsIdentity.GetCurrent().Name); %> <ul> <% foreach (System.IO.FileInfo f in files) { Response.Write("<li>" + f.FullName + "</li>"); } %> </ul> When I remove the erroneous parts of the code, the page tells me that the Windows Identity I'm using is my user (which has access to the drive). I don't understand what the problem could be or what it's even complaining about.

    Read the article

  • Dijstra shortest path algorithm with edge cost.

    - by Svisstack
    Hello, I have a directed, positive weighted graph. Each edge have a cost of use. I have only A money, i want to calculate shortest paths with dijkstra algorithm, but sum of edges costs on route must be less or equal to A. I want to do this with most smallest Dijstra modification (if I can do it with small modification of Dijkstra). Anyone can help me with this?

    Read the article

< Previous Page | 51 52 53 54 55 56 57 58 59 60 61 62  | Next Page >