all groups > c# > may 2007 > threads for thursday may 10
Filter by Day: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Please give me a moment - How Employable am I?
Posted by GeekDrool at 5/10/2007 9:32:53 PM
I hope there are some team leaders/managers (or insightful grunts) out
there that can give this post a little time, as this topic is a heavy
weight on me.
I owned a software company for about 6 years. I sold it about 5 years
ago, did almost nothing for about 2 years, and have been employed as... more >>
Problem with ASP .NET
Posted by Dave at 5/10/2007 7:48:01 PM
I created an application in Expression Web. I have now opened that
application in VS 2005. However, when I try to attach an event to to a
control, the code defaults to VB. How can I change it to C#?
--
L. A. Jones... more >>
Another noob question
Posted by azz131 at 5/10/2007 6:17:33 PM
Hi, i want to access an array of objects inside a method like this
using System;
using System.Collections.Generic;
namespace ObjectArray
{
class MainClass{
class MyClass
{
public int x=0;
MyClassTo[] obj=new MyClassTo[2];
public MyClass(){
obj[0]=new MyClassTo();
... more >>
Q: Child list for field x cannot be created.
Posted by Martin Arvidsson, Visual Systems AB at 5/10/2007 5:40:54 PM
Hi!
Have a little problem when i want to use the other dataset with the same
grid.
When i display the form i use the UniqueFolders. All works fine, then click
a button
and send InitializeGrid with FileDeletion as parameter and the exception is
raised. (See subject)
What to do? Do i h... more >>
IEnumerator
Posted by EmilH at 5/10/2007 4:25:48 PM
Hi.
I have read some examples of IEnumerator at
http://www.codeproject.com/csharp/csenumerators.asp
What if I have 2 arrays or collections, for example a DataSet which has 2
DataTables in my class which derives from IEnumerator? How to implement
Current property to return current item of t... more >>
DHTML Edit Control and umlauts
Posted by afislage NO[at]SPAM web.de at 5/10/2007 4:14:22 PM
Hello,
now let's pose the question in english.
I use the DHTML Edit Control with C#.
The editor creates html-code like the following:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN">
<html><head>
<meta http-equiv="Content-Type" content="text/html;
charset=windows-1252">
<meta htt... more >>
Graphics to TextRenderer
Posted by Nathan Laff at 5/10/2007 4:11:43 PM
I have a custom label, that as the width changes, the height will change to
fit all the text in the label...
I use to do this like this...
int newHeight = (int)Math.Ceiling(g.MeasureString(this.Text,
this.Font, this.Width - this.Padding.Left,
StringFormat.GenericDefault).Heig... more >>
Saving DataGridView
Posted by Mel at 5/10/2007 4:02:08 PM
I would like to the save the column order of DataGridView.
Thanks
Mel
... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
Reading text file problem
Posted by Tim Kelley at 5/10/2007 3:50:34 PM
I am using a streamreader to read a one line text file. The line looks like
this:
"99999","04/30/2007","XXXXXXXX","XXXXX, XX","XX",""
When the line is read in I get this: i
"\"99999\",\"04/30/2007\",\"XXXXXXXXXX\",\"XXXXXX, XX\",\"XX\",\"\""
I don't get where all the \ are coming from... more >>
Using .Net 2.0 components in .Net 1.1?
Posted by Ethan Strauss at 5/10/2007 3:40:46 PM
Hi,
I need to convert a big .Net 1.1 solution to .Net 2.0. There is a LOT of
code here and I do not want to do the conversion all in one go. I would like
to be able convert individual projects from the solution to 2.0 and then
reference them from the 1.1 solution, but when I try to add a ... more >>
XML Delete
Posted by Colin Williams at 5/10/2007 3:27:35 PM
I have just started working with XML , and am sure this is easy but
drawing blanks on this one!
e.g
<Files>
<File>C:\File1.txt</File>
<File>C:\File2.txt</File>
<File>C:\File3.txt</File>
</Files>
How do i remove the element <File>C:\File2.txt</File>
Thanks
Colin Williams
... more >>
Search and Index files...
Posted by PL at 5/10/2007 2:46:00 PM
I'm looking for a tool or library (that can be used with C#) that would allow
me to index many HTML files and to perform a search on this index. I'm
looking for something that could be used on a desktop application (not like
most of the Search-Index engine (dtSearch, Dieselpoint, etc. that req... more >>
Re: Trouble with ShowDialog
Posted by Brian Schwartz at 5/10/2007 2:40:14 PM
Oops. Pressed the wrong key.
You would instantiate your form like this:
frmUserName f = new frmUserName (username);
Alternatively, you could make the username a public property of the form.
This would allow you to read it later, after the form is done. And/or you
could implement both ... more >>
Trouble with ShowDialog
Posted by Dom at 5/10/2007 2:29:52 PM
I have a Main form called frmMain which appears when the program
starts, and a second form called frmUserName. frmMain has a button,
btnUserName. When you click it, I have this code:
frmUserName f = new frmUserName ();
f.ShowDialog(this);
For the next line, I expected to find f.txtUserNam... more >>
Multithread writes to a Rich Text Box
Posted by Ray Mitchell at 5/10/2007 2:25:03 PM
Hello,
Sorry for the long-winded dissertation - but, I have an application where I
need to write text to a rich text box using a common method, callable from
anywhere in my application. The color of the text will depend upon the first
argument and the text will be contained in the second a... more >>
DllImport win32 and out string buffer parameters
Posted by Zytan at 5/10/2007 2:24:06 PM
When using DllImport to import win32 functions that have strings, I
know you can use the native c# string type. But, what about a
function that expects a string buffer, and writes to it? I've seen
people use StringBuilder for this, but is string good enough?
The problem is that I am seeing w... more >>
where to call savetoxml to run on object destruction
Posted by deciacco at 5/10/2007 2:21:53 PM
I'm using an object that has a dataset within it.
When the object is instantiated I populate the dataset from xml files.
I want the object to save the dataset back to the xml file before it is
destroyed, but I'm not sure when to call this routine. Should I call it
from the object's destructor ... more >>
Q: Overide OnPaint in textBox
Posted by Martin Arvidsson, Visual Systems AB at 5/10/2007 2:13:20 PM
Hi!
I have a textBox on a windows form.
Can i overide the textbox OnPaint directly in the form, if so how.
Or do i have to inherit the textbox control and overide it there?
Regards
Martin
... more >>
Programmatically setting SqlServer vs. Windows authentication
Posted by michael sorens at 5/10/2007 2:11:03 PM
I am wondering how to programmatically select either SqlServer or Windows
authentication when connecting to a database. Is this something in the
connection string? Or is it some other parameter to a connection method...?... more >>
Save several DataTables of DataSet
Posted by Joe Kovac at 5/10/2007 2:05:02 PM
Hi!
I change quite a lot TableRows in several Tables of a typed DataSet. Now
I would like to know which is the best way to save all the rows.
Currently I just use each TableAdapters Update() method.
First, I think I should have some kind of transactions.
Secondly, I think I should use GetC... more >>
How to validate XMLDocument (not XMLReader) against a DTD?
Posted by engwar at 5/10/2007 1:56:37 PM
The title says it all. How do I use XMLDocument.Validate() against a
DTD.
In all my Googling about this I only find examples of how to validate
an XMLReader or XmlValidatingReader against a DTD.
The reason I want to avoid the readers is that I want an XmlDocument
that is not forward-only so... more >>
Reading keyboard key presses on WinForm
Posted by JDeats at 5/10/2007 1:54:00 PM
I have a WinForm with a single command button in the middle, I have
added a KeyDown event handler to the form and the method for this is:
private void Form2_KeyDown(object sender, KeyEventArgs e)
{
MessageBox.Show(e.KeyCode.ToString());
}
When I run the prog... more >>
Problem with creating classes as runtime - PLEASE HELP
Posted by julia_beresford NO[at]SPAM hotmail.com at 5/10/2007 1:42:20 PM
Hi
I need to create the following class at runtime:
public class MyCollection : CollectionBase
{
public void Add(MyItem item)
{
List.Add(item);
}
public MyItem this[int index]
{
get
{
return (MyItem)List[index];
}
}
}
(the type MyType will also... more >>
Creating a preference window
Posted by melon at 5/10/2007 1:36:57 PM
Let's say, I have a form class...
public class MainForm : Form {
private CustomClass cc;
public MainForm() {
DoSomething()
InitializeComponent();
}
/// Do something more
public void ShowPreference() {
PreferenceForm pf = new PreferenceForm();
pf.sometextbox.te... more >>
static & instance variables
Posted by Jordan Marr at 5/10/2007 12:22:40 PM
I have the following class:
class ProvisionCollection
{
...
private int m_VarianceCount;
public int VarianceCount
{
get { return m_VarianceCount; }
}
public static ProvisionCollection GetProvisions(...)
{
ProvisionCollection list = new ProvisionColle... more >>
Is it possible to remove "click" sound that occurs when WebBrowser control text changes?
Posted by JDeats at 5/10/2007 12:18:32 PM
Using VS.NET 2005, if you place a WinForms WebBrowser control on a
form, then place a command button on that form and in the "click" even
handler for the command you do:
webBrowser1.DocumentText = "";
On every mouse click you were hear a "click" sound identical to the
sound Internet Explore... more >>
fundamental scope question
Posted by David at 5/10/2007 12:14:42 PM
I feel like an idiot asking this but here goes: I understand the 'concept'
of scope and passing data by value and/or by reference but I am confused on
some specifics.
class example{
int i; //my global var
private void method1(int myInt){
int x; //local var
etc...... more >>
Compile Questions
Posted by OldButStillLearning at 5/10/2007 12:07:02 PM
I am trying to teach myself how to compile my application at the command line
with the csc.exe. I found a good article which steps you through the
process, but I have some questions, which I hope someone can elighten me
on....
1. In VS2005, I found an article about how VS2005 is using a n... more >>
Should I use TransactionScope?
Posted by hardieca NO[at]SPAM hotmail.com at 5/10/2007 11:25:50 AM
Hi,
I'd really like to use TransactionScope within the Business Layer of
my web application. A book I'm reading makes a note that it should not
be used in a shared web hosting environment because the server may get
re-configured. Can anyone elaborate on this?
Regards,
Chris
... more >>
Process.MainWindowHandle = 0 for hidden windows, solution?
Posted by Zytan at 5/10/2007 11:20:17 AM
I could use win32's FindWindowEx, but I need to know the window's
title bar text, or the window's class name that was registered with
win32's RegisterClass (does anyone know what that would be?).
Is there a C# solution using Process? Seems ugly to use win32
functions.
Zytan
... more >>
Question on a COM project.
Posted by Amit at 5/10/2007 11:00:26 AM
Hello group,
I will appreciate it if you give me some advice on my question:
I am asked to write a program. This program is supposed to act as
"Adobe PDF" feature which some of you either have it or see it in your
office products such as Word, Excel and ... It must get attached to
Exc... more >>
sending PCL printer cmds from csharp
Posted by David at 5/10/2007 10:55:03 AM
We have a c# application that sends documents directly to the printer using
PrinterSettings() and PrintDocument(). These functions do much of the printer
and document configuration work needed, but it looks like we are going to
need to use a PCL printer command to initiate Short-Edge Binding. ... more >>
Leading 0s in an up/down control
Posted by Ray Mitchell at 5/10/2007 9:34:03 AM
I have a numeric up/down control with it's Hexadecimal property set to true.
I would like to use it to represent 32-bit hex values and would like it to
always display all 8 digits even if they're 0s. Is there a reasonable way
to do this? Thanks!... more >>
Outlook object
Posted by Mike P at 5/10/2007 9:13:41 AM
I am using the Outlook.MailItem object to extract fields such as
ReceivedBy, SenderName and Subject from emails, but it seems like there
is no way to get at the actual received by email address and sent by
email address, I can only get at the actual name of the sender and
recipient.
Is ther... more >>
Processes attached to a file (like .dll or .exe)
Posted by luigi.amoroso NO[at]SPAM gmail.com at 5/10/2007 9:10:37 AM
Hi,
Excuse for my English. I need to know which processes are attached to
a file;
for example if I open a txt file with notepad.exe, this process is
attached to this file.
Thanks a lot
Luigi
... more >>
Excel import with x64 machine
Posted by DC at 5/10/2007 9:00:43 AM
Hi,
I easily ported a .Net 2.0 c# app to x64, but there is one major
problem left: the app imports excel data via OleDB, and there are no
Jet drivers and no ODBC divers (other than SQL Server) available for
64 bit apps on the x64 platform.
I have x64, Sql Server (must support 2000 and 2005)... more >>
32 vs 64 bit
Posted by Mark Chambers at 5/10/2007 8:47:31 AM
Hi there,
Given the following in Win32
[DllImport("User32.dll")]
internal static extern Int32 SendMessage(IntPtr hWnd, UInt32 Msg, UInt32
wParam, Int32 lParam);
the return value and last two parameters then become the following in Win64:
[DllImport("User32.dll")]
internal static exte... more >>
DropDown List Box
Posted by Ruth Mark at 5/10/2007 8:29:01 AM
Hi all,
Is there any chance to let the serverside DropDownList box to execute the
JScript instead of writing the SelectedIndexChanged event.
The reason i initiated this question is. by writing code at
"SelectedIndexChanged Event" you are allowing the page post back and
executing the code... more >>
Threading problem after migration from 2003 to 2005
Posted by Jeroen at 5/10/2007 6:49:53 AM
We converted our decently large (13 projects, compiled about 12 mb)
VStudio 2003/.Net1.1 project to VStudio 2005/.Net2. My two colleagues
have no problem starting the new solution, but I get an exception
thrown at me. I only get the exception if I run in debug mode, in
release mode all works fin... more >>
Cursor is Black?
Posted by gwoodhouse NO[at]SPAM gmail.com at 5/10/2007 6:00:52 AM
Hello,
Im using VS 2005, ive created a cursor file, deleted all the "layers"
appart from 32x32 256 colors and added the image. I saved it and set
it to be embedded as a resource.
I use this line to call it:
this.Cursor = new Cursor(GetType(), "Pencil.cur");
But the cursor is a silloett... more >>
DTD XML String
Posted by Steven Blair at 5/10/2007 5:49:52 AM
Hi,
I am writing an application which communciates with a web service.
The data I need to send to the service is an XML document over HTTPS.
I have been supplied with a DTD file.
My problem is how do I create a structure of some description (DataSet
or some other object) which has all the... more >>
Nhibernate
Posted by IceMan at 5/10/2007 4:56:14 AM
Hi,
I am using the configuration object and passing it a Assembly object
to load. The assembly object i pass in is from a dll which is in a
different folder then the Nhibernate dll.
The AddAssembly(Assembly assembly) function throws me an Error saying
it can't load the configuration hbm.xml f... more >>
Format Number as in ToString("#,###.00")
Posted by Bob at 5/10/2007 3:17:31 AM
Hello Folks,
I am bring backa data reader dr from the database/
So I have a number of fields such as dr["ExtendedPrice"]
To put this in a table I use "<td>" + dr["ExtendedPrice"].ToString()
+ "</td>"
But I want to format the number as mentioned in the subject line.
It won't work.... more >>
noob question
Posted by azz131 at 5/10/2007 2:29:57 AM
Hi, i am trying to access a field in an array of objects but i get this
error "Exception System.NullReferenceException was thrown in debuggee:Object
reference not set to an instance of an object".What am i doing wrong?
using System;
using System.Collections.Generic;
namespace ObjectArra... more >>
transparent button upon an image
Posted by Hans - DiaGraphIT - at 5/10/2007 1:57:01 AM
Hi!
I have a windowsform with an imagebox inside a groupbox. The imagebox shows
a image of a man with joints (for medical purose - shoulder, ancle, wrist
etc.). The user is able to mark the jonts by clicking on the spesific joint.
I solved this by using checkbox (with button-appearance) u... more >>
convert string to integer
Posted by jed NO[at]SPAM auto-soft.co.za at 5/10/2007 1:49:35 AM
in need an example of converting a string to integer
... more >>
derive MouseEventArgs from EventArgs
Posted by Peted at 5/10/2007 12:00:00 AM
Hello
this is the click event method of a radio button
private void radioButton1_Click(object sender, EventArgs e)
{
}
what i want to do is Within this event method check is the left mouse
button has been pressed.
I cant seem to derive MouseEventArgs from this m... more >>
forms looks different on different platform; limited things can change in OS theme
Posted by Ryan Liu at 5/10/2007 12:00:00 AM
Hi,
I have a big urgent problem to solve.
I used to use Windows 2000 Chinese version, now I installed Windows XP
(English) system.
The problem is not about 2000 or XP, it is about English and Chinese.
All forms of my compiled C# desktop application, as well as in Visual Studio
2003(E... more >>
DataAdapter
Posted by EmilH at 5/10/2007 12:00:00 AM
Hi.
Is that a good practice for every table to have its own DataAdapter and
DataSet?
Emil.
... more >>
List Question
Posted by David McCallum at 5/10/2007 12:00:00 AM
Is there a DotNET equivalent to the Java package GlazedLists?
TIA
David McCallum
... more >>
|