all groups > c# > april 2007 > threads for thursday april 5
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
BulkCopy
Posted by Ender at 4/5/2007 11:42:00 PM
For Primary keys exception:
bc.WriteToServer(dt, DataRowState.Added);
(for DataTable)
but what do we write for DataReader?
bc.WriteToServer(dr,?);
Thnks.... more >>
How to use IEquatable?
Posted by Paul E Collins at 4/5/2007 11:30:54 PM
I want to implement the equality operation for one of my classes, so
that I can use List<blah>.Contains for a list of those objects instead
of writing a loop to compare with each item in the list.
When I add ": IEquatable" to my class definition, I get a compile
error:
"Using the generic t... more >>
Event not fired on click of dyanmic dropdownlist in webuser contro
Posted by Padam at 4/5/2007 10:26:01 PM
i have created couple of dynamic controls (dropdownlist and imagebutton) in
webuser controls and assigned selected index change event and image button
clicked. I am giving names to control dyanmically.
My problem is : somtime it does not recognise click event of image button
and selected in... more >>
Converting Java to C#
Posted by Jay at 4/5/2007 9:28:37 PM
I've downloaded some Java files from the internet, and want to use them as a
basis for a C# programme.
They are .jar files, and when I open them in Notepad, they are not text
files.
Is there a way to get some sort of source code from them?
Sorry if this sounds a bit basic, but I've neve... more >>
SQL Server 2005 DAL / Data Dictionary
Posted by jkimbler at 4/5/2007 7:16:11 PM
I'm doing research for a new project I'm going to be developing and
I'm looking for some input on a good DAL (data access layer) object/
framework. I've done quite a bit of searching on-line but you can't
see them all. I'm just wondering what commercial/opensource DAL
engines/objects you might... more >>
Automatically create properties
Posted by barry at 4/5/2007 7:05:37 PM
Is there any way that I can have a piece of code create properties and
give them names for either the same class or a different class.
For example (this problem could be solved with inheritance but its
just to help present my question):
If I have a class called "shape" and I want a seperate ... more >>
developer express, xtragrid, counting (enumerating) rows
Posted by Krzystof at 4/5/2007 6:38:06 PM
hi
developer express xtragrid and treeview
i cannot find how can i enable row numbers (ex on the left side, just
like in excel) to be automatically calculated and displayed, despite sorting
and stuff. i want column something like 1,2,3,4...on the left side.
can someone help me?
thanks
lu... more >>
delaying validation
Posted by PGP at 4/5/2007 5:17:31 PM
Control.Validating event fires when the control loses focus. I find this
behavior not desirable in one of the forms i have. I would rather have the
Validating events fire when the user tries to complete the action (by
pressing the Ok button etc). Any advice is appreciated.
... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
exchange 2003 create draft using webDAV
Posted by Wiebe Tijsma at 4/5/2007 4:45:19 PM
Hi,
I'm using C# + webDAV to create a draft message to be sent in a user's
Drafts folder.
I can create the message successfully, however when I open the message
in outlook, it doesn't show the 'send' button, (only 'reply' etc as if
it was a received message).
I'm using exchange explor... more >>
Remove empty line from string
Posted by LEM at 4/5/2007 4:14:50 PM
Hi,
I'm trying to remove any empty lines from a string, and I am doing the
following:
String pp;
pp = "\r\n\r\n1\r\n23\r\n\r\n4";
pp = pp.Replace("\r\n\r\n", "\r\n");
That works fine if the first line of the string is NOT empty.
How could I remove the first line as well?
Thanks... more >>
CoInitialize in C# ?
Posted by Urs Wigger at 4/5/2007 3:35:26 PM
Hi,
I wanted to instantiate a STA COM component twice, once in the main
thread and once in a secondary thread. All worked fine for the main
thread, but for the secondary thread, I got 'Query Interface failed'
errors when trying to access COM methods.
I once had the same problem in a C++ ap... more >>
RichText in asp.net
Posted by Tomo at 4/5/2007 3:03:10 PM
How to use RichText in ASP.NET application. I need to make web page where
user can write some text, click save and than this content must be saved as
html content. Can I find some richtext control or I need to use javascript?
... more >>
Customizing Items methods in a ComboBox user control
Posted by michael sorens at 4/5/2007 2:48:04 PM
I want to create a customized ComboBox where the methods ComboBox.Items.Add
and ComboBox.Items.Insert will behave thusly:
-- If the item is not present, add it.
-- If the item is present, set the selected index to the item (without
adding a duplicate).
I know the basics of inheriting from u... more >>
Problem catching all exceptions in a windows service
Posted by Simon at 4/5/2007 2:18:54 PM
Hi all,
I'm having a problem creating a global exception handler in a windows
service that I'm making. Another poster suggested that the way to do
this was to use the CurrentDomain.UnhandledException event to catch and
deal with any exception that crops up. The problem is, when I try and
... more >>
Why is this invalid
Posted by Larry Smith at 4/5/2007 1:40:04 PM
IDerived1 derived1 = GetDerived1();
IDerived2 derived2 = GetDerived2();
IBase ibase = (derived1 != null ? derived1 : derived2);
Where "IDerived1" and "IDerived2" each inherit from "IBase". The followinge
error results on the last line:
Error 32 Type of conditional expression cannot be dete... more >>
Multithreading
Posted by victor at 4/5/2007 1:33:15 PM
Hello,
When in my main WinForm thread I do a 'new' instance to a method in
another class, in the same project, does this create a new thread or
not?
Expl:
public class Form1
{
private AnotherClass myInterface;
.....
myInterface = new AnotherClass(this);
....
}
And what if the othe... more >>
Process.start returned value?
Posted by Jason at 4/5/2007 10:48:08 AM
Hello
I've got a Excutable that returns a number of string based upon the number
arguments given to it. I'm using C# to run that exactuable with the
process.start method and in this case 4 argument.... now my question is
that how do I get the returned strings ?
... more >>
WebBrowser problem
Posted by Gaurav at 4/5/2007 10:30:05 AM
I am using the AxSHDocVw.AxWebBrowser control (named PreviewBrowser) in my C#
app to load a pdf file:
PreviewBrowser.Navigate(strPDF ,ref objNull,ref objNull,ref objNull,ref
objNull);
These PDF files are created and stored in a temp folder. The older files
from temp need to be deleted ev... more >>
Wrap command shell in System.Diagnostics.Process
Posted by Jon Davis at 4/5/2007 10:20:27 AM
Does anyone know why using System.Diagnostics.Process to "wrap" a console
application does not always transmit the I/O, depending on what processes
you're trying to "consume"? PowerShell, for example, does not seem to
process any I/O through the Process object.
I know that in the case of Po... more >>
Inter-process communication
Posted by Jon Davis at 4/5/2007 9:50:25 AM
We're looking at running a memory-intensive process for a web site as a
Windows service in isolation of IIS because IIS refuses to consume all of
the available physical RAM. Considering remoting to move data in and out of
this process. Need something that's quick and dirty and easy to implemen... more >>
convert string to binary
Posted by bbdobuddy at 4/5/2007 9:38:01 AM
I am having a problem converting string to binary and I am hoping someone can
help me out
I have a sql query that does an update that updates a binary field calles
password
password=CAST(@password as binary)
However when I go to sql server and convert that binary field to varchar,
al... more >>
convert from string to binary
Posted by bbdobuddy at 4/5/2007 9:34:02 AM
IntelliSense Question.
Posted by Shawn at 4/5/2007 9:08:49 AM
I have been using VB.NET for some time and have recently taken over several
C#.NET apps. My only frustration with it is that IntelliSense does not seem
to work as well with C#. It seems the best way to get it to check for errors
is to re-compile where as for VB it shows errors right away. Am I... more >>
SOAP security negotiation error when using WCF (please help!)
Posted by Ronald S. Cook at 4/5/2007 9:02:37 AM
Hi,
Some users on our domain can run our WCF application no problem. Some get
an unhandled exception error re: SOAP security negotiation. I'm wanting the
service to not be secure.. I just want anyone logged into our company domain
to be able to run the app. Can someone please tell me wha... more >>
AppDomains - App within an App
Posted by coder4 NO[at]SPAM walla.com at 4/5/2007 8:34:46 AM
Within an application, I want to run a second application--with it's
own separate AppDomain.
I'd like to run this second application in a "full-screen
mode" (outside the first application) or inside a panel of the first
application. Is this possible?
Is it possible to add the main form of ... more >>
Windows XP Tips for Computer Security
Posted by snow at 4/5/2007 8:26:56 AM
Windows XP Tips for Computer Security
http://www.163as.com/news/Computer%20Security.html
... more >>
Windows Forms
Posted by shapper at 4/5/2007 7:21:07 AM
Hello,
I usually develop Asp.Net 2.0 (With VB.NET or C#) web sites with SQL
2005 databases.
A few of my web sites use online CMS with AJAX.
I need to create a Windows Vista compatible application that includes
the features I usually have in my CMS:
1. Send a retrieve content from the web... more >>
Iterating over a list and altering it?
Posted by Evan Reynolds at 4/5/2007 7:14:04 AM
I am a C++ programmer and have been learning C#. I have constructed a List<>
and I want to iterate over it, altering each string in the list.
In C++, I'd just create an iterator and walk the list, so I was looking for
something similar in C#. I looked at foreach, List.ForEach, and IEnumerat... more >>
How to disable NetBios in TcpClient
Posted by Erjan at 4/5/2007 6:35:43 AM
Hi,
I am using TcpClient to connect to a device which does not talk
NetBios. The TcpClient tries first to do something with Netbios. This
probably failes on a timeout and then TcpClient sets up the TCP
connection. Due to this it takes about 5 secons to set up a TCP
connection on a LAN.
Is... more >>
How to catch system event of new process that are loaded
Posted by eitangabay NO[at]SPAM gmail.com at 4/5/2007 5:03:54 AM
Hi all .
I want to know when new process has added\loaded, i looked for system
event but i could not find any.
Is there any way to do it ?
I'm writing in c#.NET.
(Process Added meand that new process added to the task manager)
... more >>
Forgot Syntax: calling a parameterized constructor of the same class from a non-parameterized one
Posted by Sathyaish at 4/5/2007 4:35:12 AM
/* I am writing this C# program because I forgot the syntax for
calling a parameterized constructor from a non-parameterized one
within the same class.
I was coding in Java and just typed it like this:
public MyClass(String someParam)
{
}
public MyClass()
{
this.MyClass("Some... more >>
n-tier development
Posted by Mike P at 4/5/2007 4:17:57 AM
I've just started to try to create my own n-tier project, and I am using
an xsd schema to represent all my tables, and then datatables and
queries to get at my data. The question I have is, where does XML and
web services fit in to this? Do any web services go in the data layer,
and can I trea... more >>
how to listen a connection from a specific IP address?
Posted by felix.citycs NO[at]SPAM gmail.com at 4/5/2007 2:44:54 AM
Why I cannot do with this code and exception is thrown with "the
requested address is not valid in its context"
try
{
IPAddress inputDNS_IP = Dns.Resolve(inputDNS_IP).AddressList[0];
// start the data port and listen for connection from input host
this.dataListener = new TcpListener(inputD... more >>
Progress Bar refuses to work?
Posted by gwoodhouse NO[at]SPAM gmail.com at 4/5/2007 2:30:21 AM
Hello all, Ive been trying to get a helpful progress bar at the bottom
of my app to simply fill up and then disapear.
Unfortunatly, i get this error message when i try to change the .Value
field of the progress bar: "A first chance exception of type
'System.InvalidOperationException' occurred ... more >>
Passing COM object from c# to COM causes exception
Posted by aeshiels NO[at]SPAM gmail.com at 4/5/2007 2:07:03 AM
Hopefully I have the correct newsgroup for this question.
I've developed a very simple COM server in C++ as im trying to learn
COM. The COM server has an array of IUnknown interfaces (MyArray)
where im allowing the user to store COM objects (derived from
IUnknown) via get/put properties.
I ... more >>
Reflection ok in 1.1, but not anymore in 2.0
Posted by Fred at 4/5/2007 12:00:00 AM
Hi,
The code below works perfectly with Framework 1.1, but generates a run-time
error with the 2.0.
I use it to extend a PrintPreviewDialog to add my own PrintButton.
using System;
using System.Reflection;
using System.Drawing;
using System.Drawing.Printing;
using System.Windows.Forms;
... more >>
how to reassign a fixed pointer
Posted by Schwammkopf at 4/5/2007 12:00:00 AM
Hi !
What i want to do in C++ is :
int a[] = new a[2];
a[0] = 0, a[1] = 0;
int* p = &a[0];
while (1) // any condition instead of 1
{
(*p)++;
if (p == &a[0])
p = &a[1];
else
p = &a[0];
}
How is this in C# possible ? I googled and found the unsafe / fi... more >>
why doesn't this xpath expression work ?
Posted by Coaster at 4/5/2007 12:00:00 AM
I'm reading a csproj file trying to extract info via xpath and this first
one works fine
xmlNode =
xmlDoc.SelectSingleNode("/def:Project/def:PropertyGroup[1]/def:OutputType/text()",nsMgr);
but this one doesn't and the only change is the key name and that is
present. The xml is pa... more >>
|