Posts
 
Reputation
Joined
Last Seen
Ranked #1K
Strength to Increase Rep
+5
Strength to Decrease Rep
-1
100% Quality Score
Upvotes Received
3
Posts with Upvotes
3
Upvoting Members
3
Downvotes Received
0
Posts with Downvotes
0
Downvoting Members
0
1 Commented Post
~24.5K People Reached
Favorite Tags
Member Avatar for sachintha81

I have a simple USB barcode reader which I intend to use to scan COD 39 barcodes. I know that just scanning the barcode while having a text field on focus will get me the text input of the barcode I'm scanning. However my requirement is a bit different. I …

Member Avatar for welkhanson
0
4K
Member Avatar for sachintha81

In my C++ Win32 program I want to set the current Display Settings to "Extend" mode. I Googled and found out that SetDisplayConfig() is the way to go forward in Windows 7 (I'm on Windows 7) but now I am kind of stuck how to proceed as the MSDN explanation …

Member Avatar for sriv
0
2K
Member Avatar for sachintha81

I referenced Acrobat.dll in a simple C# Console program, and then wrote a couple of lines of codes to run Acrobat. CAcroApp mApp = new AcroAppClass(); Console.WriteLine("Acrobat is running"); bool bClose = mApp.CloseAllDocs(); bool bExit = mApp.Exit(); However, while CloseAllDocs() return true, Exit() always return false. And accordingly I can …

0
137
Member Avatar for sachintha81

I am trying to extract all the images in a PDF and then convert them into DIB format using an Acrobat plugin. First part is easy. I extract all the contents in the PDF, then iterate through them and whenever I find a PDEImage, I put them in an array. …

Member Avatar for sachintha81
0
591
Member Avatar for sachintha81

Let me describe my problem as well as I can. I have a C# application program, let's call it App.exe. It references a DLL named A.dll which in turn references another DLL, namely, B.dll. However the way in which they are referenced is a bit different. In the code of …

Member Avatar for sachintha81
0
3K
Member Avatar for sachintha81

Can someone please tell me what is the event that is triggered when a user clicks on the + sign in C# TreeView? To elaborate more, here is my problem. I have a tree view that is populated at the time of Form_Load. Then the user can expand/collapse/select etc with …

Member Avatar for jerry32uk
0
821
Member Avatar for sachintha81

Let me first describe my situation. I have a list of Hex values, which are called BaseID. They are chosen [B]such that logical OR between any number of them will give you a unique ID[/B] which is called FinalID. That is, my BaseID values are as follows. BaseID = { …

Member Avatar for sachintha81
0
194
Member Avatar for sachintha81

I have a WPF C# program where I attempt to delete certain characters from a text box at TextChanged event. Say, for instance, the dollar sign. Here is the code I use. [CODE] private void txtData_TextChanged(object sender, TextChangedEventArgs e) { string data = txtData.Text; foreach( char c in txtData.Text.ToCharArray() ) …

Member Avatar for Momerath
0
1K
Member Avatar for sachintha81

I have done pretty much all my programming using C# and very much a newbie to C++. However now I have to convert to C++ and is finding it a bit difficult. For example, I wrote a pretty simple program using C# to acquire a RegistryKey, then using a recursive …

Member Avatar for drkybelk
0
368
Member Avatar for sachintha81

Hi All I'm wondering if there is a way to know, using a C# program, among my COM ports which are connected to BlueTooth devices? For example, let us assume that of my ports 1 through 9, the COM ports 7 and 8 are connected to some type of BlueTooth …

0
113
Member Avatar for sachintha81

I want to add a custom configuration section to my App.Config file in my C# 2010 project. I want the section to look like the following. [CODE]<DmModules> <Module Name="Module1"> <add key="DbType" value="..."> <add key="ConnType" value="..."> </Module> <Module Name="Module2"> <add key="DbType" value="..."> <add key="ConnType" value="..."> </Module> </DmModules>[/CODE] Of course there can …

Member Avatar for sachintha81
0
313
Member Avatar for sachintha81

I have a very simple WCF program where I have a simple self-host and a client running on the same computer. There is a single method which returns a System.IO.Stream, which is actually a serialized form of a simple string. (This could be any number of data types, but for …

0
105
Member Avatar for sachintha81

I'm using .NET 3.5 with VS 2005 C#. I created a simple application where when I select the time zone from a combo box, it displays the current time of that time zone. To do this I simply use the GetSystemTimeZones() method of TimeZoneInfo class, and then populate the combo …

Member Avatar for darkagn
0
1K
Member Avatar for davieJohnson

I am working on a C# Windows Form project and I need to access the controls on a form from a separate class within the project. can anyone help me with this?

Member Avatar for Mitja Bonca
0
156
Member Avatar for sachintha81

I have a WindowsService named, say, BST. And I need to give a non-Administrator user, UserA, the permissions to Start/Stop this particular service. My service runs on a variety of Windows OS, starting from Windows Server 2003 to Windows 7. How can I do this? I Googled and found some …

Member Avatar for sachintha81
0
2K
Member Avatar for sachintha81

I have a simple ASP.NET page where after the initial page load the user enters a username and a password to two text boxes. Note that I can not use the built-in login control in ASP.NET, as my purpose of using this username and password is slightly different. Now, I …

Member Avatar for vuyiswamb
0
235
Member Avatar for sachintha81

I was looking for a way to Start / Stop Windows Services residing in a remote machine using C# code, and found the following code sample. It works fine for me. It is coded using Impersonation Technique, which apparently requires both the machines (let's say A and B) have a …

0
107
Member Avatar for adiiz

[B]I have this XML code and I want to print value of UserName and Email on console.Can you help me??[/B] [CODE]<?xml version="1.0"?> <USERS> <User> <UserName>abc</UserName> <Email>abc@gmail.com</Email> </User> <User> <UserName>abc</UserName> <Email>abc@gmail.com</Email> </User> <User> <UserName>abc</UserName> <Email>abc@gmail.com</Email> </User> <User> <UserName>abc</UserName> <Email>abc@gmail.com</Email> </User> </USERS>[/CODE]

Member Avatar for Diamonddrake
0
346
Member Avatar for ChaosKnight11

Hi there, I have started working on a new C# app which will be installed directly onto our customers' computers to access our services remotely. I'm still in the phase of planning how everything will fit together. I normally use PostgreSQL for our back-end database needs, but I can't think …

Member Avatar for sachintha81
0
194
Member Avatar for divyakrishnan

Hi.. I want export data from database to a PDF using c#.In database I stored the data as 'nvarchar'.Any body have any idea About this? Thanks in advance.

Member Avatar for sachintha81
0
99
Member Avatar for sachintha81

First some background on what I'm working on. I have a particular service (Windows only) running on my computer, which is built using C#. Other than Control Panel > Management Tools > Services, I can also use C# programming to Start/Stop/Restart the said service. I use ServiceController class in System.ServiceProcess …

Member Avatar for sachintha81
0
212
Member Avatar for balrogf

how do i transfer the contents of a string array to an int array in relation to my code below: string[] sample= { "J♦", "3♦", "4♥", "Q♦", "9♥" }; convert(sample) [CODE] void sample(string[] straight) int[] straight2 = new int[straight.Length]; for (int i = 0; i < straight.Length; i++) { if …

Member Avatar for balrogf
0
236
Member Avatar for sjn21682

hi everyone, im having trouble with my code here, please help me. i have a button edit and my code is Cmd2.CommandText = "UPDATE Project SET FILE = " + "'" + MyTable2.Rows[j]["FILE"].ToString() + "', " + "DATE = " + "'" + Convert.ToDateTime(MyTable2.Rows[j]["DATET"].ToString()) + "' " "WHERE ID = …

Member Avatar for sachintha81
0
148
Member Avatar for BuhRock

How would I go about converting a string to an integer? Say someone enters a 4 digit string. Like 1234. Could I use the place of each digit and work with it? Pretty much, I wanna get 1 from the string "1234" and put it in a variable. Then get …

Member Avatar for coil
0
175
Member Avatar for Xeros606

I usually make enumerations separate from classes, but when my CS teacher was teaching us about enums, he put it inside the class, and when it came time to set a variable of the enum outside of the class, he told us to just pass a string to the class …

Member Avatar for ddanbe
0
174
Member Avatar for sachintha81

I am a bit (well, actually a lot) confused with how exactly I should use the Dispose() method on SqlConnection object in C#. First let me tell you what I have learned so far (I've been reading a LOT on the subject for the past 24 hours, and I'm still …

Member Avatar for Momerath
0
1K
Member Avatar for sachintha81

This isn't exactly a problem with C# coding rules, rather I need help with logic. Here's my situation. In my program, I deal with a JobID. Say, a print job, and there is a unique (obviously) JobID assigned to each print job. Now, regarding each job there are MANY files …

Member Avatar for nick.crane
0
194
Member Avatar for sachintha81

All the registered IIS MIME types in IIS 7 + Windows Vista are registered in the following config file.  [CODE]C:\Windows\System32\inetsrv\config\applicationHost.config[/CODE] I was wondering where I can find the same file in Windows XP when I have IIS 6 installed? Additionally, in Vista if I add a MIME type MANUALLY, it …

Member Avatar for sachintha81
0
288
Member Avatar for sachintha81

I'm trying to set a MIME type for a certain file extension (.jdf) using MimeMapClass in C#. Following is the code I use which works fine. [code] // directory is a virtual directory, say BSS // extension = ".jdf" // type = "text/xml" private static void SetMIMEType(DirectoryEntry directory, string extension, …

0
88
Member Avatar for sachintha81

The following registry key contains many system default folder locations. HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders The value for the path of the All Users desktop, which is found there, is as follows: XP or earlier : %ALLUSERSPROFILE%\Desktop Vista or later: %PUBLIC%\Desktop Whereas the actual paths of the All User desktops, respectively, are …

Member Avatar for sachintha81
0
331