Search Results

Search found 11972 results on 479 pages for 'writing'.

Page 129/479 | < Previous Page | 125 126 127 128 129 130 131 132 133 134 135 136  | Next Page >

  • Progress Bar not updating

    - by Bailz
    I have the following piece of code to write data to an XML file. private void WriteResidentData() { int count = 1; status = "Writing XML files"; foreach (Site site in sites) { try { //Create the XML file StreamWriter writer = new StreamWriter(path + "\\sites\\" + site.title + ".xml"); writer.WriteLine("<?xml version=\"1.0\" encoding=\"ISO-8859-1\" ?>"); writer.WriteLine("<customer_list>"); foreach (Resident res in site.GetCustomers()) { bw.ReportProgress((count / customers) * 100); writer.WriteLine("\t<customer>"); writer.WriteLine("\t\t<customer_reference>" + res.reference + "</customer_reference>"); writer.WriteLine("\t\t<customer_name>" + res.name + "</customer_name>"); writer.WriteLine("\t\t<customer_address>" + res.address + "</customer_address>"); writer.WriteLine("\t\t<payment_method>" + res.method + "</payment_method>"); writer.WriteLine("\t\t<payment_cycle>" + res.cycle + "</payment_cycle>"); writer.WriteLine("\t\t<registered>" + CheckWebStatus(res.reference) + "</registered>"); writer.WriteLine("\t</customer>"); count++; } writer.WriteLine("</customer_list>"); writer.Close(); } catch (Exception ex) { lastException = ex; } } } It's using the same BackgroundWorker that gets the data from the database. My progress bar properly displays the progress whilst it is reading from the database. However, after zeroing the progress bar for the XML writing it simply sits at 0 even though the process is completing correctly. Can anyone suggest why?

    Read the article

  • insert BibTeX article *here*, not at the end of the article

    - by vy32
    I've seen this before, but I just can't find it. I am writing a resume and want to include the articles from my bibtex file. If I write \cite{FOO} then they all appear at the end. I know that there is some way to say \something{FOO} and the FOO reference appears here. Basically, I want this section of my CV to look like: \something{FOO1} \something{FOO2} What is the \something? Thanks.

    Read the article

  • Proper Commit Messages

    - by wowus
    What are commit messages for? I've always been writing them as an explanation of what I did, but I've recently gotten into a discussion about it with a colleague who writes commit messages explaining why he did. Which one is right, or is there another answer entirely?

    Read the article

  • Windows forms designer renaming copy/pasted controls

    - by Ready Cent
    I saw a similar question asked and answered for ASP.net here http://stackoverflow.com/questions/484327/how-do-i-prevent-visual-studio-from-renaming-my-controls But I am trying to prevent this while writing a Windows forms app in VS 2008 using c#. I want to copy/paste a ton of controls without them being called Checkbox1 etc. I'd rather rename them manually since its only a small change to the name.

    Read the article

  • Migrating From SQL Server Server 7 To 2005, What should I get excited about?

    - by Jon P
    The company I work for has decided to join the 21st century and upgrade our main database cluster from SQL Server 7 to SQL Server 2005. As a web developer what new whiz-bang features of SQL Server 2005 should I get excited about or get to know? Currently I'm mainly writing CRUD style queries, pretty much exclusively using Stored Procdures for a mixed ASP.net and Classic ASP environment.

    Read the article

  • Implementing SSL tunnel in C#

    - by RaYell
    As a part of a larger application I need to implement an SSL tunnel in C#. I was wondering if there's a better way of doing that instead of writing each step of SSL negotiation myself which sounds like reinventing the wheel. Do you know if there are any libraries that I could use to minimize the code I need to write or any tutorials which show how this or similar thing can be implemented most efficiently in .NET?

    Read the article

  • OpenCV videos across platform

    - by Gurman Gill
    I am writing a video using OpenCV on linux machine. I want to read the same video using OpenCV on a windows machine. I am not able to do this using the standard codecs provided in openCV. Can anybody suggest how I can read/write videos across the two platforms?

    Read the article

  • Unable to cast lists with Reflection in C#

    - by DrLazer
    I am having a lot of trouble with Reflection in C# at the moment. The app I am writing allows the user to modify the attributes of certain objects using a config file. I want to be able to save the object model (users project) to XML. The function below is called in the middle of a foreach loop, looping through a list of objects that contain all the other objects in the project within them. The idea is, that it works recursively to translate the object model into XML. Dont worry about the call to "Unreal" that just modifes the name of the objects slightly if they contain certain words. private void ReflectToXML(object anObject, XmlElement parentElement) { Type aType = anObject.GetType(); XmlElement anXmlElement = m_xml.CreateElement(Unreal(aType.Name)); parentElement.AppendChild(anXmlElement); PropertyInfo[] pinfos = aType.GetProperties(); //loop through this objects public attributes foreach (PropertyInfo aInfo in pinfos) { //if the attribute is a list Type propertyType = aInfo.PropertyType; if ((propertyType.IsGenericType)&&(propertyType.GetGenericTypeDefinition() == typeof(List<>))) { List<object> listObjects = (aInfo.GetValue(anObject,null) as List<object>); foreach (object aListObject in listObjects) { ReflectToXML(aListObject, anXmlElement); } } //attribute is not a list else anXmlElement.SetAttribute(aInfo.Name, ""); } } If an object attributes are just strings then it should be writing them out as string attributes in the XML. If an objects attributes are lists, then it should recursively call "ReflectToXML" passing itself in as a parameter, thereby creating the nested structure I require that nicely reflect the object model in memory. The problem I have is with the line List<object> listObjects = (aInfo.GetValue(anObject,null) as List<object>); The cast doesn't work and it just returns null. While debugging I changed the line to object temp = aInfo.GetValue(anObject,null); slapped a breakpoint on it to see what "GetValue" was returning. It returns a "Generic list of objects" Surely I should be able to cast that? The annoying thing is that temp becomes a generic list of objects but because i declared temp as a singular object, I can't loop through it because it has no Enumerator. How can I loop through a list of objects when I only have it as a propertyInfo of a class? I know at this point I will only be saving a list of empty strings out anyway, but thats fine. I would be happy to see the structure save out for now. Thanks in advance

    Read the article

  • Writting Rails project documentation

    - by potapuff
    Hi to all. Give me an example, that's you can describe as "well documented project on Rails", or "best practices of making documentation for Rails project" (with link to github, or other same site, if it possible). And, what tool's you prefer to use for writing documentation of your project?

    Read the article

  • audio processing in iPhone

    - by Janaka
    I am writing an iPhone application to apply filters to audio input and output the result in real time. I am new to audio processing but using audiounit, the correct approach? I found out how to output data using audiounit but couldn’t figure out how to capture input audio. Is there a sample application showing how to connect input and output using audiounit?

    Read the article

  • Background color for Tk in Python

    - by olofom
    I'm writing a slideshow program with Tkinter, but I don't know how to change the background color to black instead of the standard light gray. How can this be done? import os, sys import Tkinter import Image, ImageTk import time root = Tkinter.Tk() w, h = root.winfo_screenwidth(), root.winfo_screenheight() root.overrideredirect(1) root.geometry("%dx%d+0+0" % (w, h)) root.focus_set() root.bind("<Escape>", lambda e: e.widget.quit()) image = Image.open(image_path+f) tkpi = ImageTk.PhotoImage(image) label_image = Tkinter.Label(root, image=tkpi) label_image.place(x=0,y=0,width=w,height=h) root.mainloop(0)

    Read the article

  • How can I make Strawberry Perl's cpan(1) find perl?

    - by WalterVonBruegemon
    I'm having trouble installing Template module with Strawberry Perl. cpan Template yields the following: Writing Makefile for AppConfig C:strawberryperlbinperl.exe: not found dmake.EXE: Error code 255, while making 'blib\lib\.exists'` I haven't been able to understand either how to affect the path so dmake will work correctly why the path (which is correct) does not have any \ in it.

    Read the article

  • Is there such a tool for testing

    - by kjack
    Say one has a structural codebase where lots of the code is in GUI control events and has no tests. So such code, to my knowledge is not suitable for unit testing Is there a tool that can test each routine automatically replacing references to code elements external to the routine (be they functions, variables or GUI controls) with appropriate mocks(?) and record the results in a database for later comparison after code changes? So the testing program would have the duty of writing, running and reporting tests with minimal intervention?

    Read the article

  • learn dbms online

    - by siva
    Hi I want to learn DBMS including the concepts of complex SQL writing and normalisation and other stuff. Can anyone please help me to find some useful online resources.....

    Read the article

  • Security in programmming?

    - by yesraaj
    What is the best book to read about security issues that should be kept in mind while programming? What should a c++ programmer know about security? Is it worth buying any one of the following book If so which one should I get. Secure Coding In C & C++ Secure Programming Cookbook for C and C++ Writing Secure code

    Read the article

  • Sleep Command in T-SQL?

    - by skb
    Is there to way write a T-SQL command to just make it sleep for a period of time? I am writing a web service asynchronously and I want to be able to run some tests to see if the asynchronous pattern is really going to make it more scalable. In order to "mock" an external service that is slow, I want to be able to call a SQL server with a script that runs slowly, but isn't actually processing a ton of stuff.

    Read the article

  • Is there a good blogging platform to use as a framework?

    - by itsadok
    I'm writing a new product, and I've noticed that a lot of the features I want already exist in blogging platforms like wordpress. For example, comments and comment moderation, content editing, etc. Is there a good blogging system that is easy to use as a foundation for something else? Something with an API, extremely customizable, and hopefully something that works well with Java.

    Read the article

  • how to get ip address from sock structure in c ?

    - by REALFREE
    I'm writing simple server/client and trying to get client ip address and save it on server side to decide which client should get into critical section. I googled it several times but couldn't find proper way to get ip address from sock structure. I believe this is a way to get ip from sock struct after server accept request from client more specifically in c after server execute csock = accept(ssock, (struct sockaddr *)&client_addr, &clen) Thanks

    Read the article

  • X64 installer using Won64 node registry

    - by rajeshaz09
    I am using InstallShield 2008 premium edition. I created one basicMSI project only to target x64 platforms. I changed summary property to "x64". But this installer is writing registry entries in "HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\CompanyName\ProductName" . I am using both installshield script and vc++ DLL for custom actions. Why x64 installer is using WOW64 registry ?

    Read the article

< Previous Page | 125 126 127 128 129 130 131 132 133 134 135 136  | Next Page >