-
- Should a C# beginner focus on WPF and Silverlight?
by tvance929
- 7 Replies
- Last post
by Dmitry Pavlov
- Hey guys,
I am a wannabe programmer. I am reading as many books and tutorials as possible - (with very limited time - full time job, online college, kids, wife, etc. etc.) such as Programming C#, c# and sql, c# and asp, and AJAX.
I want to get INTO the programming industry. I am in IT but not programming. I WANT to be a .NET programmer and not a Java programmer.
It seems that
-
- debuging multi thread application problem
by ashk1860
- 14 Replies
- Last post
by ashk1860
- hi
I have a windows application which have much intraction with the webservices. so I use backgroundworkers to make connection with webservices. I mostly handle DoWork and RunWorkerCompleted events to get the data in one and set in the other. and application is in debuging step now.
Just assume that the user loose the connection to internet when a backgroundworker is trying to connect to the
-
- A question about C# use COM object.
by CLR_cn
- 3 Replies
- Last post
by Mattias Sjogren
- //Code
IntPtr comObjPtr; SomeWinapiFunction(out comObjPtr); // Get a com object ptr. IUnknown obj = (IUnknown)Marshal.GetTypedObjectForIUnknown;(comObjPtr, typeof(IUnknown));
//use obj.
Marshal.ReleaseComObject(obj);
My question is , do I need to call "Marshal.Release(comObjPtr)" I think "Marshal.ReleaseComObject(obj)" can release the COM object, so I do not have t
-
- Choice of Collection
by Azurewrath
- 11 Replies
- Last post
by Azurewrath
- Hi all,
I need a collection to hold hundreds of directory paths, which should be sorted. Say I know the number of the directories from the start. Is it better to use SortedList or an Array
If I didn¡¯t know the number of the directories, then I would be using SortedList, right
But SortedList sorts the list everytime you add an element, right So wouldn¡¯t it be better to add
-
- Project Designer - Which Settings Per-User? Which Per-Configuration?
by John Saunders
- 9 Replies
- Last post
by Stephen Weatherford MS
- This a pair of dumb questions, but they're dumb questions I should have asked back in the .NET 1.0 days.
Which settings in the Project Designer are kept on a per-user basis as opposed to being kept in the solution
Which settings in the Project Designer are kept on a per-configuration basis, as opposed to staying the same as the configuration changes
I haven't been able to fi
-
- jagged arrays 2
by Brett445
- 6 Replies
- Last post
by IsshouFuuraibou
- Sorry for making a new thread. The site wasn't letting me resond to the old thread for some reason.
When making a two dim array for use in numerical algorithms in C++, it's very useful to do it this way...
int rows=3; cols=4; double **matrix;
matrix = new double* [rows]; matrix[0] = new double[rows*cols];
for(int r=1; r<rows; r++) matrix[r] = &(matrix[0][r*cols]);
This is a p
-
- How to create a custom toolbox in c#.net?
by lavanya
- 2 Replies
- Last post
by lavanya
- Hi
I have to create a custom toolbox with controls loaded from an xml file dynamically. Please let me know how to add create the same and add the required events for drag and drop of items.
Thanks
Lavanya.S
-
- .net 2.0 windows service installer
by arkiboys
- 1 Replies
- Last post
by TaylorMichaelL
- In .net 1.1 there was a hyperlink for Add Installer to install windows service. This option seems to be missing in .net 2.0 Am I right How do you install the windows service in .net 2.0 please Thanks
-
- How to use data structure containing object arrays?
by jrykowski
- 4 Replies
- Last post
by jrykowski
- (Warning: I'm new to C# syntax! And a bit fuzzy on concepts of class, array, and object array)...
I'm trying to develop a windows client that uses a webservice. The webservices has some fairly complex data structures - including object arrays.
I've got the webservice reference in place, and it's created the class structures and everything....
Code Snippet
public pa
-
- How to use c # to write shrinking algorithm?
by walking fish
- 14 Replies
- Last post
by walking fish
- Algorithm use c # language is described shrinking
Can write the code example
thanks
-
- Problem with if and else statements within a For Looop. Error CS0201
by don06van
- 8 Replies
- Last post
by micvos
- Hi I've been developing a Queue for customers. The user can enter the customer's information into text inputs and add them to the queue, the user can also remove customers from the queue which is where im having problems. I've created array's for all my customers informations and then when they "add to queue" i add it to the datagrid table I have created in the form.
anyways for
-
- need some help with registering a dll during install
by smwoodward
- 1 Replies
- Last post
by TilakGopi
- Hey guys, i'm a little new to program, so please bear with me. My project is needing a dll registered to operate correctly. if i type regsvr32 and the dll at the run prompt, my program will work fine. I need to know how to register this dll inside the installation .msi. I have the dll being added to the programs folder, i just need help registering it. Thanks guys
-
- Refactor - Encapsulate field
by Infinite Entropy
- 5 Replies
- Last post
by Anson Horton MSFT
- When I use refactor - encapsulate field I get the preparing files dialog and then it scans all the files in the project. It never used to do this and it now takes so long that there is no point in using encapsulate field as it is quicker to type it. On colleagues pc it works immediately without the scan, we are on the same spec pc. Have I changed a config setting somewhere Any help would be appre
-
- how to add a common delegate function for all the events of control?
by bruce.du
- 1 Replies
- Last post
by bruce.du
- hello,everyone:
Now I must add a delegate function dynamically for a event of control by the event name. for example,
I want to add the delegate function for the keyup event and MouseDown event of a button control.
Code Snippet
public partial class Window1 : System.Windows.Window {
..................
void test(object s, KeyEventArgs e) { Message
-
- Sending/picking up file for conversion
by dgorsman
- 1 Replies
- Last post
by OmegaMan
- Ok, heres the set-up:
I have a console application running on another computer, monitoring a specific network "input" folder. When certain types of files are sent to that folder, the console app fires up a licenced application to convert the file to another type. The converted file is placed in an "output" folder and the original file is erased. All fine and well.
-
- set font heigth in pixels
by Dirk Reske
- 2 Replies
- Last post
by Matthew Watson
- Hello,
I want to draw a string using Graphics.DrawString()
How can I set the Font height in pixels
I have to fill a control with text lines, and the lines should fit the control.
If I use new (Font fontFamily, float size, GraphicsUnit.Pixel) its get to large.
thanks for help!
Dirk
-
- An exeception occurred while trying to update the smart data tasks, they will be disabled.
by stig brembo 1
- 3 Replies
- Last post
by stig brembo 1
- Hi, I've taken over an windows application in VS2005 C#.
One of the forms keep raising an error while reading the code or [design]. An ordinary error message from the IDE, with the red and white error cross. The error message beening:
An exeception occurred while trying to update the smart data tasks, they will be disabled.
Data at the root level is invalid. Line 1, position 1.
Som
-
- InvalidOperationException
by Sniper167
- 14 Replies
- Last post
by sirjis
- I got an Exception on this line: " whois.Lookup(listBox1.SelectedItem.ToString());" and I don't know what to do...
System.InvalidOperationException was unhandled Message="Cross-thread operation not valid: Control 'listBox1' accessed from a thread other than the thread it was created on."
So I tried this:
private void setListBoxSelectedItem( Strin
-
- Removing items in a list while iterating through it
by J Andrews
- 14 Replies
- Last post
by jgalley
- In this code, I get a SystemInvalidOperation execution and I know why. List<int> list = new List<int>(); for (int i = 1; i < 10; i++) { list.Add(i); } foreach (int i in list) { list.Remove(i); } I replaced the foreach with for: List<int> list = new List<int>(); for (int i = 1; i < 10; i++) { list.Add(i); } for (int i = 0; i < list.Count; i++) { int remove = list ;
-
- Looking for a C# code sample. Urgent
by Haikun Zhang
- 5 Replies
- Last post
by vtortola
- Hi All,
I am looking for a C# code sample. I have ever got it but lost. The sample illustrates a editor that the user can place some shape like rectangle, circle on the document, and you can move and resize the shapes using mouse. Is there anybody remember the sample name It's urgent. Thanks in advance.
-
- detect application at launch
by vb2005
- 4 Replies
- Last post
by vb2005
- Is there an alternative process to detect when an application is launched and close it (in .net 2.0)
Currently I am looking into
FindWindow then GetWindowThreadProcessId then OpenProcess and then TrminateProcess
Thanks
-
- Clipboard.GetImage() returns null on large images
by swemaniac
- 2 Replies
- Last post
by swemaniac
- I've been using the clipboard to retrieve images for a while, works fine. But now I tried copying a large JPEG image from my browser (around 3meg) and suddenly the clipboard.getimage() or clipboard.getdata(dataformats.bitmap) returns null! i can still retrieve smaller images. what's going on here Thanks Johan
-
- Not keyword in C#
by Azurewrath
- 10 Replies
- Last post
by Azurewrath
- Hi all, I am wondering if not keyword is in C# For those who don't know what it does, it is the verbal form of ! But the advantages over ! are: 1. not is way easier to see than !. Because ! is very slim, and hard to notice. 2. not is color coded like false, and that makes it easy to spot. 3. ! is generally not seperated from what comes after, with a space, so you have to do it yourself. Thanks,
-
- Cannot Convert type 'char' to System.DateTime'
by HarryBedi
- 14 Replies
- Last post
by ShellShock
- Hi guys I keep getting the following error when I try to iterate through an array
foreach (DateTime TimeStamp in theTickData[0]) //Cannot Convert type 'char' to System.DateTime'
{
if (TimeStamp >= dtEntryTime)
{
foreach ( string PG in theTickData)
{
if (PG == theDirection)
{
foreach ( double theRate in theTickData[1])
{
alEntryPointEURCHF.Add(theR
-
- READ USB PORT
by Anish MM
- 1 Replies
- Last post
by Karthikeya Pavan Kumar .B
- HI
any one know that read/write usb port
regards
anish mm