Search Results

Search found 2655 results on 107 pages for 'conversion'.

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

  • invalid conversion from 'char' to 'int* in C

    - by majdal
    Hi, I have the following arrays: int A[] = {0,1,1,1,1, 1,0,1,0,0, 0,1,1,1,1}; int B[] = {1,1,1,1,1, 1,0,1,0,1, 0,1,0,1,0}; int C[] = {0,1,1,1,0, 1,0,0,0,1, 1,0,0,0,1}; //etc... for all letters of the alphabet And a function that prints the letters on a 5x3 LED matrix: void printLetter(int letter[]) I have a string of letters: char word[] = "STACKOVERFLOW"; and I want to pass each character of the string to the printLetter function. I tried: int n = sizeof(word); for (int i = 0; i < n-1; i++) { printLetter(word[i]); } But I get the following error: invalid conversion from 'char' to 'int*' What should i be doing? Thanks!!

    Read the article

  • Android Development - Conversion to Dalvik format failed with error 1

    - by KP65
    So I'm dipping my toes into this area for the first time - i followed instructions to install the android SDK and eclipse plug in. I created a blank new android project and I get the following build errors: [2011-01-08 16:34:55 - xxx]: Dxno classfiles specified [2011-01-08 16:34:55 - xxx] Conversion to Dalvik format failed with error 1 I've googled the problem and tried to clean and rebuild, or hitting F5 on the project in the explorer but the issue remains. I've verified the build paths and the libraries to make sure only Android 2.3 is there but still get this issue. I have also tried to load a sample project and I get the same error. Any ideas?

    Read the article

  • Using a Time Zone Conversion When Dynamically Generating Results

    - by John
    Hello, If I understand correctly, the code below converts $row["datesubmitted"] from one timezone to another. I would like to print the converted $row["datesubmitted"] dynamically in an HTML table. Is there a way that I can apply the conversion below for each row that is pulled from MySQL? I assume that I can't just plug $row["dt"] into the code since there is no field called "dt" in the MySQL that I am using. Thanks in advance, John $dt = new DateTime($row["datesubmitted"], $tzFrom); $dt->setTimezone($tzTo);

    Read the article

  • Error debugging - Conversion from String to Double

    - by Jamie Taylor
    I'm doing some error debugging trying to get the errors on our website down to a minimum and there seems to be an error that is popping up quite a lot Conversion from string "" to type 'Double' is not valid. I'm unable to replicate this problem but I can see that it is happening. I've been looking through the code in one of the pages and strolled across this Dim varWeek As String If varWeek < 10 Then 'Do something' End If Could this be causing the problem as it is trying to see if a String is less than 10 which is an Integer? As I said before as I am unable to see this error in the first place so changing this to an Integer doesn't change anything on my system. Thanks.

    Read the article

  • Bit conversion operations in PHP

    - by Goro
    Hello, I find myself in need of performing bit-level conversion on variables in PHP. In more detail, I have a bit stream that is read as an integer by hardware, and I need to do some operations on the bits to make it into what its actually supposed to be (a float). I have to do this a few times for different formats, and the functionality I need is Being able to select and move individual bits in a variable Being able to cast statically one type of variable to the other (ie. int to float) I know php natively supports bitwise AND, OR, etc, and shift operations, but I was wondering if: there may already be a library in php that does this sort of thing I would be better off with delegating the calculations to some other language Thanks,

    Read the article

  • C# - High Quality Byte Array Conversion of Images

    - by Lijo
    Hi Team, I am converting images to byte array and storing in a text file using the following code. I am retrieving them successfully as well. My concern is that the quality of the retrieved image is not up to the expectation. Is there a way to have better conversion to byte array and retrieving? I am not worried about the space conception. Please share your thoughts. string plaintextStoringLocation = @"D:\ImageSource\Cha5.txt"; string bmpSourceLocation = @"D:\ImageSource\Cha50.bmp"; ////Read image Image sourceImg = Image.FromFile(bmpSourceLocation); ////Convert to Byte[] byte[] clearByteArray = ImageToByteArray(sourceImg); ////Store it for future use (in plain text form) StoreToLocation(clearByteArray, plaintextStoringLocation); //Read from binary byte[] retirevedImageBytes = ReadByteArrayFromFile(plaintextStoringLocation); //Retrieve from Byte[] Image destinationImg = ByteArrayToImage(retirevedImageBytes); //Display Image pictureBox1.Image = destinationImg; Thanks Lijo

    Read the article

  • Time Zone conversion form stringdate

    - by Kishore
    Hi, I have a stringdate 16-MAY-2010 23:04:44 which i need to convert to gmt time zone that is the out put required is 17-May-2010 12:03:03. I used date formatters to convert but the result i am getting is not in the format i required.I am sending the code please let me know if i am doing correct or not Here is the code: NSString *timeStamp = [format stringFromDate:[NSDate date]]; NSString *output = [timeConv dateStringFromString:timeStamp]; (NSString *)dateStringFromString:(NSString *)sourceString { NSDateFormatter *dateFormatter = [[[NSDateFormatter alloc] init] autorelease]; [dateFormatter setFormatterBehavior:NSDateFormatterBehavior10_4]; [dateFormatter setDateFormat:@"dd-MMMM-yyyy HH:MM:ss"]; NSTimeZone *gmt = [NSTimeZone timeZoneWithAbbreviation:@"GMT"]; [dateFormatter setTimeZone:gmt]; NSDate *date = [dateFormatter dateFromString:sourceString]; return [dateFormatter stringFromDate:date]; } The out put i am getting is the same old time without conversion. so please let me know the correct solution.

    Read the article

  • Adding a conversion page trough Google Websiteoptimizer API

    - by hoppa
    Hey guys, I'm developing a module which allows users of my cms to create A/B tests from my cms instead of Google's interface. I manage to create tests and add the original page and the alternative page(s) just fine using the API documented here: http://code.google.com/apis/analytics/docs/gwo/ My issue is that i can't find documentation on how to add the conversion page. I tried Google forums but to no avail. Is there anyone here who can help me further? Thanks in advance! [edit] I don't know how badly I'm going against convention at this moment nut is there absolutely no one here who can give me a pointer in the right direction?

    Read the article

  • Generic Dictionary - Getting Conversion Error

    - by pm_2
    The following code is giving me an error: // GetDirectoryList() returns Dictionary<string, DirectoryInfo> Dictionary<string, DirectoryInfo> myDirectoryList = GetDirectoryList(); // The following line gives a compile error foreach (Dictionary<string, DirectoryInfo> eachItem in myDirectoryList) The error it gives is as follows: Cannot convert type 'System.Collections.Generic.KeyValuePair<string,System.IO.DirectoryInfo>' to 'System.Collections.Generic.Dictionary<string,System.IO.DirectoryInfo>’ My question is: why is it trying to perform this conversion? Can I not use a foreach loop on this type of object?

    Read the article

  • Automatic conversion between methods and functions in Scala

    - by fikovnik
    I would like to understand the rules when can Scala automatically convert methods into functions. For example, if I have following two methods: def d1(a: Int, b: Int) {} def r[A, B](delegate: (A, B) ? Unit) {} I can do this: r(d1) But, when overloading r it will no longer work: def r[A, B, C](delegate: (A, B, C) ? Unit) {} r(d1) // no longer compiles and I have to explicitly convert method into partially applied function: r(d1 _) Is there any way to accomplish following with the explicit conversion? def r[A, B](delegate: (A, B) ? Unit) {} def r[A, B, C](delegate: (A, B, C) ? Unit) {} def d1(a: Int, b: Int) {} def d2(a: Int, b: Int, c: Int) {} r(d1) // only compiles with r(d1 _) r(d2) // only compiles with r(d2 _) There is somewhat similar question, but it is not fully explained.

    Read the article

  • Array to string conversion in (cant get it to work)

    - by user2966551
    ok I am trying to pull a a specific row of data that corresponds to the username logged in. on my page I have started my session but for some reason I cant get the code to work.i keep getting a "Array to string conversion in " on the line " WHERE username = '$_SESSION[user]'");" what am I doing wrong? if I set username = a set username it works but I need it to draw from the session id so it will display different values based on whos logged in. <?php $con=mysqli_connect("localhost","root","xxx","xxxx"); // Check connection if (mysqli_connect_errno()) { echo "Failed to connect to MySQL: " . mysqli_connect_error(); } $result = mysqli_query($con,"SELECT * FROM users WHERE username = '$_SESSION[user]'"); while($row = mysqli_fetch_array($result)) { echo $row['username'] . " " . $row['att']; echo "<br>"; } ?>

    Read the article

  • Adobe lance un outil expérimental de conversion de Flash vers l'HTML5, « Wallaby » est disponible gratuitement pour Windows et Mac

    Adobe lance « Wallaby », un outil expérimental de conversion de Flash vers l'HTML5 Pour Windows et Mac OS Adobe vient de sortir une préversion de « Wallaby », un outil expérimental de conversion des fichiers sources Flash (.FLA) en des ensembles de fichiers HTML5, SVG, CSS, images et JavaScript pouvant fonctionner sans la présence du lecteur Adobe Player. Comme cas d'utilisation, on pense tout de suite à l'iOS d'Apple où Flash est toujours le grand absent malgré les tentatives réitérées d'Adobe, chaque fois

    Read the article

  • Google incruste son outil de conversion vers le HTML5 dans Flash Professionnel, Swiffy y est disponible en tant que plug-in

    Google incruste son outil de conversion vers le HTML5 dans Flash Professionnel Swiffy y est disponible en tant que plug-in Mise à jour du 17 novembre 2011 par Idelways Google avait sorti Swiffy en juin dernier (lire ci-devant), un outil de conversion Flash/HTML5 qu'il propose aujourd'hui en tant que plug-in pour Flash Professionnel, l'environnement phare de création d'animations multimédia d'Adobe. Cette extension disponible pour Windows et Mac OS incruste la commande d'exportation vers le HTML5 dans les menus du navigateur. Elle est aussi disponible via raccourci clavier pour une meilleure intégration au flux de travail...

    Read the article

  • Free rmvb to avi converter

    - by user23950
    Anyone here who knows a free software that could convert rmvb to avi?Please help, all that I found is free trial software which adds water mark or do only partial conversion. For windows 7 or xp.

    Read the article

  • Automating the choice between JPEG and PNG with a script

    - by MHC
    Choosing the right format to save your images in is crucial for preserving image quality and reducing artifacts. Different formats follow different compression methods and come with their own set of advantages and disadvantages. JPG, for instance is suited for real life photographs that are rich in color gradients. The lossless PNG, on the other hand, is far superior when it comes to schematic figures: Picking the right format can be a chore when working with a large number of files. That's why I would love to find a way to automate it. A little bit of background on my particular use case: I am working on a number of handouts for a series of lectures at my unversity. The handouts are rich in figures, which I have to extract from PDF-formatted slides. Extracting these images gives me lossless PNGs, which are needlessly large at times. Converting these particular files to JPEG can reduce their size to up to less than 20% of their original file size, while maintaining the same quality. This is important as working with hundreds of large images in word processors is pretty crash-prone. Batch converting all extracted PNGs to JPEGs is not an option I am willing to follow, as many if not most images are better suited to be formatted as PNGs. Converting these would result in insignificant size reductions and sometimes even increases in filesize - that's at least what my test runs showed. What we can take from this is that file size after compression can serve as an indicator on what format is suited best for a particular image. It's not a particularly accurate predictor, but works well enough. So why not use it in form of a script: I included inotifywait because I would prefer for the script be executed automatically as soon as I drag an extracted image into a folder. This is a simpler version of the script that I've been using for the last couple of weeks: #!/bin/bash inotifywait -m --format "%w%f" --exclude '.jpg' -r -e create -e moved_to --fromfile '/home/MHC/.scripts/Workflow/Conversion/include_inotifywait' | while read file; do mogrify -format jpg -quality 92 "$file" done The advanced version of the script would have to be able to handle spaces in file names and directory names preserve the original file names flatten PNG images if an alpha value is set compare the file size between the temporary converted image and its original determine if the difference is greater than a given precentage act accordingly The actual conversion could be done with imagemagick tools: convert -quality 92 -flatten -background white file.png file.jpg Unfortunately, my bash skills aren't even close to advanced enough to convert the scheme above into an actual script, but I am sure many of you can. My reputation points on here are pretty low, but I will gladly award the most helpful answer with the highest bounty I can set. References: http://www.formortals.com/introducing-cnb-imageguide/, http://www.turnkeylinux.org/blog/png-vs-jpg Edit: Also see my comments below for some more information on why I think this script would be the best solution to the problem I am facing.

    Read the article

  • convert mp4 to flv. Adobe Medio Encoder Failing.

    - by Derek Adair
    Hi, I am trying to encode a .mp4 to a .flv I've tried using the Adobe Media Encoder but the video is lost in the conversion process, leaving me a black screen and some audio. I have yet to find something that can do this successfully for free. I found ffmpeg, which looks promising... but I can't figure out how to get it to work. Any direction would be greatly appreciated. -Thanks.

    Read the article

  • Converting .doc files to .pdf

    - by ngn
    Anybody aware of a piece of software which could do MS Office .doc to .pdf conversion for me? I already tried OpenOffice but it appeared to be rather slow and resource-hungry for large documents.

    Read the article

  • CHM e-book cover extraction

    - by Robottinosino
    I would like to extract a "book cover image" from a series of CHM files, which command line tool can do that, please? I have looked at the source of the QuickLook plug-in "quickchm1.1_source" and at the calibre command line conversion options (ebook-convert) but couldn't find anything akin to simple: name_of_tool file_to_convert output_image as in: mytool routermanual.chm routermanualcoverimage.png

    Read the article

  • How to convert tar file from gnu format to pax format

    - by nosid
    On the one hand I have a lot of tar files created with gnu format, and on the other hand I have a tool that only supports pax (aka posix) format. I am looking for an easy way to convert the existing tar files to pax format - without extracting them to the file system and re-create the archives. GNU tar supports both formats. However, I haven't found an easy way to the conversion. How can I convert the existing gnu tar files to pax?

    Read the article

  • getAudioInputStream can not convert [stereo, 4 bytes/frame] stream to [mono, 2 bytes/frame]

    - by brian_d
    Hello. I am using javasound and have an AudioInputStream of format PCM_SIGNED 8000.0 Hz, 16 bit, stereo, 4 bytes/frame, little-endian Using AudioSystem.getAudioInputStream(target_format, original_stream) produces an 'IllegalArgumentException: Unsupported Conversion' when the target_format is PCM_SIGNED 8000.0 Hz, 16 bit, mono, 2 bytes/frame, little-endian Is it possible to convert this stream manually after every read() call? And if yes, how? In general, how can you compare two formats and tell if a conversion is possible?

    Read the article

  • Imagemagick PDF to JPG conversion failing

    - by sbressler
    I'm trying to convert the first page of a PDF to a JPG. I'm pretty sure I got this to work with certain PDFs, but is it really possible that certain PDFs are made incorrectly and cannot be converted? I tried running this first: $ convert 10-03-26.pdf[1] test.jpg And I got the follow: Error: /syntaxerror in readxref Operand stack: Execution stack: %interp_exit .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push --nostringval-- --nostringval-- --nostringval-- false 1 %stopped_push 1 3 %oparray_pop 1 3 %oparray_pop --nostringval-- --nostringval-- --nostringval-- --nostringval-- --nostringval-- --nostringval-- Dictionary stack: --dict:1062/1417(ro)(G)-- --dict:0/20(G)-- --dict:73/200(L)-- --dict:73/200(L)-- --dict:97/127(ro)(G)-- --dict:229/230(ro)(G)-- --dict:14/15(L)-- Current allocation mode is local ESP Ghostscript 7.07.1: Unrecoverable error, exit code 1 convert: Postscript delegate failed `10-03-26.pdf'. Running this instead: $ convert -verbose -colorspace rgb '10-03-26.pdf[1]' test.jpg I get the following: Error: /syntaxerror in readxref Operand stack: Execution stack: %interp_exit .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push --nostringval-- --nostringval-- --nostringval-- false 1 %stopped_push 1 3 %oparray_pop 1 3 %oparray_pop --nostringval-- --nostringval-- --nostringval-- --nostringval-- --nostringval-- --nostringval-- Dictionary stack: --dict:1062/1417(ro)(G)-- --dict:0/20(G)-- --dict:73/200(L)-- --dict:73/200(L)-- --dict:97/127(ro)(G)-- --dict:229/230(ro)(G)-- --dict:14/15(L)-- Current allocation mode is local ESP Ghostscript 7.07.1: Unrecoverable error, exit code 1 "gs" -q -dBATCH -dSAFER -dMaxBitmap=500000000 -dNOPAUSE -dAlignToPixels=0 "-sDEVICE=pnmraw" -dTextAlphaBits=4 -dGraphicsAlphaBits=4 "-g792x1611" "-r72x72" -dFirstPage=2 -dLastPage=2 "-sOutputFile=/tmp/magick-XXU3T44P" "-f/tmp/magick-XXoMKL8Z" "-f/tmp/magic2eec1F"Start of Image Define Huffman Table 0x00 0 1 5 1 1 1 1 1 1 0 0 0 0 0 0 0 Define Huffman Table 0x01 0 3 1 1 1 1 1 1 1 1 1 0 0 0 0 0 Define Huffman Table 0x10 0 2 1 3 3 2 4 3 5 5 4 4 0 0 1 125 Define Huffman Table 0x11 0 2 1 2 4 4 3 4 7 5 4 4 0 1 2 119 End Of Image convert: Postscript delegate failed `10-03-26.pdf'. Why would the conversion fail? Thanks!

    Read the article

  • C# exception when calling stored procedure: ORA-01460 - unimplemented or unreasonable conversion req

    - by Taylor L
    I'm trying to call a stored procedure using ADO .NET and I'm getting the following error: ORA-01460 - unimplemented or unreasonable conversion requested The stored procedure I'm trying to call has the following parameters: param1 IN VARCHAR2, param2 IN NUMBER, param3 IN VARCHAR2, param4 OUT NUMBER, param5 OUT NUMBER, param6 OUT NUMBER, param7 OUT VARCHAR2 Below is the C# code I'm using to call the stored procedure: OracleCommand command = connection.CreateCommand(); command.CommandType = CommandType.StoredProcedure; command.CommandText = "MY_PROC"; OracleParameter param1 = new OracleParameter() { ParameterName = "param1", Direction = ParameterDirection.Input, Value = p1, OracleDbType = OracleDbType.Varchar2, Size = p1.Length }; OracleParameter param2 = new OracleParameter() { ParameterName = "param2", Direction = ParameterDirection.Input, Value = p2, OracleDbType = OracleDbType.Decimal }; OracleParameter param3 = new OracleParameter() { ParameterName = "param3", Direction = ParameterDirection.Input, Value = p3, OracleDbType = OracleDbType.Varchar2, Size = p3.Length }; OracleParameter param4 = new OracleParameter() { ParameterName = "param4", Direction = ParameterDirection.Output, OracleDbType = OracleDbType.Decimal }; OracleParameter param5 = new OracleParameter() { ParameterName = "param5", Direction = ParameterDirection.Output, OracleDbType = OracleDbType.Decimal}; OracleParameter param6 = new OracleParameter() { ParameterName = "param6", Direction = ParameterDirection.Output, OracleDbType = OracleDbType.Decimal }; OracleParameter param7 = new OracleParameter() { ParameterName = "param7", Direction = ParameterDirection.Output, OracleDbType = OracleDbType.Varchar2, Size = 32767 }; command.Parameters.Add(param1); command.Parameters.Add(param2); command.Parameters.Add(param3); command.Parameters.Add(param4); command.Parameters.Add(param5); command.Parameters.Add(param6); command.Parameters.Add(param7); command.ExecuteNonQuery(); Any ideas what I'm doing wrong?

    Read the article

  • Multi-base conversion - using all combinations for URL shortener

    - by Guffa
    I am making an URL shortener, and I am struggling with the optimal way of encoding a number (id) into a character string. I am using the characters 0-9,A-Z,a-z so it will basically be a base-62 encoding. That is pretty basic, but it doesn't make use of all possible codes. The codes that it would produce would be: 0, 1, ... y, z, 10, 11, ... zy, zz, 100, 101, ... Notice that the codes 00 to 0z is not used, the same for 000 to 0zz, and so on. I would like to use all the codes, like this: 0, 1, ... y, z, 00, 01, ... zy, zz, 000, 001, ... It would be some combination of base-62 and base-63, with different bases depending on the position... Using base-62 is easy, for example: create procedure tiny_GetCode @UrlId int as set nocount on declare @Code varchar(10) set @Code = '' while (@UrlId > 0 or len(@Code) = 0) begin set @Code = substring('0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz', @UrlId % 62 + 1, 1) + @Code set @UrlId = @UrlId / 62 end select @Code But I haven't yet managed to make a multi-base conversion out of it, to make use of all the codes.

    Read the article

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