Software Development Network Logo
  • Game Technologies
  • IE Development
  • SQL Server
  • VS Team System
  • Visual C#
  • Windows Forms
  • Smart Devicet
  • Windows Vista
  • .NET Development
  • Visual C++
  • Visual Studio
  • Visual FoxPro
  • Audio and Video
  • Microsoft ISV
  • SharePoint Products

Software Development Network >> Prashant_Rai's Q&A profile

Prashant_Rai

Member List

PatOvens
scripteaze
eskimosound
R3dD0g
Keith Hill
newVBuser
Sqnyy
dron747
ttfo
Bakerboy60
Peteraap
Ryan F
Misbah Ahmad
goPlayer
Anand Raman - MSFT
Troy Lundin
Blackwood
Marc Jones
shyamkumar
DamsDev2007
Only Title

Prashant_Rai's Q&A profile

  • Visual Basic Line separation

    I would like to write a file's content to a textbox which is multilined. I loaded the file but I don't know how to write lineseparator. Try Dim sr As StreamReader = New StreamReader("D:\\a.txt") Dim line As String TextBox1.Text = "" Do line = sr.ReadLine() If (line IsNot Nothing) Then TextBox1.Text = TextBox1.Text & "\n" & line End If Loop Until line Is Nothing sr.Close() Catch Err As Exception Console.WriteLine("The file could not be read:") Console.WriteLine(Err.Message) End Try It wrote xyz\nxyz. It would be good if it write:xyz xyz Thank you in advance. Adam If I'm not mistaken then Dim sr As StreamRe ...Show All

  • Game Technologies: DirectX, XNA, XACT, etc. 360 Dev do's and don'ts

    Hi, My primary platform at the moment is Windows, but I want to ensure I don't code anything that is going to cause alot of pain when I eventually get around to subscribing to the creators club and deploying to the 360. I've read a couple of articles on GC and other performance related stuff, but I wondered if anyone has any advice generally on what to avoid or if there are preferences in how ceratin things are coded (e.g. there are many types of storage, is one better than another for XNA specifically) that will mean the transition to 360 is as smooth as possible. Any thoughts or comments welcome! Cheers :) Ska Software wrote: I did; it turns the game into a slideshow :) I'm not sure why it's gotte ...Show All

  • Windows Forms populate DataGridView from Stored Procedure

    I am using this code to populate to datagridview but nothing is happening and when I try DataBind() at the end it throws an error (dataGridView does not contain a definition for DataBind) sql_connection = new SqlConnection ( "Data Source=.\\SQLEXPRESS;initial catalog=ws2connect;integrated security=true" ); sql_command = new SqlCommand ( "sp_get_customers" , sql_connection); sql_command.CommandType = CommandType .StoredProcedure; sql_command.Parameters.Add( "@id_number" , SqlDbType .VarChar).Value = "%731%" ; sql_connection.Open(); sql_reader = sql_command.ExecuteReader( CommandBehavior .CloseConnection); dataResult.DataSource = sql_reader; You can not direc ...Show All

  • Windows Forms Create Trace in my application

    Hi to all, i like to create a application, that will allow user to trace through out code runtime like f11, i will use reflection to open the methods in the user dll. how create a trace in a new window...... please help me........... is it possible, any ideas, i like to do that application in c#. Yes for example, i working on some method it through exception, i want to provide a trace button it will allow user to debug the code and find which will cause this error. thanks Amjath ...Show All

  • Visual Studio 2008 (Pre-release) Dynamic creation of LINQ

    Hi guys, I finally had the chance to try out LINQ and think it's a very cool tool. I have already finished one of my projects using LINQ for XML. Now I am working on another project and am using LINQ for SQL. Is there a way you can dynamically create the DLinq object I asked so because the object I'm creating will be used against 2 projects (with two different databases). And possibly a third and fourth database later on. To get a better view of my problem, here is what I'm trying to do: I want to create a library that will return an object. This object can be a list, xml, or whatever the calling application wants. For now, the types would be list, xml and dataset (and most of our internal applications will use xml). The value/data insid ...Show All

  • Visual Basic Sending unicode characters to an application

    (This thread was "moved" to this forum) Hi, I'm creating an application that detects the pressed keystrokes and sends other characters in their place. Just like a key mapper. I'm using a keyboard hook to detect the keystrokes (the one from here , if you need to know) and and then send other keys to applications system-wide. My only problem is that I need to send non-latin characters, cyrillic characters to be more precise (in my case), and I have realized that I'm not able to simulate this the way I'm doing so far. I have researched a lot and the only thing I found was that I may have to use SendInput instead, or Windows Messages to send a WM_CHAR or something like that. My main objective is to be able ...Show All

  • Software Development for Windows Vista Problem with Rules and comparisons on nullable types

    I'm building an application (using .NET 3.0 RC1) where I want to allow my customers to create simple Rules to do a consistency check on amounts on an invoice. They might create a condition like this.totalAmount > 500 to flag invoices that total more than $500.00. This works OK. But they also need to be able to check whether the total amount is more than the total amount of the last invoice, which would be a condition like this.totalAmount > this.previous.totalAmount where I set previous to be a reference to the previous invoice. This also works OK, except for one case. At times there won't be a previous invoice (for example, the oldest invoice in the database won't have a previous invoice.) Of course, we could add a ...Show All

  • Visual Studio 2008 (Pre-release) Bubbling an Event from WPF to Winform

    Hello All, I have a WPF canvas which is hosted in an ElementHost (I am using this WPF canvas in a .NET 2.0 application using System.Windows.Forms.Integration). I want to bubble the occurence of the MouseDown/MouseMove/Drag/Drop events of the WPF canvas to its superbase control which is basically a C# .NET 2.0 class (which is hosting the ElementHost). This superbase control is winform user control that inherits from System.Windows.Forms.UserControl. So the hierarchy is WPF Canvas is the Child of ElementHost which is added to superbase control (using this.Controls.Add(ElementHost)). Firstly, can I bubble up the event from WPFCanvas to the winform based superbase user control If yes, How will I handle the change in eventargs declaration ...Show All

  • Visual C++ getting all existing windows login names in my computer by VC++ programming.

    Hi all. I want to get all existing windows login names in my computer by VC++ programming. :) Purusothaman A Try NetUserEnum, with the filter parameter set to FILTER_NORMAL_ACCOUNT. See http://msdn2.microsoft.com/en-us/library/aa370652.aspx . Also note that there are places better suited for SDK questions ( http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=980773&SiteID=1 ). ...Show All

  • .NET Development Concat String

    hi I am Try to contact string from Xml data and set to a variable but i can't i use a contact fuction and foreach to concat and set variable . i want use variable in out of foreach but variable value is not ACCEPTABLE plz help me InnerText property does the trick. http://msdn.microsoft.com/library/default.asp url=/library/en-us/cpref/html/frlrfsystemxmlxmlnodeclasstopic.asp ...Show All

  • Game Technologies: DirectX, XNA, XACT, etc. How do you handle exceptions?

    I took my free-look camera project to work to show my colleagues and when I tried to run it I get an InvalidCallException in my Program.cs on game.Run(); I don't have a 3D card in my work machine but other projects I've created on it have worked fine so I started a new project and copied the game components across and ran it.\ Now I get the same expection when I call DrawUserPrimitives, can anyone tell me what might be happening And how are you supposed to handle exceptions either in Game Components (which you might not have built) or in code OK, I use graphics.GraphicsDevice.GraphicsDeviceCapabilities.PixelShaderVersion and graphics.GraphicsDevice.GraphicsDeviceCapabilities.VertexShaderVersion to check for compatibility on my work ...Show All

  • Windows Forms Datagrid Cell Keypress

    VS 2005 windows unbound datagridview I want to ensure that only numeric values are entered into a datagridview cell. Is there anywhere to put a keypress event in a cell The Regex is a way, maybe not good enough here. hehe The link does provide some information. There are lots of events out when you move from cell to cell: cell leave(old cell) cell validating/ed (old cell) cell endedit (old cell) cell enter(new cell) cell beginedit(new cell) So it's a great ease for users to validate their input data. ...Show All

  • Visual Studio Team System Merge Error - TF14085

    When we try to do a baseless merge we get the following error TF14085: Cannot merge $/Path1/Branch1 to $/Path2/Branch2 because there is an incompatible pending change (not edit or encoding) at $/Path2/Branch2$/Path2/Branch2 already. Why do we get this error Is there something wrong with Braching Thanks, Srikanth Obvious question first: are there any pending changes in Branch2 Undo them before trying to merge. There are a few cases that can lead to TF14085 being thrown for trickier reasons, but they shouldn't be possible during baseless merge. Post the exact command if you can, along with any relevant history. ...Show All

  • Software Development for Windows Vista Automatically discovered printers raise multiple JobAdded events

    Howdy, I'm a little new to interoping, so I need a little help. I have a WaitCallback method that raises an event whenever a job has been added to the print queue on the local machine (generally a print server). The primary purpose is to pause all incoming jobs so they can be properly logged, and then released afterwards. The jobs are stored in a queue in a separate SQL database. This is all well and good when a user adds a printer through the "Add Printer..." dialog. However, whenever UPnP discovers a printer and automatically adds it, the jobs sent through that device raise multiple JobAdded events. As an example, let's say we have a Xerox Document Centre 432 on the print server \\beast . If I share this printer on a ...Show All

  • .NET Development Cannot add signed assembly in GAC ??

    Hi, I've got a problem with enterprise library assemblies. I signed and installed them in the GAC. It works for me and some computers of the team. On 2 others computers, I try to register using gacutil -i and I get the following error message : "Failure when adding assembly to GAC : the module should contain an assembly manifest" Any idea Thanks, What is the dependency graph of your enterprise library that you are trying to install into the GAC Is it a multi-module assembly What other assemblies does it depend on Is there a publisher policy for this assembly or any of its dependencies If you run ILDASM on the assembly that you are trying to install into the GAC, it sounds like the & ...Show All

©2008 Software Development Network