c#,silverlight,windows-phone-7Related issues-Collection of common programming errors


  • user3085540
    c# mysql asp.net mysql-error-1064
    I got the following error while calling a stored procedure in asp.net c#page. I could not understand the error details. Please help me to solve this.MySqlCommand cmd =new MySqlCommand(“CALL sp_wrt_test(10, @param);SELECT @param”, connection);cmd.CommandTimeout = 5000000;//Assign the query using CommandType7 using (IDataReader reader = cmd.ExecuteReader()) {if (reader.Read())id = “@param = ” + reader[0]; }create procedure sp_wrt_test(in name varchar(100), out retval varchar(200)) begininsert into

  • Abi Ruban
    c# sql
    I am getting an error when trying to connect to SQL Database through C#:SqlConnection sqlc = new SqlConnection(“Server=sql09.freemysql.net,3306;Database=rekklamirajmee;Uid=trubilord;Pwd=******;”); sqlc.Open()When connecting through HeidiSQL, everything works, with the following settings:Advanced on default.I’ve been trying to fix it, have been Google-ing for over an hour but I cannot seem to fix it ;

  • remudada
    c# mysql
    This code is placed in the button. and when i click it to update the data, a messagebox error appears saying “fatal error encountered during command execution”. Your answers would be a great help. Thank youMySqlConnection connection = new MySqlConnection(MyConnectionString);MySqlCommand cmd;try{connection.Open();cmd = connection.CreateCommand();cmd.CommandText = “UPDATE student_offense SET TYPE=@TYPE,DATE_HAPPENED=@DH,DESCRIPTION=@DESC,SANCTION=@SANC” + “Where STUDENT_NO = @STUDENT_NO And DESCRI

  • user1033278
    c#
    How can I execute some code when my program experiences a fatal error and crashes? For example, something goes wrong and the box pops up that say “TestApp.exe has encountered an error and needs to close.” and then I want to write to a file with an error code and say a report of the last few things that were entered into the program. How would I do this in C#??

  • Sharpeye500
    c# asp.net mysql
    MySql.Data.MySqlClient.MySqlException:Fatal error encountered during commandexecution. —>MySql.Data.MySqlClient.MySqlException:Timeout expired. The timeout periodelapsed prior to completion of theoperation or the server is notresponding. atMySql.Data.MySqlClient.MySqlDataReader.NextResult()atMySql.Data.MySqlClient.MySqlCommand.ExecuteReader(CommandBehaviorbehavior) — End of inner exceptionstack traceWhat does this error mean? I have max connection pool =200 in the connection string? my app i

  • JM.
    c# windows-services
    I created a windows service and installer that watches a collection of files for changes and copies any file that changes to a destination directory specified in the WatchlistConfig.xml file. I have a couple issues with the service: 1. It has stopped running on one occasion. (unacceptable) 2. We sometimes have to attempt to start the service several times before it “takes”.I believe issue #1 is probably due to not handling fatal errors in the application. I found a bit of code that I tried to

  • samaxI92
    c# .net obfuscation
    The class below causing –fatal error– after obfuscating with confuser(v1.9.0.0); I’m thinking its for bad/unsafe coding. I’m a beginner programmer. So it would be great if some-one point and describe the bad part(if exists) of my code. My IDE is VS-2010. Thanks. public class Check_COMgsm {public Exception ex;public List<string> ModemName;public List<string> ModemPort;public Check_COMgsm(){this.ex = null;this.ModemName = new List<string>();this.ModemPort = new List<string&g

  • C Sharper
    c# asp.net nhibernate mapping
    i have an error ( System.InvalidCastException: Unable to cast object of type ‘AccountProxy’ to type ‘System.String’.) when i did this codei mapped the tables( Account,AccountString,EventData,…) of the the database opengts ( open source) i have this error when i called a function from EventData.csIQuery query = session.CreateQuery(“FROM Eventdata”);IList pets = query.List();return pets;the Stack Trace:[InvalidCastException: Impossible d’effectuer un cast d’un objet de type ‘AccountProxy’ en typ

  • Clark Kent
    c# winforms web-browser clr fatal-error
    Possible Duplicate:Troubleshooting .NET “Fatal Execution Engine Error” My code is throwing a Fatal Execution Error. The exact error is this:The runtime has encountered a fatal error. The address of the errorwas at 0xed40646c, on thread 0x2044. The error code is 0xc0000005.This error may be a bug in the CLR or in the unsafe or non-verifiableportions of user code. Common sources of this bug include usermarshaling errors for COM-interop or PInvoke, which may corrupt thestack.I’m not using unsafe u

  • Darren Young
    c# minidump
    I want to write a utility that in the event of a fatal error, a minidump dmp file is created. I’m using the clrdump api and that seems fairly straightforward.What I wanted to know is, what should I be reading up on to determine how to trigger an event when there is a fatal error that allows for this minidump to be created.I will be writing it in C#.Thanks.

  • Shawn
    silverlight exception fatal-error
    Receiving this error when trying to build a Silverlight 4 project.The code generator’Microsoft.ServiceModel.DomainServices.Tools.CSharpCodeDomClientCodeGenerator’encountered a fatal exception and could not generate code for project’TheProject.csproj’: Exception has been thrown by the target of aninvocation.

  • Drazisil
    c# silverlight asynchronous world-of-warcraft
    I have been stuck on this all weekend and failed miserably! Please help me to claw back my sanity!!Your challengeFor my first Silverlight application I thought it would be fun to use the World of Warcraft armoury to list the characters in my guild. This involves making an asyncronous from Silverlight (duh!) to the WoW armoury which is XML based. SIMPLE EH?Take a look at this link and open the source. You’ll see what I mean: http://eu.wowarmory.com/guild-info.xml?r=Eonar&n=Gifted and Talen

  • lukas
    c# c++ silverlight html5 windows-phone-7
    I recently decided to go into WP7 app development, but haven’t actually started learning silverlight/xna; Only C#. I already know C++ quite well.my Dad, who works for Microsoft, has recently told me that there’s no point to learning Silverlight because it will become irrelevant in the long run; due to HTML5’s superiority. However, Im not aware of any way to develop apps for WP7 using HTML5, and I barely know anything about markup languagez anyway.I wanted to get some proffesional advice on this,

  • Mmerrell
    c# silverlight
    Currently i’m tracking down a memory leak issue in a Silverlight 4 application. I can watch the memory used by iexplorer.exe increase gradually using Task Manager. However, I am looking for a way within the Silverlight code to tell how much memory the application is currently using within the IE Process. I have tried GC.GetTotalMemory but it does not represent the actual memory usage by iexplorer. I have developer tools for tracking down the memory leak itself, so i’m not looking for that but

  • Mud
    java silverlight flash printing hardware
    I need direct-to-printer functionality for my website, with the ability to distinguish a physical printer from a virtual printer (file).Coupons.com has this functionality via a native binary which must be installed by the user. I’d prefer to avoid that.SmartSource.com does it via Java applet:Does anybody know how this is done? I dug through that Java APIs a bit, and don’t see anything that would let you determine physical vs virtual, except looking at the name (that seems prone to misidentificat

  • ForbesLindesay
    c# silverlight visual-studio-2010 silverlight-4.0 mediaelement
    I want to write a method like the one bellow. However, in the event that Silverlight is unable to play the stream natively, I would like it to go through a list of MediaStreamSource classes, and try each one in turn till either one of them works, or it has no more to try. My question is, how do I tell whether the method below is sufficient for a particular stream.public static void OpenMedia(this MediaElement ME, Stream FileData) {ME.SetSource(FileData); }I need some code to execute in the ev

  • user2056563
    c# silverlight pdf windows-phone-8 windows-phone
    I have few pdf in a folder say Data/PDF/abc.pdf.I am trying to open PDF with the below code:private async void LaunchPDFNew(string name){string imageFile = @”Data/PDF/”+name+”.pdf”;// Get the image file from the package’s image directoryvar file = await Windows.ApplicationModel.Package.Current.InstalledLocation.GetFileAsync(imageFile);if (file != null){bool success = await Windows.System.Launcher.LaunchFileAsync(file, options);if (success){// File launchedDebug.WriteLine(“File Launched”);}else{/

  • Adam Cobb
    silverlight printing telerik reporting
    I am trying to trigger a Telerik report to print once it has been rendered using either the native Silverlight printing ability or the integration with Adobe Acrobat.In my searches I have found this forum post – http://www.telerik.com/community/forums/reporting/telerik-reporting/reporting-parameters-first-time-not-applied-when-usenativeprinting-false.aspxWhich seems to describe how to do it, but when I try this approach, using the ReportServiceClient RenderAndCacheCompleted event, I get a Securi

  • spoof3r
    java silverlight networking dns applet
    I’m trying to create a Silverlight application that gathers network information, similar to that of running the command ‘ipconfig /all’ from the command line. I simply want to display the client’s IP address, default gateway, and the DNS server(s). If the DNS server is pointed to their router, then I need a way to get the DNS server being used by the router. Any suggestions? I’ve looked a little into WMI but with no success. Silverlight is simply too compressed.I have not done a lot in Java, but

  • AnthonyWJones
    silverlight printing xps
    Is there any way (library or native) to use the printing API to print an XPS document? I tried using the Document Toolkit API which works up to a point, but I get a COM exception when I try to set PrintPageEventArgs.PageVisual.

  • xbonez
    android ios windows-phone-7 phonegap sencha
    I need to develop applications for a company on some major mobile OSes, specifically, iOS, Android and WP7.I was initially planning to code three separate applications for the three different OSes – each using the native SDK.However, is there any advantage to doing so? There are a number of cross-platform tools available – Sencha, Phonegap, Rhodes etc. How ‘native’ do the apps created by them feel across devices? What kind of hardware integration do they have (camera, GPS, local storage etc.) ?I

  • that_guy
    windows-phone-7 advertising
    Problem: I am trying to integrate adds into a already successful deployed app. HOWEVER no matter what I do, I cannot seem to get the ads working! I have tried using both the code version AND the drag n’ drop gui version. NEITHER of which I can get to work. This is what I see: When it starts up it may flash for a split second white, where the ad is supposed to be, but none the less, no adds. It recognizes that it is where I place it, when I place it over a button, the button becomes unclickable.

  • lukas
    c# c++ silverlight html5 windows-phone-7
    I recently decided to go into WP7 app development, but haven’t actually started learning silverlight/xna; Only C#. I already know C++ quite well.my Dad, who works for Microsoft, has recently told me that there’s no point to learning Silverlight because it will become irrelevant in the long run; due to HTML5’s superiority. However, Im not aware of any way to develop apps for WP7 using HTML5, and I barely know anything about markup languagez anyway.I wanted to get some proffesional advice on this,

  • joe
    windows-phone-7 windows-phone windows-phone-8
    My Windows Phone app was rejected because when I play a sound in the browser in my app it stops existing background music from playing (rejection issue 6.5.1).How do I update my application to not stop background music?My JavaScript is something like this:var mySound = new Audio(soundpath);Sound.play(mySound);I could not find anything in Microsoft.Xna.Framework.Media that handles how the app handles browser sound, but maybe I missed something?

  • Alexandr
    windows-phone-7 windows-phone-8
    I want to close my app if network not available.I check network in App.cs:private void Application_Launching(object sender, LaunchingEventArgs e){if (!NetworkInterface.GetIsNetworkAvailable()){//close my app}else{//continue to work}}Is there a better way to do it?Thanks in advance.

  • aronchick
    c# windows-phone-7
    Sadly, this question is not for me, so I don’t have all the exact details – but as a follower of Windows Phone and C#, this individual seems to be hard core about getting his point across that Windows Phone will fail because it does not offer native C/C++.Windows Phone Apps Biggest Stumbling BlockI suppose other than the portability, this does not seem to be a particularly difficult problem – 500k items in memory (even if each word is 10 characters) means it’s 5 MB of total memory, and would be

  • Milan Aggarwal
    windows-phone-7 windows-phone-7.1 windows-phone
    Possible Duplicate:Launching other applications in Windows phone 7 Programatically I have created an application in which I download Images/Files and other docs from web for my application but I need them to open using their default file launchers like pdf should be opened via adobe pdf viewer. Currently I have acheived this using external web browser using webbrowsertask. I want it to happen within the app using webclient or webbrowser control. I tried these two methods, they worked correctly

  • Arterius
    windows-phone-7
    I’ve made an app which content is in Armenian language and not natively supported in the Windows Phone OS. The app is a blog reader which read RSS feed for posts and shows that posts in the mobile app. Posts in blog is only in Armenian and there is no translated version to English or any other language. The neutral language for assembly is set to English. The app long description for marketplace is in English and also I clearly mentioned what content of app is in Armenian language. But app certi

  • Praetorian
    windows-phone-7
    I just tried submitting my app to AppHub for the first time and I keep getting a submission failure. This is the error:Error code: 1044 The XAP uses one or more restricted native APIs.I found this post describing the same error but he says his problem was solved by adding the /NOENTRY linker option to his resource-only DLL (used for application name localization). I already have that option set in my localization DLL, yet the submission fails.Has anyone come across this, and hopefully found a so

  • ?????? ??????
    windows-phone-7
    The second time refused to certify the application.Comments: The application’s long description and/or UI content is presented in Ukrainian not natively supported in the OS. For an application to be presented in a language not natively supported in the OS, its description must satisfy the following requirements: 1. A statement to indicate the application is not in the targeted language. 2. A full description text in the targeted language. 3. A full description text in the language supported by

Web site is in building