all groups > c# > november 2004 > threads for wednesday november 24
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
Outlook Global Address Book
Posted by Peter at 11/24/2004 11:53:20 PM
Does anyone have an example of how to access Global Address Book using
Outlook automation and c#, preferably late binding, but any example will be
appreciated.
Thank You
Peter
... more >>
problem with displaying Unicode strings
Posted by Ziemowit Skowronski at 11/24/2004 11:50:02 PM
Hi,
I have a problem with displaying unicode strings in ASP.NET (C#). I
recieve data from MS SQL Server database and use them to construct
navigation on the page. Because I'm from Poland, I have to display
Polish accent characters and here is a problem. On my testing/developing
server (Window... more >>
Persistance using attributes, reflection and inheritance
Posted by Tilted at 11/24/2004 11:25:10 PM
As I'm not working on many c# projects at the moment I thought I'd spend
some time investigating the subject line.
Getting quite close to a conclusion, it works, it's a little slow (but still
in development), supports 1:1, 1:m, m:m relationships etc.
I've seen several "previews" of ObjectS... more >>
Can You Convert This VB Snippet?
Posted by clintonG at 11/24/2004 10:58:55 PM
This code has to go into the global.asax Application_Start code block.
I'm just not getting this one right and the web-based code converters choke
on it. Can somebody rewrite this VB snippet to C# for me?
Sub Profile_MigrateAnonymous(ByVal sender As Object, ByVal e As
ProfileMigrateEventArgs)
... more >>
How to use the Socket "Connected" property properly?
Posted by Dr. J at 11/24/2004 10:49:42 PM
I have an application that opens a socket and connects to another
application listening over a port. The problem I am encountering is that
when the listening application is closed my application cannot detect it to
take appropriate action. I am using "Connected" property of the Socket
class, b... more >>
Marshalling a char array in a structure from C to .NET
Posted by bettychristopher NO[at]SPAM yahoo.com at 11/24/2004 10:33:53 PM
When marshalling a char array in a structure from C to .NET, I get the
following error:
System.ArgumentException: Type could not be marshaled because the
length of an embedded array instance does not match the declared
length in the layout.
namespace RemoteClientNew
{
[StructLayout(LayoutKi... more >>
Exiting program
Posted by Karl at 11/24/2004 10:03:03 PM
Hi folks,
I have a simple form like this:
public class Blah: System.Windows.Forms.Form{
private OleDBConnection conn;
public class Blah(){
conn.ConnectionString = "... ....";
try{
conn.open();
}
catch(Exception e){
... more >>
ISA Server DestinationSet Performance
Posted by Joris Dobbelsteen at 11/24/2004 9:54:15 PM
Dear,
I've made a little tool that synchronizes my ISA Server block list with a
database. However the performance of this is very low.
I'm retreiving 41140 rows from the database, storing them in a hash table
and clearing the input tables within 1 or 2 seconds.
Getting 41140 rows from the I... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
Relection and private object properties
Posted by Tilted at 11/24/2004 9:27:49 PM
Hi
I have the following scenario...
public class aclass
{
private bclass mbclass
public aclass()
{
bclass = new bclass();
}
}
.... there is more but I cut out the interesting bits. My question is
whether or not by reflection I can in someway modify the value of (for
inst... more >>
System.Console.WriteLine question
Posted by newsgroupie at 11/24/2004 8:45:19 PM
Hi Newsgroupies,
I'm writing a Web Forms program using C# (VS.NET 2003) and trying to
monitor it whilst running using "System.Console.WriteLine(<params>)" but
can't for the life of me find where it outputs too.
Am I thick or just unlucky?
Please help!
Lost & Bewildered, UK
Ps: Bac... more >>
ATcommand in .NET
Posted by smeagol at 11/24/2004 8:19:10 PM
Some xBase languages have a command called AT (remember this?)
In C# this might look like
int retPosition = AT(searchedString, InString);
in xBase
dd = AT("DD", MASK)
It return the position in "dd" searching into "MASK" the "DD" string.
I was looking in the help, but i was ... more >>
cast an object to string array
Posted by toufik at 11/24/2004 7:47:36 PM
Hi,
I'm using a method (from an API) that return an object which is a string
array.
How can I casst it to get a string array?
Thanks.
... more >>
purpose of XmlConvert.ToString() ???
Posted by Chris at 11/24/2004 7:35:48 PM
HI,
what is the purpose of XmlConvert.ToString() ?
why not just use Convert.ToString() ?
e.g.
Int32 vInt32 = -2147483648;
string s1 = XmlConvert.ToString(vInt32);
string s2 = Convert.ToString(vInt32);
s1 and s2 result in the same string.
so what is the added benefit ?
... more >>
Thread Doubt.
Posted by Ram at 11/24/2004 7:30:37 PM
Hi,
I have two threads, one parent thread containing UI and a child thread
waiting for some events from the parent thread. Now, I have two issues: 1)
to keep the child thread active till the end of parent thread. 2) Fire event
from the parent thread to child thread.
To keep the child thre... more >>
XmlTextWriter and quotes ???
Posted by Chris at 11/24/2004 6:49:54 PM
Hi,
I'm trying to specify single-quotes to be used in xmlAttributes as follows :
XmlTextWriter writer = new XmlTextWriter (filename, null);
//Use indenting for readability.
writer.Formatting = Formatting.Indented;
writer.QuoteChar = (char)39;
--> but he still generates doub... more >>
Copying directory contents to another directory with same name?
Posted by VMI at 11/24/2004 6:46:05 PM
How can I copy the contents of a directory without having to 1) create dir,
2)copy files ,etc...?
Thanks.
... more >>
read-only object
Posted by Alex K. at 11/24/2004 5:55:06 PM
My custom control includes DataGrid as one of the constituents. I want to be
able to expose this DataGrid as public property "get":
public DataGrid InternalDataGrid
{
get {return MyDataGrid; }
}
At the same time, I don't want to let user change the grid's properties or
content. In ... more >>
Dissable Label Font Color...
Posted by Chester Ragel at 11/24/2004 5:40:35 PM
Hi,
How can I change the font color of a dissabled label control?
Chester.
... more >>
Static Interface/Abstract/Virtual
Posted by Tamir Khason at 11/24/2004 4:27:37 PM
I have some classes that basicly do the same things but different way.
There are no default constructors in those classes each constructor should
recieve same value
So
Fooclass:MyBasicClass or Fooclass:IBasicClass
and I want to be able to call form program something like this:
MyBasic... more >>
How to de @ a string?
Posted by Russell Wyatt at 11/24/2004 4:05:03 PM
I have a vb class which returns a string to my C# app. I'm finding that if
escape characters are included in the string the C# string becomes a @
string and the escape chars are ignored.
Unfortunately I need the escape characters.
Anyone know of a way I can either avoid this behaviour or to ... more >>
free and used space in a shared computer
Posted by JH at 11/24/2004 3:44:13 PM
How do you get the total free and used space in a computer which I have a
share to specific folders ONLY? (Without using WMI)
Example. computer2 is another computer and I have access to say
computer2\shared folder. But I want to know the total free and used space in
that computer.
Any help ... more >>
Rrun C# Window Application from DOS
Posted by tapaks NO[at]SPAM yahoo.com at 11/24/2004 3:38:06 PM
Hi,
I have a C# window application, and I would like to run this program
from DOS. Does anyone know how to trigger the window application, and
then close the program after it runs?
Thanks... more >>
One form above another
Posted by Tamir Khason at 11/24/2004 3:37:06 PM
Is it possible managed detect that one form inaplicationcontext is above
other ?
--
Tamir Khason
You want dot.NET? Just ask:
"Please, www.dotnet.us "
... more >>
Loading an Assembly from a URL
Posted by Eric Marthinsen at 11/24/2004 2:43:05 PM
Hello-
I'm looking to do something similar to Assebly.Load or
Assembly.LoadFrom, but rather than specify the file name, I want to give it a
URL, so, I could do something like this:
Assembly a = Assembly.LoadFrom("http://mysite/myAssembly.dll");
Does anyone know how to do this, or s... more >>
SpecificCulture
Posted by Thierry at 11/24/2004 2:36:36 PM
Hi all,
I'd like to personalize my Windows app for each of my customers.
Is it possible to create a custom CultureInfo like us-Customer1 and
us-Customer2 ?
Thanks,
Thierry.
... more >>
A good resource editor...
Posted by Sam Martin at 11/24/2004 2:08:59 PM
Hi all,
getting a bit pissed off using Lutz Roeder's external (from VS.NET) resource
editor.
Anyone know any good free ones that add-in to VS?
TIA
Sam
... more >>
How to write to config file
Posted by ALI-R at 11/24/2004 1:57:57 PM
Hi,,
I have two questions :
1) Is it mandatory that config file of a desktop application must be
App.config
2) Is it possible to update config file in your code??
thanks for your help.
ALI
... more >>
string or Stringbuilder??
Posted by ALI-R at 11/24/2004 1:54:10 PM
Shall I use stringbuilder in the following statement? why?
string devInfo =
"<DeviceInfo>" +
"<Toolbar>False</Toolbar>" +
"<MarginLeft>0in</MarginLeft>" +
"<MarginRight>0in</MarginRight>" +
"<MarginTop>0in</MarginTop>" +
"<MarginBottom>0in</MarginBottom>" +
"<Pa... more >>
Closing an opening window
Posted by John Smith at 11/24/2004 1:52:27 PM
I need to:
a) Close a windows form from within the form's code itself
b) It must be able to occur after the form's constructor function is called
(like from another function that's called before .Show())
c) It must be able to occur before the form is actually viewable.
It's for security purpo... more >>
I don't seem to find a solution to this
Posted by B Vidyadhar Joshi at 11/24/2004 1:09:52 PM
After trying out various methods, I couldn't get the below structure to
work. I read on some forum that combining value to type and reference type
in a [StructLayout(LayoutKind.Explicit)] is not valid. And to implement a
union struct, we need to use [StructLayout(LayoutKind.Explicit)]. If I
... more >>
Program version info
Posted by Lee at 11/24/2004 1:05:49 PM
Hi All,
I need to put the program version info into it's about box. How do I get
the various version number (major, minor, rev, etc, etc)
I have tried this (major part only) but am getting a method was expected
error
strversion = "Version:" +
System.Diagnostics.FileVersionInfo.GetVer... more >>
Marshalling Unmanaged DLL
Posted by james.shedden NO[at]SPAM baesystems.com at 11/24/2004 12:37:52 PM
Hi,
I've really flailed at this today, and read many posts and MSDN help
areas. I would really appreciate a sanity check.
The DLL is for OziExplorer API, the function declaration from the
documentation is:
function oziGetExePath(var Path:pansichar;
var DataLenth:in... more >>
list of all possible DateTime formats in culture
Posted by Sakharam Phapale at 11/24/2004 12:26:32 PM
Hi All,
How to get the list of all possible DateTime formats in culture set on
machine?
Thanks in Advance
Sakharam Phapale
... more >>
Work with excel or other ole automation object
Posted by Heriberto at 11/24/2004 12:06:39 PM
Hi,
I'd like to know how to work with excel using C#. I known how to do it in
Delphi but I new in C#. I just want a small exemple. And if anyone knows if
there are diferrence working with excel por pocket pc, let me known. I just
want to put some values and format some cells and columns...
A... more >>
C# C++ Event question
Posted by Andrew S. Giles at 11/24/2004 11:59:07 AM
Does anyone know if it is possible for an Event to be raised/fired in C++ and
then caught/handled in C# and vice versa in a .NET environment? If so, does
the C# and C++ code need to be in the same solution, different solutions,
different threads?
Thanks in advance,
Andrew S. Giles... more >>
ContentType detection without full downloading
Posted by Tamir Khason at 11/24/2004 11:49:13 AM
'm using HttpWebRequest/Response to get content type of urls (a lot of them)
It takes a while, so is it possible to tell to request/response just get a
content type (download only headers) ?
TNX
--
Tamir Khason
You want dot.NET? Just ask:
"Please, www.dotnet.us "
... more >>
Timer question
Posted by Benjamin at 11/24/2004 11:38:49 AM
Hi,
I am having a problem enabling a timer in my class. I have attached some
sample pseudo code (see "Sample code illustrating issue") so you can see
what I am talking about.
Whats the issue?
================
I am unable to pause the timer when a timed event is thrown due to my
event han... more >>
GetNextWindow API in C#
Posted by Tim Mulholland at 11/24/2004 11:33:40 AM
I'm trying to call the GetNextWindow API function via C#.
I've tried two different definitions for it (both are similar), but i always
get the same error:
An unhandled exception of type 'System.EntryPointNotFoundException' occurred
in MsgTestCSharp.exe
Additional information: Unable to find... more >>
Problem using ODBC with MySQL
Posted by Faisal Yaqoob at 11/24/2004 11:19:43 AM
I am using MySQL ODBC driver and System.Data.Odbc package to connect to
database.
I am using OdbcDataReader to read the recordset returned as a result of a
query.
I do check if the column value is null or not before reading it using
OdbcDataReader.IsDBNull(column_index)
This function throws ... more >>
Abstract Base Class Conflicts with the Design View
Posted by Faisal Yaqoob at 11/24/2004 11:10:40 AM
In my application, I have created a base form that contains the common
functions used across all the forms in my application. I want to make some
functions of this class abstract, which makes the whole class abstract. Now,
when other developers derive their classes from this class the .NET IDE
f... more >>
Reflection on my own assmbly
Posted by ALI-R at 11/24/2004 11:06:26 AM
I have defined a public enum in my assembly and I am trying to have access
to it through reflection:
Type theType = Type.GetType("MyAssemblyName.ParameterTypeEnum");
but I get this error:
Object reference not set to an instance of an object.
Why if I put for instance ,"Syste.Reflect... more >>
Regular Expression
Posted by Ryu at 11/24/2004 10:55:42 AM
I would like to create a regular expression that seperates 2 sentences. For
example,
This is a test. Another test.
Is it possible to seperate them into 2 sentences using Regex in .Net?
... more >>
How do you delete an excel column
Posted by GG at 11/24/2004 10:49:57 AM
Have this code but does not delete right columns.
When I ran the folllowing code only columns 14, and 15 is deleted.Col 12
and 13 are still there.
Any ideas?
Thanks
for (int colDel = 12; colDel <= 15; colDel++)
{
columnDelete(ref objSheet,colDel);
}
private void columnDelete(ref Excel... more >>
Inheritance Design Question
Posted by Mike at 11/24/2004 10:37:42 AM
I want to provide an abstract class to derive all nodes from. In the example
below Parent in the base class is of Type Node, but in the custom class I
want Parent to return a Type CustomNode. When CustomNode is accessed by a
helper class as Node Parent is always null. Is this a poor design, Im ... more >>
DirectorySearcher first access speed
Posted by cameron at 11/24/2004 10:36:50 AM
I have always been under the impression that LDAP was optimized for
speed. Fast queries, fast access, slower writes. I have a block of data
in LDAP and in SQL. Exact same data. The query is fast but the first
access to the result set takes longer that to do the query in SQL and
process the s... more >>
Storage of Double variable
Posted by JRB at 11/24/2004 10:22:32 AM
Hi, just curious about how a double value is stored internally. I can go:
byte[] foo = BitConverter.GetBytes(45.78);
foreach(byte b in foo)
Console.WriteLine(b + " ");
I get 8 bytes, which makes sense, since a double is 64 bits, but how is the
number actually stored internally? Is it some ... more >>
How to create a RTF file?
Posted by BVM at 11/24/2004 10:08:18 AM
This is a multi-part message in MIME format.
------=_NextPart_000_0006_01C4D20D.84F9AEA0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Hi,
Do you know how to create a RTF file? Do I have to use a third party =
component?
Thanks,
Dennis... more >>
Writing a generic function to validate values translating to enums
Posted by Claire at 11/24/2004 9:25:13 AM
I have a large record with many enumerated fields.
The record is stored in a file and the fields have to be extracted.
I validate the data as it's read, but there's so many tests similar to the
following that I wondered if it's possible to create a single generic
function to perform the valida... more >>
how to return xml document from a web service
Posted by R.A. at 11/24/2004 9:11:41 AM
Hi,
I have an web service method that accept an xml document and returns a
different xml document.
Based on the input xml I fill a dataset with information from a database.
If the dataset has rows then I need to return those rows to the consumer.
I can't tell if the consumer of the web serv... more >>
Similar To Progress Bar
Posted by bernardpace NO[at]SPAM yahoo.com at 11/24/2004 8:26:57 AM
Hi,
I would like a component that is similar to a progress bar but moves
automatically, ie when it finished it restarts again. Exactly I
require something similar to that bar shown while loading windowsXP.
Does some sort of this component exist.
Thanks... more >>
deploying and using web services at runtime (Again)
Posted by Faraz at 11/24/2004 7:37:36 AM
I would be also interested in knowing if there a way to make a proxy for a
web service at runtime - the web service not existant when execution starts
-. Let me explain.
My executable starts running and while processing it does something that in
turn deploys a web service on a server runni... more >>
disabling
Posted by bernardpace NO[at]SPAM yahoo.com at 11/24/2004 6:22:23 AM
Hi,
I have a program, that connects to a webservice to retrieve data.
While it is connected and retrieving data, and I click on some
component like a text box or button, the window freezes till the
connection to the webservice terminates.
Upon connection, I was to disable every component... more >>
Port Scanner of remote computer in C#
Posted by IceColdFire at 11/24/2004 5:55:03 AM
Hi,
I need to build a port scanner ,able to scan a remote computer ports....
Kindly help
ciao.
AA... more >>
problem with DataBase
Posted by liranby NO[at]SPAM hotmail.com at 11/24/2004 2:45:25 AM
hi
Hi
I have a problem with a dataset. Im trying to update the database but
it doesn't updating the database
this.oleDbConnection1 .Open ();
OleDbCommand cmd = new OleDbCommand ("",this.oleDbConnection1);
cmd.CommandText = "UPDATE Manufactor SET ,factor_Size="
+company.manufacto... more >>
Navigation of a DataGrid help needed
Posted by Stephen at 11/24/2004 2:13:04 AM
Hey, does anyone know of any good sites or examples showing me how to create
a datagrid which i can easily navigate through.
I would like to be able to navigate through a datagrid using wee link
buttons. Can someone please point me in the right direction of how to do
something like this. He... more >>
Why not destructor?
Posted by Sharon at 11/24/2004 12:31:02 AM
I have heard that if I add a constructor it is not good, it complicates
things and that it is better to use the Dispose.
Can anybody explain this for me?
--
Regards
Sharon G.... more >>
|