code

Application Crashes when Code Optimization option is enabled

Hello, I'm having the following problem: I'm developing a C# application which requires unsafe code to call an unmanaged c++ function. The structure is: [StructLayout(LayoutKind.Sequential)] unsafe struct DataStruct { public UInt16 index; public UInt16 response; public byte* addr; //this is a pointer to a byte array which s...

I'm buying a Point of Sale software, is it possible to get full source code and for how much?

Hello all, A little company is developping a software for my business. I would like to know if it would be possible that I ask them to get the full source code. (I want to be independent) Do you think it would be possible? Do you think they will charge me an extra amount for that ? (probably) Thanks, ...

Checkstyle equivalent for JSPs?

Is there any tool to do for JSP files what checkstyle does for Java files? The ideal would be to include JSP checking on checkstyle, but as far as I can see, this isn't possible. I would like for example to check JSP files for : Indentation style Right placements of certain constructs Tab / space check Check for use of scriplets Tha...

Mix and Match Discount Code Advice

I need advice on how to implement. I have two objects ReceiptLine and Discount. Cashier scans item and a receiptline object is added. If the added ReceiptLine object have a Discount Id then, it has to lookup in Discount object and issues discount after validation. I have problem in validation. Here is the situation, cashier scans the ite...

Have we become too dependent on google?

In the good old days when the internet was non-existent , programmers had the following tools at there peril: Books Teachers Yes, thats it! just two resources. When searching for example code they either had to copy the code from a colleague or simply read several books until they found the code which they needed. It was a very long ...

WPF: Dynamic Actions in Template

Hi, I've defined a control Template for a progressbar to make it look like a thermometer ... now i want it to change its color when reaching a certain value (for example .. when the progressbar has the value 70, its color should change to yellow) Currently the color of PART_Indicator is bound to the background color of the progressbar ...

How it is done? i want one of this mosaics for my site

http://www.aetv.com/criss-angel-mindfreak/season-6/scorpion-mosaic/ ...

GWT code splitting strange behaviour in IE8

Hi everyone, I have a widget (Main.java) which encapsulates funcionality and implements the Async Provider pattern for code splitting. In addition, I use the Prefetching pattern so that the browser downloads the code inmediatly after it loads a Welcome screen. The problem raises in IE8. If I use the Main widget without doing prefetchin...

send mail from client and server in php

Hi everyone, i have request form in my site. i submit the form in php the mail send to server.i need a code the mail send to server and "thank you for request" mail send to client at a time . Example: <?php ob_start(); $namecp = $_POST['namecp']; $namec = $_POST['namec']; $mobile = $_POST['mobile']; $lname = $_POST['lname']; $pro...

Runtime Revolution simple but hard question...

Can anyone convert this RunRev function to a usable PHP function? I'm not an expert when it comes to PHP so I hope somebody helps me... Here is the RunRev code snippet, -> http://paste-it.net/public/n8a6437/ I hope somebody helps me... ...

Autofocus when scanning QR code

I'm working on a BlackBerry app, and one of the feature is QR code scanning (will be used in cafes/restaurants). Is there any way to make the camera autofocus the QR code? I did some Googling, and found this: FocusControl That looks like the one I'm looking for. Unfortunately, it's only available since OS 5.0. I wonder how to achieve...

Branch from *part* of main code, how to keep it up to date?

Was little bit difficult to formulate the title for my question since is kind of abstract... Let me try to explain. I have a main code which has a git repository, I decided to take part of that code and make it a stand alone app. with its own name and versions to be distributed. Is there a way to keep the main code and that other branc...

Personal archive tool, looking for suggestions on improving the code

i've written a tool in python where you enter a title, content, then tags, and the entry is then saved in a pickle file. it was mainly designed for copy-paste functionality (you spot a piece of code you like on the net, copy it, and paste it into the program), not really for handwritten content, though it does that with no problem. i ma...

RunOnce in Foreach

Hey All, I'm writing a little scripting language just for a bit of fun and the learning of the codes :P I would just like your opinions/suggestions. I have an idea but I don't want to include something that people are going to want to spit on. I plan on making this language open source once, soon. Does anybody think that it would be c...

Large amount of Javascript code that does nothing?

I'm trying to make one of my scripts seem really complicated, when it's not. I was wondering if anyone had a snippet of code or something that would help, or a nudge in the right direction? EDIT: I need this because I'm trying to hide an algorithm for something in the middle of the nonsense code. ...

Can Javascript get a function as text?

Can Javascript get a function as text? I'm thinking like the inverse of eval(). function derp() { a(); b(); c(); } alert(derp.asString()); The result would be something like "a(); b(); c();" Does it exist? ...

Settingup Xcode project to add new file in custom directory

How can i setup my Xcode project so that it creates new class files (.h/.m) in Classes directory and new interface files (.xib/.nib) in Interfaces directory? By default Xcode adds new files in the root project directory, and i have to manually put these into Classes and Interfaces directories. Edit: I'm referring to the Xcode File >...

What's the best way to verify that an element is ready for use in a foreach() loop in php?

example: foreach($boxes as $box) { echo "$box \n"; } Used to be fairly easy, I could just wrap the foreach around a check like: if(is_array($boxes) && count($boxes) > 0) { //foreach loop here } Without having to worry about a warning getting thrown if for whatever reason bad input was passed to the $boxes array. When...

What is the best free Code Generators for ASP.net C#? and Best Snippet Tool?

What is the best free Code Generators for ASP.net C#? I know it is opinion based but I would like to have a list and I searched and found a few and some that said they were free but ended up only being a free trial. Also what is the Best Snippet Tool to add snippets to Visual Studio 2008? I can not get the one I found to work since I ...

Building and code signing an iPhone Application from the command line.

I want to make my iPhone Apps in Emacs now, so without using Xcode at all. How can I build and codesign my app from the command line (even through SSH)? I can't use xcodebuild as there is no Xcode project. Are there any tutorials which cover this? I want to compile them with GCC, and as soon as Developer Tools 4.0 come out, I want to co...