conversion

Muslim Hadeeth Database / CHM to CSV or SQL

I am looking here to create a Facebook App on Hadeeth. My first question is for muslim programmers here because other might not be having clue. Is it possible to find hadeeth in csv / sql (at least the popular ones like bukhari, muslim, tirmidhi) otherwise Do we have any tools or is it possible to convert CHM files into CSV or SQL ? T...

help me with Converter please

I'm trying to bind element's Height value to Checkbox.IsChecked property. Why that's not working? <Window.Resources> <local:BoolToHeightConverter x:Key="BoolToHeightConverter"/> </Window.Resources> <Button Name="JustBtn" Content="Hello World"/> <CheckBox IsChecked="{Binding ElementName=JustButton, Path=Height, Converter=BoolT...

How to convert a Java Long to byte[] for Cassandra?

Lazy programmer alert. :) Cassandra stores column values as bytes (Java example). Specifying a LongType comparator compares those bytes as a long. I want the value of a long into a Cassandra-friendly byte[]. How? I poked around for awhile. I think you people can help me faster. EDIT: Both Alexander and Eli's answers agreed with t...

Creating SVG map from geometry stored in MySQL

I have a group of geometries stored in MySQl (as polygon and as well-known text) representing counties. I can build a table of geometries and color codes after querying some county data (say GDP per capita). What is the best way to export this as an SVG map? I cannot find any reference to SVG conversion in the MySQL documentation. ...

TinyMCE converts &lt;xxx&gt; into <xxx></xxx> - how do I stop it?

I can successfully save the characters < and >. I do this with these options: entities : """ cleanup : false verify_html : false So far no problems. However, whenever I put anything between that text it gets converted into a tag: &lt;xxx&gt; converts to <xxx></xxx> How do I stop that?I am trying to enter sample HTML into TinyM...

Error:Conversion Between Two Character Set

Hi, I am getting the error "Conversion Between Two Character Sets" when connecting to SAP from .NET using SAP .NET Connector. When i use Win XP and Visual Studio 2003 there is no problem. But when i reference the .dll from visaul studio 2008 on windows 7, the error appears. What can i do? Thanks ...

Is this the best way to convert String hex to bytes?

Is this the best way to convert String hex to bytes? Or can you think a shorter/simpler? public static byte[] hexToBytes(String hex) { return hexToBytes(hex.toCharArray()); } public static byte[] hexToBytes(char[] hex) { int length = hex.length / 2; byte[] raw = new byte[length]; for (int i = 0; i < length; i++) { int high = Charac...

How to display (converted) Word document content in Sharepoint

There is Page Viewer Web Part which can display HTML page. Is there another webpart that can display the content of the Word document or alternatively a way to convert a Document from inside OOTB Sharepoint? ...

fft and array-to-image / image-to-array-conversion

Hello! I want to make a fourier-transformation of an image. But how can I change the picture to an array? And after this I think I should use numpy.fft.rfft2 for the transformation. And how to change back from the array to the image? Thanks in advance. ...

What is CDbl doing?

I had until recently been under the impression that the CDbl(x) operation in VB.NET was essentially a cast (i.e., the VB equivalent of (double)x in C#); but a recent discovery has revealed that this is not the case. If I have this string: Dim s As String = "12345.12345-" And I do this: Dim d As Double = CDbl(s) d will be set to th...

Convert byte array to understandable String

I have a program that handles byte arrays in Java, and now I would like to write this into a XML file. However, I am unsure as to how I can convert the following byte array into a sensible String to write to a file. Assuming that it was Unicode characters I attempted the following code: String temp = new String(encodedBytes, "UTF-8"); ...

Strange problem when converting RGB to HSV

Hi, I made a small RGB to HSV converter algorithm with C. It seems to work pretty well, but there is one strange problem: If I first convert i.e. a 800x600 picture into HSV map and then back to RGB map without doing any changes in the values, I get some pixels that are convertet incorrectly. Then if I try to convert those misbehaving si...

C++ Converting image to integer array

How would I go about converting the pixels in an image (.png file) to an integer array, where each pixel is converted to its ARGB integer equivalent? Not a 2D integer array by the way, a 1D one (where access is through array[row*width+col]). Thanks. ...

How can I Unescape and Reescape strings in .net?

I need a textbox on a WPF control that can take in text like "Commit\r\n\r" (which is the .net string "Commit\r\n\r") and convert it back to "Commit\r\n\r" as a .net string. I was hoping for a string.Unescape() and string.Escape() method pair, but it doesn't seem to exist. Am I going to have to write my own? or is there a more simple w...

Iphone. Create a latitude from a string or integers

Hi. One small conversion problem that drives me crazy. I have a string (ex "35.453454") that represents a latitude. I want to use it as a latitude for CLLocation. How can I convert the string in the proper CLLocation (in degrees) format ? Many thanks, this drives me so mad ! Thomas ...

C# > VB Conversion, RelayCommand behaves differently

[Visual C#] public ICommand MyCommand { get { if (this.myCommand == null) { this.myCommand = new RelayCommand(this.ShowMyCommand); } return this.myCommand; } } private void ShowMyCommand(object param) { ... } Th...

How to go about writing this classic asp in asp.net

I am stuck in converting this snipped to asp.net. set RSLinksCat = conn.Execute("select linkscat.id, linkscat.category from linkscat, contentlinks, links where contentlinks.linksid = links.id and contentlinks.contentid = " & contentid & " and links.linkscatid = linkscat.id order by linkscat.category") <%if not RSLinksCat.EOF then%><h...

How do I use "Into" LINQ expression in VB.NET?

I'm converting from C# this LINQ expression. However, it does not seem to work. C# return (from w in fishSticks group w by w.FishQty into g orderby g.Key descending select g).First().First(); VB Return (From w In fishSticks Group w By w.FishQty Into g() Order By g.Key Descending Se...

Dump characters (glyphs) from TrueType font (TTF) into bitmaps

I have a custom TrueType font (TTF) that consists of a bunch of icons, which I'd like to render as individual bitmaps (GIF, PNG, whatever) for use on the Web. You'd think this is a simple task, but apparently not? There is a huge slew of TTF-related software here: http://cg.scs.carleton.ca/~luc/ttsoftware.html But it's all varying le...

Unusual conversion error (string to integer) asp.net

I have my repeater item template: <asp:Repeater ID="Linksrepeater" runat="server"> <HeaderTemplate><h2>Links</h2><ul> </HeaderTemplate> <ItemTemplate> <li><%#Container.DataItem("Category")%></li> </ItemTemplate> <FooterTemplate> </ul> </FooterTemplate> </asp:Repeater> Hooked up to: s = "sql" x = New SqlCommand(s, c) ...