Search Results

Search found 665 results on 27 pages for 'problematic'.

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

  • Bookmarkabale ajax calls with MVC routing

    - by devzero
    I have a page with a menu that uses JQuery AJAX calls to populate the page with. To reflect any changes I update the URL with a #... instead of ?... or /... So an URL that originally reads : htpp://localhost/pages/index/id=1 would look like : http://localhost/#pages/index/id=1. If a user bookmarks this, and later comes back to the page, I wonder if it's possible to use the second URL in my route decoding, or if I have to load it blank, then use the same JS/Ajax to populate the page? In my mind it is problematic to use Ajax in these cases if a user copies the link and mails it to a friend with JavaScript disabled. edit#1: Fixed some spelling.

    Read the article

  • Getting invalid context errors

    - by Andrew
    I don't have much code thus far, only this to start: UIGraphicsBeginImageContextWithOptions(bounds.size, NO, 0); CGContextRef context = UIGraphicsGetCurrentContext(); CGMutablePathRef outerPath; CGMutablePathRef highlightPath; CGRect outerRect = rectForRectWithInset(bounds, 1); CGRect highlightRect = CGRectMake(outerRect.origin.x, outerRect.origin.y + 1, outerRect.size.width, outerRect.size.height); And then the problematic bit, which when commented out, the error goes away: CGContextSaveGState(context); CGContextAddPath(context, highlightPath); CGContextSetFillColorWithColor(context, [[UIColor colorWithWhite:1.0 alpha:0.05]CGColor]); CGContextFillPath(context); CGContextRestoreGState(context); Below that is simply: UIImage *image = UIGraphicsGetImageFromCurrentImageContext(); UIGraphicsEndImageContext();

    Read the article

  • OpenGL Performance Questions

    - by Daniel
    This subject, as with any optimisation problem, gets hit on a lot, but I just couldn't find what I (think) I want. A lot of tutorials, and even SO questions have similar tips; generally covering: Use GL face culling (the OpenGL function, not the scene logic) Only send 1 matrix to the GPU (projectionModelView combination), therefore decreasing the MVP calculations from per vertex to once per model (as it should be). Use interleaved Vertices Minimize as many GL calls as possible, batch where appropriate And possibly a few/many others. I am (for curiosity reasons) rendering 28 million triangles in my application using several vertex buffers. I have tried all the above techniques (to the best of my knowledge), and received almost no performance change. Whilst I am receiving around 40FPS in my implementation, which is by no means problematic, I am still curious as to where these optimisation 'tips' actually come into use? My CPU is idling around 20-50% during rendering, therefore I assume I am GPU bound for increasing performance. Note: I am looking into gDEBugger at the moment Cross posted at Game Development

    Read the article

  • aacplus frame alignment problems

    - by Daniel Mošmondor
    I have an application that rips aac+ audio streams, cutting them at every regular interval (i.e. 10 minutes). Sometimes files are playable OK, but sometimes, Windows Media Player just closes when trying to build DirectShow graph. I am using Orban aacplus plugin, and it works under directshow. When I play this file with winamp or vlc, that have it's own aacplus decoding engine, it works fine. However, I need it to work under directshow. Anyway, problematic file is here: http://www.videophill.com/files/00272-20100418100002.aac I know that there is frame alignment error and I confirmed my theory by filling first 256 bytes with 0x00, tried to play it again, and it worked. Is there any info on aacplus frames available on the web, so I can try to find the beginning of the frame manually and cut the rest off?

    Read the article

  • Conflict resolution merge commit seems incomplete

    - by kayaker243
    There was a feature branch with conflicts. These were resolved and the resolution committed. Unfortunately, I botched the merge and a couple previously-released features regressed - this is verified by doing a diff between the merge commit sha1 and that of the previous tag. When I do git show <sha1 for merge commit> all changes are innocuous. When I do git log -Sunique_variable_added_for_feature_and_lost_after_botched_merge, I only see the commit that added unique_variable_... but not the problematic deletion from the bad merge. However, when I took the ignominious step of viewing the sha1 for the commit in a gui git client like Tower, I can clearly see the botched lines. Is there an additional switch used by Tower that I've missed entirely? Why didn't pickaxe pick up the deletion implicit in the merge commit?

    Read the article

  • Appropriate high level language to deal with binary data

    - by fortran
    Hi, I need to write a small tool that parses a textual input and generates some binary encoded data. I would prefer to stay away from C and the like, in favour of a higher level, (optionally) safer, more expressive and faster to develop language. My language of choice for this kind of tasks usually is Python, but for this case dealing with binary raw data can be problematic if one isn't very careful with the numbers being promoted to bignums, sign extensions and such. Ideally I would like to have records with named bitfields that are portable to be serialised in a consistent manner. (I know that there's a strong point in doing it in a language I already master, although it isn't optimal, but I think this could be a good opportunity to learn something new). Thanks.

    Read the article

  • Is there a way to combine streaming data retrieval with hibernate?

    - by Steve B.
    For the purposes of handling very large collections (and by very large I just mean "likely to throw OutOfMemory exception"), it seems problematic to use Hibernate because normally collection retrieval is done in a block, i.e. List values=session.createQuery("from X").list(), where you monolithically grab all N-million values and then process them. What I'd prefer to do is to retrieve the values as an iterator so that I grab 1000 or so (or whatever's a reasonable page size) at a time. Apart from writing my own iteration (which seems like it's likely to be re-inventing the wheel) is there a hibernate-native way to handle this?

    Read the article

  • Accessing non-related entities in LinqToSql entity classes

    - by Chris Johnson
    In LinqToSql, if I want to access a non-related entity in an entity partial class, how do I do this without creating a new DataContext? Here's the scenario: I have the tables Client, IssueType and ClientIssueType. A Client may specify a list of IssueTypes if they do not want to use the default IssueTypes. I have the default IssueTypes in the ClientIssueType table with a ClientId of null. In my Client partial I'd like to try to retrieve all IssueTypes, and if none are found, return all default IssueTypes. The only way I can see of accessing the IssueTypes with a null ClientId is by accessing the table through a new DataContext, which is problematic once I want to start assigning them to Issues. Where am I going wrong?

    Read the article

  • How can I update many rows with SQL in a single table?

    - by tmarouda
    Hi folks. I have a table and one of the columns holds web addresses like: 'http://...' or 'https://...'. The problem is that there are some invalid entries, like 'shttp://...' or '#http//...' (the first character is invalid) and I want to correct all of them. I use the following SQL statement: 'SELECT [...] FROM MyTable WHERE WebAddress LIKE '_http%' and I successfuly get the problematic rows. But how am I going to change/correct all of them using an UPDATE statement? If you have some other solution please share it!

    Read the article

  • iPhone screen rotates at random !

    - by Baldoph
    I use a tabBar Controller as root controller. It has 4 tabs and each of its ViewControllers has - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation { return YES; } as long as the tabBarController itself. But when I rotate the device (real or simulator), the screen turns at random! If it doesn't turn when I open the application it would have the same behavior until I quit the app. I tried to add the 4 viewControllers one by one in IB to see if one was problematic, but I obtained the same issue. It only always works when there is no tabs at all! Please tell me if you have any ideas. Thanks!

    Read the article

  • Can an app delete its own internal resources?

    - by user637884
    I am trying to find a way to delete an internal resource after an app installs. More specifically, I have a zip file included in the apk, that I unzip to the SD Card when the app is first run. But then want to delete the now unneeded zip file (the purpose being to save the user internal phone memory). I access the zip file with, Resources resources = this.getResources(); InputStream is = resources.openRawResource(R.raw.assets); But am uncertain how to then delete the resource (if even possible). I know one may ask why not simply install the app to SD Card at download. But the app includes a screen widget, and installing apps to the SD Card and using a screen widget is problematic. Thanks, Matt

    Read the article

  • Live output from .jar executed by PHP

    - by user2926097
    I have a php-script which executes a .jar-file: <?php passthru("java -jar nlp-server.jar 9000"); ?> I want to display the output generated by this .jar-file on a website. The problematic part is the fact that the .jar-file doesnt finish executing because its a server-application. Thus navigating to the php-file wont help and I didnt manage to make AJAX work either. Is there a way to display the "live" output of the .jar-file on a website?

    Read the article

  • Passing message over network

    - by Sylvestre Equy
    Hi, I'm currently trying to develop a message-oriented networking framework and I'm a bit stuck on the internal mechanism. Here are the problematic interfaces : public interface IMessage { } public class Connection { public void Subscribe<TMessage>(Action<TMessage> messageCallback); public void Send<TMessage>(TMessage message); } The Send method does not seem complicated, though the mechanism behind Subscribe seems a bit more painful. Obviously when receiving a message on one end of the connection, I'll have to invoke the appropriate delegate. Do you have any advice on how to read messages and easily detect their types ? By the way, I'd like to avoid to use MSMQ.

    Read the article

  • "No row with the given identifier exists" although it DOES exist!

    - by roesslerj
    Hello all! I am using Hibernate and getting Exception in thread "main" org.hibernate.ObjectNotFoundException: No row with the given identifier exists: [<MyDbObject>#271] What is pretty weird about this error is, that the object with the given id exists in the database. I inserted the problematic record in another run of the application. If I access it in the same run (i.e. same hibernate session) there seem to be no problems retrieving the data. Just because it could be a fault of the mapping: public class ProblemClass { @ManyToOne(optional = false) private MyDbObject myDbObject; } public class MyDbObject { @OneToMany(mappedBy = "myDbObject") private List<ProblemClass> problemClasses; } I have absolutely no clue even where to look at. Any hints highly appreciated!

    Read the article

  • Getting a "summary" of a webpage

    - by MattiasK
    I have something of a a hairy problem, I'd like to generate a couple of paragraphs of "description" of a given url, normally the start of an article. The Meta description field is one way to go but it isn't always good or set properly. It's fair to say it's a bit problematic to accomplish this from the screenscraped HTML. I had a general idea that perhaps one could scan the HTML for the first "appropriate" segment but it's hard to say what that is, perhaps something like the first paragraph containing a certain amount of text... Anyone have any good ideas? :) It doesn't have to be foolproof

    Read the article

  • Wix Installer - How to customize FatalError dialog based on server actions

    - by Paul
    I need to display different messages in the FatalError dialog depending on what caused the installation to fail. My first attempt was to make the FatalError description text point to a property, and then set this property's value when an error appeared. The problem is that this dialog runs in the InstallUISequence table and the problematic actions in the InstallExecuteSequence table, and apparently the values that are set during InstallExecuteSequence are not copied back to the UI, and thus I'm losing them when the dialog is created. Any ideas on how to solve this? Thanks!

    Read the article

  • Is `eval`ing in a CPAN module without localizing $@ a bug?

    - by rassie
    I think I've encountered a bug in Params::Validate, but I'm not sure whether I identified the problematic code piece correctly. The code in question failed to pass exceptions up the chain (using Try::Tiny), so I started debugging and found out that a class used inside the try block has a destructor. This destructor calls object methods which use Params::Validate and looking into Validate.pm source I see an eval without $@ localization, i.e. the global $@ gets overwritten. Now I see two options: Params::Validate should always localize $@ and thus it's a bug that should be reported. The bug is in the class in question, because it shouldn't use Params::Validate in a destructor. Params::Validate can stay as it is now. Which one is it? How I should I handle this situation? PS: I think that CPAN modules should be rock-solid and neither break themselves nor their environment, hence the question title.

    Read the article

  • How do you find the last element of an array while iterating using a foreach loop in php ?

    - by Vaibhav Kamble
    I am writing a sql query creator using some parameters. While doing that ,I came across this problem. In java , Its very easy to detect the last element of an array from inside the for loop by just checking the current array position with the array length. for(int i=0; i< arr.length;i++){ boolean isLastElem = i== (arr.length -1) ? true : false; } php has some different fashion. They have non integer indexes to access arrays. So you must iterate over an array using foreach loop. But it becomes very problematic when you need to take some decision (in my case to append or/and parameter while building query). I am sure there must be some standard way of doing this. How do you solve this problem normally in php ?

    Read the article

  • Calling some functions before main in C

    - by minjang
    I'd like to do some stuffs before main function. I have multiple source files. In each file, there is some work that needs to be done before main. It was no problem in C++, but problematic with C. In C++, this can be done by two ways: Exploiting a constructor of a global class/struct. Calling a function to a global variable For example, static const int __register_dummy_ = __AddRegisterMetaInfo(...); However, in C, either ways is impossible. Obviously, there is no constructor. So, the first option is inherently impossible. I thought that the second option would be possible, but not compiled in C (I tested only with Visual C++. It gives C2099.). C only allows a constant to a non-automatic variable. Is there any way to call some functions before main?

    Read the article

  • Cocos 2D v1.0.1 : Crash at changing CCMenuItemImage normal image

    - by Max
    I retrieve a crash log file, which, after XCode analysis on my archive show the problematic line of code : Date/Time: 2012-12-08 23:48:08.930 +0100 OS Version: iPhone OS 5.1.1 (9B206) Report Version: 104 Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x00000000, 0x00000000 Crashed Thread: 0 Last Exception Backtrace: 0 CoreFoundation 0x31a4088f __exceptionPreprocess + 163 1 libobjc.A.dylib 0x3188b259 objc_exception_throw + 33 2 CoreFoundation 0x31a40789 +[NSException raise:format:] + 1 3 Foundation 0x374c73a3 -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] + 91 4 Killer 0x0017ed35 -[CCSprite initWithFile:] (CCSprite.m:201) 5 Killer 0x0017e419 +[CCSprite spriteWithFile:] (CCSprite.m:93) 6 Killer 0x00123101 -[Player makeZombie] (Player.m:1363) 7 Killer 0x00105a51 -[PlayScene endOfKilling:] (PlayScene.m:1438) Which clearly indicates the second of the two following lines is crashing: NSLog(@"images %@ %@",self.zombieImage,self.zombieImageDown); [self.characterSprite setNormalImage:[CCSprite spriteWithFile:self.zombieImage]]; I know that the crash seem to happend when the user is touching the corresponding CCMeanuItemImage, is there a problem if the user is touching it, while we change the normal et selected images of it ? Is this the right manner to change its image (i do it several times during the game) ? Thanks for your ideas

    Read the article

  • Exclude subexpression from regexec in c++

    - by wyatt
    Suppose I was trying to match the following expression using regex.h in C++, and trying to obtain the subexpressions contained: /^((1|2)|3) (1|2)$/ Suppose it were matched against the string "3 1", the subexpressions would be: "3 1" "3" "1" If, instead it were matched against the string "2 1", the subexpressions would be: "2 1" "2" "2" "1" Which means that, depending on how the first subexpression evaluates, the final one is in a different element in the pmatch array. I realise this particular example is trivial, as I could remove one of the sets of brackets, or grab the last element of the array, but it becomes problematic in more complicated expressions. Suppose all I want are the top-level subexpressions, the ones which aren't subexpressions of other subexpressions. Is there any way to only get them? Or, alternatively, to know how many subexpressions are matched within a subexpression, so that I can traverse the array irrespective of how it evaluates? Thanks

    Read the article

  • How to make sure a method returns an array, even when there is only one element in Ruby

    - by doctororange
    I have a Ruby method that searches an array of hashes and returns a subset of that array. def last_actions(type = 'all') actions = @actions if type == 'run' actions = actions.select {|a| a['type'] == "run" } end return actions end This works, except when there is only one action to return, in which case I don't think it is returning an array with one element, but just the element itself. This becomes problematic later. What's a good way to ensure it returns an array of 1 element in this case? Thanks.

    Read the article

  • Using Dom Objects in PHP, the default namespace is redeclared in some nodes.

    - by TomcatExodus
    I'm working on a template engine, having migrated from regex driven to DOM driven. It appears though, that whenever I create a DomDocumentFragment to encapsulate some portion of a document temporarily, the namespace attribute is added to each node in the fragment. Since my default namespace for a given document will 99% of the time be XHTML, it's adding the XHTML namespace declaration. Being the default namespace, this seems fruitless, and ultimately nodes in any other namespace will be stripped out at render time anyways. Aside from iteratively removing namespace attributes, is there some way I can prevent this from occurring to begin with? Its quite problematic, as this will likely increase render time filesize considerably, as large portions of a given document may be stored in a fragment. I've tried $doc->normalizeDocument(), but as I assumed, it did nothing.

    Read the article

  • Latitude & longitude coordinates of Australian states/territories for database using Google Maps

    - by RMW
    Hi, We have a database which has location-based search using Google Maps API. However searching by state or territory in Australia is problematic because Google Maps locates these at the centre of the states and most population centres in Australia are on the coast. We need to hand code in the latitudes and longitudes so that when someone searches for the state 'NSW', for example, the database returns relevant results. Does anyone know where to find a list of the coordinates for the boundaries of Australian states & territories to code into the database? This will save our busy programmer a lot of time. Thanks in advance.

    Read the article

  • Android how to display and image from URL

    - by Patrick
    Hi all! I'm having trouble displaying SOME images on my android app. Just normal display image from certain URL. Some images works, some just doesn't work. For instance try displaying this image from URL: http://img191.imageshack.us/img191/7379/tronlegacys7i7wsjf.jpg It doesn't work. Doesn't even work in emulator. Could it be the EXIF info for the image is problematic? Can anyone try to see they are able to display that image on android app, and share the code/method to display that image on screen? Thank you!

    Read the article

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