Search Results

Search found 328 results on 14 pages for 'jacob relkin'.

Page 9/14 | < Previous Page | 5 6 7 8 9 10 11 12 13 14  | Next Page >

  • Linking to a C library compiled as C++

    - by Jacob
    I'm in linker paradise now. I have a C library which only compiles in Visual C++ (it probably works in gcc) if: I compile it as C++ code Define __cplusplus which results in all the declarations being enclosed in extern "C" { } So, by doing this I have a static library called, say, bsbs.lib Now, I have a C++ project called Tester which would like to call function barbar in declared in bsbs.h. All goes fine, until I try to link to bsbs.lib where I get the all-too-familiar: Tester.obj : error LNK2001: unresolved external symbol _foofoo And it always seems to be foofoo which cannot be resolved regardless of which function I call in Tester (barbar or anything else).

    Read the article

  • php Form to Email sanitizing

    - by Jacob
    Hi, im using the following to send a contact us type form, iv looked into security and only found that you need to protect the From: bit of the mail function, as ive hardcoded this does that mean the script is spamproof / un-hijackable $tenantname = $_POST['tenan']; $tenancyaddress = $_POST['tenancy']; $alternativename = $_POST['alternativ //and a few more //then striptags on each variable $to = "[email protected]"; $subject = "hardcoded subject here"; $message = "$tenantname etc rest of posted data"; $from = "[email protected]"; $headers = "From: $from"; mail($to,$subject,$message,$headers);

    Read the article

  • MATLAB Magical Mystery timing behavior

    - by Jacob Lyles
    I am experiencing some very odd timing behavior from a function I wrote. If I wrap my function inside another empty container function, it gets a 3x speedup. > tic; foo(args); toc time elapsed: ~140 seconds >tic; bar(args); toc time elapsed: ~35 seconds Here's the kicker - the definition of bar(): define bar(args) foo(args) end Is there some sort of optimization that gets triggered in MATLAB for nested function calls? Should I be adding a dummy function to every function that I write?

    Read the article

  • Microsoft sublanguage string to locale identifier

    - by Jacob
    I can't seem to find a way to convert, or find, a local identifier from a sublanguage string. This site shows the mappings: http://msdn.microsoft.com/en-us/library/dd318693(v=VS.85).aspx I want the user to enter a sublanguage string, such as "France (FR)" and to get the local identifier from this, which in this case would be 0x0484. Or the other way around, if a user enters 0x0480 then to return French (FR). Has anyone encountered this problem before and can point me in the right direction? Otherwise I'm going to be writing a few mapping statements to hard code it and maintain future releases if anything changes. BTW, I'm coding in C++ for Windows platform. Cheers

    Read the article

  • Correct way to give users access to additional schemas in Oracle

    - by Jacob
    I have two users Bob and Alice in Oracle, both created by running the following commands as sysdba from sqlplus: create user $blah identified by $password; grant resource, connect, create view to $blah; I want Bob to have complete access to Alice's schema (that is, all tables), but I'm not sure what grant to run, and whether to run it as sysdba or as Alice. Happy to hear about any good pointers to reference material as well -- don't seem to be able to get a good answer to this from either the Internet or "Oracle Database 10g The Complete Reference", which is sitting on my desk.

    Read the article

  • PHP PDO fetch null

    - by Jacob
    How do you check if a columns value is null? Example code: $db = DBCxn::getCxn(); $sql = "SELECT exercise_id, author_id, submission, result, submission_time, total_rating_votes, total_rating_values FROM submissions LEFT OUTER JOIN submission_ratings ON submissions.exercise_id=submission_ratings.exercise_id WHERE id=:id"; $st = $db->prepare($sql); $st->bindParam(":id", $this->id, PDO::PARAM_INT); $st->execute(); $row = $st->fetch(); if($this->total_rating_votes == null) // this doesn't seem to work even though there is no record in submission_ratings???? { ... }

    Read the article

  • Can Crystal Reports Scale to Fit Page

    - by Jacob Reyes
    Hello , Can a crystal report be scaled to fit page? I'm hoping to achieve something similar to Microsoft Excel's Scale To Fit feature wherein a large spreadsheet can be scaled to fit a 8.5"x 11" page. (On MS Excel 2007 goto Page Layout Scale To Fit). Im searching of a way to make a large report fit into a smaller page during print. for example a report designed in Legal(8.5"x 14") page must be able to shrink when print previewed for Letter(8.5"x 11") page. In my crystal report, it should be scaled to fit the page by default. I was thinking maybe theres a Crystal Report Setting or C# code technique that I missed out. Any hint or link to the right direction is appreciated. Thanks!

    Read the article

  • Java OS X - No app icon in dock

    - by Jacob
    I am using Jar Bundler to create a .app file out of my .jar file. When I launch the app, I do not want a dock icon to show at all. I have already tried modifying my .plist file to include: <string>NSUIElement</string> <key>1</key> But it does not work... Any help?

    Read the article

  • Show ContextMenuStrip from ToolStripDropDown without dismissing ToolStripDropDown

    - by Jacob G
    I have a ToolStrip. In my ToolStrip I have a ToolStripDropDownButton. My ToolStripDropDownButton has a DropDown of type ToolStripDropDown that contains a ToolStripControlHost which contains a Label. I have assigned a ContextMenuStrip to my Label. When I show the DropDown and right-click on the label, the ContextMenuStrip displays correctly, but the original DropDown is dismissed. I can understand the existence of underlying code to prevent the display of two "ToolStripItems" at the same time and I'm assuming that's what I'm running in to here. Anybody know of a way around it?

    Read the article

  • Sparse linear program solver

    - by Jacob
    This great SO answer points to a good sparse solver, but I've got constraints on x (for Ax = b) such that each element in x is >=0 an <=N. The first thing which comes to mind is an LP solver for large sparse matrices. Any ideas/recommendations?

    Read the article

  • Maven - add dependency on artifact source

    - by Jacob Hansson
    I have two maven modules, one that ends up as a jar, and one war that depends on that jar. I want the jar module to package it's source code together with the compiled classes in the jar, so that the second module is able to access it. I have tried using the maven-source-plugin, but I am confused as to how to add a dependency on the output of that. It seems that the dependency by default goes to the compiled jar, and not the source-code jar (ending with "-source.jar") that maven-source-plugin creates. How do I add the "-source.jar" as a dependency, while still preserving the dependency on the compiled sources?

    Read the article

  • NSContextManagedObject - Problem Accessing it

    - by Jacob
    I have tab bar navigation application and The problem is that in my root controller I am able to set its NSContextManagedObject to the app delegates...However when I try to do the same on the other controller the application freezes... This only happens in the ViewDidLoad but thats where I need to set it so I can fetch the data

    Read the article

  • How can I implement a jquery ajax form which requests information from a web api via a php request?

    - by Jacob Schweitzer
    I'm trying to implement a simple api request to the SEOmoz linkscape api. It works if I only use the php file but I want to do an ajax request using jquery to make it faster and more user friendly. Here is the javascript code I'm trying to use: $(document).ready(function(){ $('#submit').click(function() { var url=$('#url').val(); $.ajax({ type: "POST", url: "api_sample.php", data: url, cache: false, success: function(html){ $("#results").append(html); } }); }); }); And here is the part of the php file where it takes the value: $objectURL = $_POST['url']; I've been working on it all day and can't seem to find the answer... I know the php code works as it returns a valid json object and displays correctly when I do it that way. I just can't get the ajax to show anything at all!!

    Read the article

  • Defining golang struct function using pointer or not

    - by Jacob
    Can someone explain to me why appending to an array works when you do this: func (s *Sample) Append(name string) { d := &Stuff{ name: name, } s.data = append(s.data, d) } Full code here But not when you do this: func (s Sample) Append(name string) { d := &Stuff{ name: name, } s.data = append(s.data, d) } Is there any reason at all why you would want to use the second example.

    Read the article

  • Calling member method on unmanaged C++ pointer from C# (I think)

    - by Jacob G
    I apologize in advance if this is a trivial question... I'm pretty C++ / unmanaged dumb. Here's a simplified analog to my setup: --In myUnmanagedObject.h in DLL: class myUnmanagedObject { public: virtual void myMethod(){} } --In MyControl.h in Assembly #1: #pragma make_public(myUnmanagedObject) [event_source(managed)] public ref class MyControl : public System::Windows::Forms::UserControl { public: myUnmanagedObject* GetMyUnmanagedObject(); } --in C# in Assembly #2: unsafe { MyControl temp = new MyControl(); myUnmanagedObject* obj = temp.GetMyUnmanagedObject(); obj-myMethod(); } I get a compile error saying that myUnmanagedObject does not contain a definition for myMethod. Assembly #2 references Assembly #1. Assembly #1 references DLL. If I compile the DLL with /clr and reference it directly from Assembly #2, it makes no difference. How, from C#, do I execute myMethod ?

    Read the article

  • ASP MVC LINQ to SQL IQueryable Array out of bounds?

    - by Jacob Huggart
    Hey guys, I have an Iqueryable that is populated from the database and then converted to an Array. That works fine. The issue is when I only have 1 element in the Array. I try to use the 0th element and it says "ArrayOutOfBoundsException". When I have 2+ elements in the array and pull elements 0 and 1 it works fine. What gives?

    Read the article

  • How do you tell that your unit tests are correct?

    - by Jacob Adams
    I've only done minor unit testing at various points in my career. Whenever I start diving into it again, it always troubles me how to prove that my tests are correct. How can I tell that there isn't a bug in my unit test? Usually I end up running the app, proving it works, then using the unit test as a sort of regression test. What is the recommended approach and/or what is the approach you take to this problem? Edit: I also realize that you could write small, granular unit tests that would be easy to understand. However, if you assume that small, granular code is flawless and bulletproof, you could just write small, granular programs and not need unit testing. Edit2: For the arguments "unit testing is for making sure your changes don't break anything" and "this will only happen if the test has the exact same flaw as the code", what if the test overfits? It's possible to pass both good and bad code with a bad test. My main question is what good is unit testing since if your tests can be flawed you can't really improve your confidence in your code, can't really prove your refactoring worked, and can't really prove that you met the specification?

    Read the article

  • jQuery re-checking check boxes

    - by Jacob
    Hi, I having problems with re-checking some checkboxes after and ajax call updates a table. I have a table of what the project calls 'shares'. I want to: 1) check for and save any checked shares to an array 2) Do my ajax call to update the table of shares 3) Re-check any there we checked before the ajax update. My code is not working and I can't see why? Any tips, help or advise much appreciated. // Array to hold our checked share ids var savedShareIDs = new Array(); // Add checked share ids into array $("input:checkbox[name=share_ids]:checked").each(function() { savedShareIDs.push($(this).val()); }); // Do ajax update Dajaxice.pagination_shares('Dajax.process',{'id':1, 'page':1}) // Re-check any that were checked before ajax update $("input:checkbox[name=share_ids]").each(function() { if ( $.inArray( $(this).val(), savedShareIDs) > -1 ) { $(this).attr('checked',true) } }); The problem is the checkboxes are not checking. I'm pretty sure the loop is working and the inArray check works. Just not checking the checkboxes. Can anyone see where I'm going wrong? Thanks.

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14  | Next Page >