conversion

Is anyway to make the php projects in exe format?

It is possible to make the php projects in exe format (i.e like vb project exe format) ? Please help me, thanks in advance ...

Convert SQL with Inner AND Outer Join to L2S

I need to convert the below Sproc to a Linq query. At the very bottom is what I have so far. For reference the fields behind the "splat"(not my sproc) are ImmunizationID int, HAReviewID int, ImmunizationMaintID int, ImmunizationOther varchar(50), ImmunizationDate smalldatetime, ImmunizationReasonID int The first two are PK and FK, r...

PHP - why is this date function not erroring out

function convertDT($TS) { $TS = strtotime($TS); $TS -= date("Z"); $newTS = date("Y-m-d\TH:i:s\Z", $TS); return $newTS; } echo "Good: ".convertDT('2010-04-20 01:23:45')."\n"; echo "Bad: ".convertDT('2010-31-20 01:23:45')."\n"; The second date returns: 1969-12-31T23:00:00Z Why? Should this error? ...

RenderPartial missing from Html Helper in ASP.NET MVC 2

I've just converted an application from MVC 1 to MVC 2 using the VS2010 wizard. Not found is the Html.RenderPartial which I have sprinkled around a number of views. I am guessing that this is something that I've done wrong because I see no mention of this as a breaking change in the white papers and docs. Everything I'm using is RTM/RTW ...

Can i Convert VB code to C++ code

Can I convert my VB code to C++? How can I do it? This is my VB code: Dim OpenFileDialog1 As New OpenFileDialog With OpenFileDialog1 .CheckFileExists = True .ShowReadOnly = False .Filter = "All Files|*.*|Bitmap Files (*)|*.bmp;*.gif;*.jpg" .FilterIndex = 2 If .ShowDialog = DialogResult.OK Then ' Load the sp...

How to convert an 8-bit integer into a binary string in xquery?

At work today, we threw together this attempt: xquery version "1.0"; declare option saxon:output "omit-xml-declaration=yes"; declare variable $x := 99; string-join( for $b in (128,64,32,16,8,4,2,1) let $xm := $x mod ($b*2) return if ( $xm >= $b ) then "1" else "0" , "") Do you have a better way? Takin...

Java char array to int

Hello, Is it possible to convert a char[] array containing numbers into an int? Thanks ~ Kyle. ...

Convert 64bit Binary to Long equivalent

How can we convert the following 64 bit binary into the long equivalent; 01111101 10100011 01001111 11111111 11111111 11111111 11111111 11000000 equals 7D A3 4F FF FF FF FF C0 HEX equals 9053167636875050944 << this is the value we want in a C# variable EDIT: The large binary number is currently stored as a String. So its a st...

g++ compiler complains about conversions between related types (from int to enum, from void* to class*...)

g++ compiler complains about conversions between related types (from int to enum, from void* to class*, from const char* to unsigned char*, etc.). Compiler handles such convertions as errors and won't compile furthermore. It occurs only when I compile using Dev-C++ IDE, but when I compile the same code (using the compiler which Dev-C++ u...

Mysql: Convert DB from local time to UTC

I need to convert an existing (datetime fields) db from local time ut UTC. The values are stored ad datetimes on a server with time zone CET (+1) (with summertime +2). When selecting data I use UNIX_TIMESTAMP(), which magically compensates for everything, ie, time zone shift and dst (if i've read the docs right). I'm moving the db to a...

The type or namespace name 'Mvc' does not exist in the namespace 'System.Web'

After converting a Hybrid ASP.NET MVC1 app to MVC2 I'm getting the following error when I try and run the application: The type or namespace name 'Mvc' does not exist in the namespace 'System.Web' (are you missing an assembly reference?) The allegeded culprit in the web.config file is System.Web.Mvc: <namespaces> <add namespace="S...

prevent conversion of <br/>

Hello, I fear this is a dumb question, but I can't seem to find the answer. Pretty sure what that makes me...... I have C# generated HTML (HtmlGenerator), to which I sometimes want to insert a line break at a certain part of a cell's innertext. Here is how that comes out: <TD >There are lots of extra &lt; br /&gt; words here </TD> ...

Most concise way to convert Julian date (yyyy[day of year]) to SQL datetime

I'm working with an existing database where all dates are stored as integers in the following format: yyyy[3 digit day of year]. For example: 2010-01-01 == 2010001 2010-12-31 == 2010365 I'm using the following SQL to convert to a datetime: DATEADD(d, CAST(SUBSTRING( CAST(NEW_BIZ_OBS_DATE AS VARCHAR), 5, LEN(NEW_BIZ...

How to convert a fomula to a valid identity name in C#?

In an application, I have to use a valid identity string as a value of a property. I mean the string should be a valid identity name in C#. For I want to use the string as a formula without change the source code of the component, I have to convert ANY formula, a string, to a valid identity string and convert it back when needed.Of cour...

Convert JSON query parameters to objects with JAX-RS

I have a JAX-RS resource, which gets its paramaters as a JSON string like this: http://some.test/aresource?query={"paramA":"value1", "paramB":"value2"} The reason to use JSON here, is that the query object can be quite complex in real use cases. I'd like to convert the JSON string to a Java object, dto in the example: @GET @Produce...

[C#] How to convert string encoded in windows-1250 to unicode ?

Hi! I am receiving from some dll (which is wrapper for some external data source) strings in Windows-1250 codepage and I would like to insert them correctly (as unicode) to table in SQL Server Database. Since particular row in database which should hold that data is of NVarchar type, I only needed to convert it in my C# code to unicode ...

Image Outlining Effect in .NET

I'm looking to accomplish the following effect in C#: Any ideas would be much appreciated. ...

One-liner to Convert Nested Hashes into dot-separated Strings in Ruby?

What's the simplest method to convert YAML to dot-separated strings in Ruby? So this: root: child_a: Hello child_b: nested_child_a: Nesting nested_child_b: Nesting Again child_c: K To this: { "ROOT.CHILD_A" => "Hello", "ROOT.CHILD_B.NESTED_CHILD_A" => "Nesting", "ROOT.CHILD_B.NESTED_CHILD_B" => "Nesting Again", ...

Eclipse Encoding MacRoman -> UTF8

Hi! I recently created a project, organized it and well... I used my Mac with Eclipse running. Somehow it stored everything in MacRoman. The project has to be UTF8. Is there any easy way to handle the conversions? ...

Is it possible to use Kit3D in WPF? If so, how?

I have a Silverlight application that uses Kit3D and I want to convert it to WPF. How would I do that? Should I do that? ...