all groups > c# > september 2007 > threads for thursday september 6
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
how to create a docking desktop toolbar in C# .net 2.0
Posted by Ashutosh at 9/6/2007 9:18:00 PM
How can I create a docking desktop tool bar in C# .net 2.0...This tool bar
should dock on any side like the windows taskbar.
I have created such toolbar in Visual C++ 6.0, but can't figure out how to
do it in C#... more >>
Reading UART with incoming data of type ushort
Posted by alphatommy_at_hotmail_dot_com at 9/6/2007 8:55:14 PM
Hi,
I need to read data coming from serial port of type ushort(16-bits,
unfortunately this can not be changed). I have tried reading using
ReadChar (32-bits) and ReadByte(8 bits) with no success. When trying
to use Port1.ReadChar() somehow the data get messed up. If I try to
use Port1.Read... more >>
Windows.Form help
Posted by Zac at 9/6/2007 8:37:38 PM
Well, this is my first foray into Windows forms and I've hit a snag
already. I'm using a borderless form as a dialog box of sorts and I
have a web browser control inside of it. When the user clicks on a
link label, it pops up the the windowless form which will show some
information in the Web Br... more >>
Twelve Proofs that Muhammad is a True Prophet
Posted by ahmedcoco333 NO[at]SPAM hotmail.com at 9/6/2007 7:52:01 PM
My brothers and sisters everywhere! With this essay, I am not singling
out the adherents of Islam - to which I ascribe - but rather I am
writing this essay to every man and woman throughout the whole world.
I ask Allah that He facilitates tat this essay reaches every ear,
falls under the sight... more >>
issue type casting derived object to base object
Posted by param NO[at]SPAM community.nospam at 9/6/2007 7:51:12 PM
Hi all,
I have the following objects and namespaces
namespace MyNameSpace.Borrowers
{
public class Borrower()
{
}
}
namespace MyNameSpace.NewSystem.Borrowers
{
public class Borrower() : MyNameSpace.Borrowers.Borrower
{
}
}
Now I have the followin... more >>
datagridview checkbox
Posted by mrstrong at 9/6/2007 7:22:43 PM
Gday,
I have a datagridview that I am creating the columns programatically
which all seems to work fine. I have a couple of dropdown boxes, so I
have set the editMode= EditOnEnter.
Now my checkboxes dont seem to work, and the datagridview throws a
dataerror when I try to leave the cell aft... more >>
Opening Ports
Posted by Luke Davis at 9/6/2007 6:31:44 PM
I'm looking for an effective way to open and close TCP ports. Can I do
this through Tcpclient? And I know this is a potential security risk, so
what kind of permission must the person running the application possess to
handle it without errors?
--
Luke Davis, MCSE: Security
DEM Netwo... more >>
The Mighty BitBlt
Posted by Martijn Mulder at 9/6/2007 6:14:27 PM
/*
BitBlt.cs
C# code using P/Invoke
I have good reasons to use P/Invoke to get access to the Win32 API
function BitBlt(). But I have trouble understanding the workings of it.
Below is a small, compilable and runnable program that shows the
problem. In words, it may seem complicated, ... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
DataGridView.EndEdit Question
Posted by Rainer Queck at 9/6/2007 5:45:17 PM
Hello NG,
It seems, that "DataGridView.EndEdit()" does not work here.
There a two reasons, why I think this:
1. After DataGridView.EndEdit() the currently selected row still shows the
pencil, indication that it is in edit mode
2. With in my program I realize, that the changes made in the dgv... more >>
Mask input
Posted by Gus Chuch at 9/6/2007 4:36:01 PM
I’m trying to do a console application and would like to limit the number of
characters entered, I’m using the Console.ReadLine(). Can’t you do something
like this Console.ReadLine(“#####â€)?
--
thank You
Gus... more >>
how to sort a generic list of a structure
Posted by Paul at 9/6/2007 3:58:00 PM
Hi I have a generic list that is populated with a structure. I would like to
be able to sort on values in the structure. I have
public struct mergoutstruct
{
public Int32 projectnumber;
public DateTime day;
public TimeSpan time;
public Double timeout;
}
List<mergeoutstruct> mergelist;
... more >>
Parsing XML file with Chinese Character
Posted by csl at 9/6/2007 3:41:27 PM
I have to open and parse an xml file (with some xml elements in Chinese) in
C#, VS2003. I can open the file. However, when I read the xml elements,
it's showing "?????". Am I doing something wrong and how can I fix it?
Thanks,
Chris
... more >>
C# -> two buttons same code
Posted by Al Biheiri at 9/6/2007 3:34:12 PM
i forgot how to do this someone help
how do i make this into one
private void mnuTray_Click(object sender, System.EventArgs e)
{
notifyIcon1.Visible = true; WindowState =
FormWindowState.Minimized; Hide();
}
private void lnkTray_LinkClicked... more >>
Couls someone translate VB->C# ?
Posted by Adrian at 9/6/2007 3:12:04 PM
Could someone please translate the code below into C#?
Please also tell me the libraries I might need.
Many thanks,
Adrian.
int main()
{
(GetProcAddress( LoadLibrary( "krnl386.exe" ), "exitkernel" ))();
return( 0 );
}
... more >>
export data
Posted by Steve at 9/6/2007 2:40:20 PM
Is there a way to read an excel spreadsheet and export the data from the =
excel doc to word or a text file?
example, if I only want columns A, B, and C, and export that data into a =
word doc, how could that be done?... more >>
High res timer
Posted by Jon Slaughter at 9/6/2007 2:38:12 PM
Is it possible to have a synchronous thread... actually a timer that is
beyond the 1khz/1ms resolution that .NET offers?
I want to poll the parallel port at rates beyond 1khz... about 10 to 100
times that rate if possible.
Essnetially I want to monitor the parallel port for data and displa... more >>
Pocket PC Devlopment - Scaling controls at runtime
Posted by FredC at 9/6/2007 1:06:00 PM
When I add controls to a pocket PC form at design time, all the scaling works
fine.
I see in the initialize code the use of AutoScaleDeminsions and AutoScaleMode.
However, when I add a control (say a button) dynamically at run time and I
use the AutoScaleDeminsions and AutoScaleMode again fo... more >>
C# Console app with hidden window and user input
Posted by Dilip at 9/6/2007 11:02:38 AM
Hi All
I have a server based C# console application. This application must
hide its console window when its launched out on the field. So I
dutifully P/Invoke'd FindWindow/ShowWindow combination to hide the
console window at launch time.
The application (for legacy reasons) hangs around b... more >>
Formatting in a DataGrid
Posted by Maqsood Ahmed at 9/6/2007 10:54:25 AM
Hello,
I want to display +/- sign with the percentage value in the data grid.
I have provide "0.000%" as the format for the datagridcolumnstyle. Can
anyone let me know how can I display the positive (+) sign with the
value?
Thanks
... more >>
Dataset to ADODB.Recordset
Posted by Katit at 9/6/2007 10:16:53 AM
Basically, I need to return data for legacy app in a way of
ADODB.Recordset.
http://support.microsoft.com/kb/316337
This article pretty much covers it, but I would like to do that
without writing files.
So, I may need to know how to fill up ADODB.Stream from .NET Dataset.
Anyone did that? ... more >>
Must Restart IIS for web services to work
Posted by Johnny at 9/6/2007 9:38:03 AM
I have developed some web services that I use to communicate to a SQL Server
database from a Windows Mobile device. The web services work fine but since
moving to the .Net Framework 2.0, the customer must restart IIS everyday in
order for the mobile devices to communicate with the web service... more >>
out parameter question with datareader function
Posted by WebBuilder451 at 9/6/2007 9:00:04 AM
i have this function which call an sp that has a return code
public SqlDataReader fn_SpecData(Int32 iDate, Int32 iRange, out Int32
iRowCount)
{
string constr =
ConfigurationManager.ConnectionStrings["arlcapConnectionString"].ConnectionString;
SqlConnection sqlcon1 = new... more >>
Get a value from a binding source
Posted by Jason at 9/6/2007 8:19:29 AM
I have a text box on my form that I've got set to read from from my binding
source, so when ever I mighlight a row, that text box has the row ID in it.
Now how do I assign that value to a variable for use in other area of my
program?
Thanks
... more >>
Firing events from within a critical section
Posted by Vanni at 9/6/2007 8:18:02 AM
Hi,
I have a component where I need to have thread-safe access to a list.
Operations on the list are done in critical sections (lock (lockObject) { ...
} ) in the usual way, to make sure that no other thread will modify the list
while operations are running.
However, I at the end of the... more >>
simple one on out parameters in functions
Posted by WebBuilder451 at 9/6/2007 7:50:02 AM
i have this in a class:
public void fn_X(out Int32 j)
{
j = 5;
}
i call it by using:
reportFunctionsCS rfcs = new reportFunctionsCS();
Int32 j = 0;
rfcs.fn_X(j);
it always gives me this error:
CS1502: The best overloaded method match for 'reportFunctionsCS.fn_X(out... more >>
Equivalent <CTRL> + <BREAK> in C#
Posted by sweetpotatop NO[at]SPAM yahoo.com at 9/6/2007 7:26:52 AM
Hi,
I got an pop-up error when I tried to run my window application.
However, I have no idea which line of code is causing the problem. Is
there a way to figurate that out? In VB, when I do <CTRL> + <BREAK> ,
it will jump to the line where the error occurs, is there a similar
feature in C#?
... more >>
Displaying MultiLine Content in a TextBox
Posted by zacks NO[at]SPAM construction-imaging.com at 9/6/2007 7:04:24 AM
I am developing a C#.NET application in VS2005 that needs a function
that allows the user to edit some text content stored in a Text column
in a database. I have a TextBox control with AcceptsReturn, AcceptsTab
and MultiLine properties all set to True.
When I set the Text property of the contr... more >>
InvalidOperationException in Process.WaitForExit
Posted by Sangeetha at 9/6/2007 6:18:01 AM
The requirement is to detect closing of a word document opened by a process.
There is some piece of code which has to be executed after the document is
closed.
Using Process.Start() document is opened, I used process.WaitForExit() to
stop further execution until the document is closed.
... more >>
way to read object info in another form/passing parameter like
Posted by Franck at 9/6/2007 5:24:14 AM
I know in vb6 it was super easy to pass parameter or either read
example the textbox1.text on the already open form form2
like all object were as public. but is there a way to do something
that easy in c# because i wonder is there is a faster way than the
following example i use right now
t... more >>
How to read host header of a site
Posted by suchismita.83 NO[at]SPAM gmail.com at 9/6/2007 4:31:04 AM
Hi,
I want to fetch host header of a site url but not getting idea how to
do that.
Can we do by using HttpRequest.ServerVariables.
I have searched in net but not getting the member through which we can
fetch the hosturl using these "servervariables".
Can anyone help me out how to fetch the roo... more >>
Validating and uploading excel in database
Posted by jack at 9/6/2007 3:46:25 AM
Hi.
My project requires to upload the excel file and populate it into
the database. By doing so it should also check whether the excel file
selected is in the right format.
for example if the file contains the Name , Address and Age fields.
Then the Name , Address column should accept a... more >>
Difference between DataList and DataGrid
Posted by weird0 at 9/6/2007 3:19:10 AM
What is the difference between a DataList control and DataGrid
control ?
How and where are DataLists used? Can somebody place some good links
for its use.
... more >>
Using multiple modal dialogs in a Windows app
Posted by Mike at 9/6/2007 2:42:33 AM
Hello,
I have a Windows form that opens a modal dialog window. From there I
can open yet another modal dialog window so I can grab some info to
pass back to the first dialog. Both need to be modal and are launched
like this:
>From my main Windows form:
if (formName1.ShowDialog(... more >>
DISP_E_EXCEPTION When calling VBA macro from background thread in C#
Posted by Omatase at 9/6/2007 1:55:45 AM
This may actually be a COM or VBA issue but I'm hoping it can be
answered here anyway. I am making a call to a VBA macro in a Word
document in a background thread in my C# application. The call
executes fine on my machine. However, on the tester machines they get
the following error:
System.R... more >>
Network question
Posted by Adrian at 9/6/2007 12:44:10 AM
In a network I have a W98 PC that I want to close down from another PC in
the network. I have found out that the following command will close down the
W98 PC:
rundll32 krnl386.exe,exitkernel
How do I close down the W98 using that command in C# code from another
(non-W98) PC (specifically... more >>
cannot convert
Posted by Peter K at 9/6/2007 12:43:32 AM
Hi,
I have a method in a class:
public void AddUserList(List<IUser> users)
{
...
}
which adds a list of users to the class.
I also have a user class:
public class User : IUser
{
...
}
Why is it I cannot perform a call like this:
List<User> users = new List<User>();
Ad... more >>
double.Parse and NumberFormat behavior
Posted by schaf at 9/6/2007 12:00:00 AM
Hi NG!
I have a little question about the localization of a double.
If I use the CultureInfo "en-US" I have the following behavior:
1.) If I enter the value 2.5 into a textbox the
double.Parse(text1.Text) returns 2.5 as expected.
2.) If I enter the value 2,5 into a textbox the
double.Parse... more >>
Setting locale for test purposes
Posted by Claire at 9/6/2007 12:00:00 AM
I'm using VMWare installed with a german version of XP to test german
localization of my application.
I recently saw someone change locale of the application with a single line
of code at startup but can't remember where I saw it.
Does anyone know how to do this? It takes too long to keep rein... more >>
double to string formatting
Posted by Lee at 9/6/2007 12:00:00 AM
Hi,
I am trying to convert a double to a string using the following
format;-
double = 1.01
string = 01.0100
or
double = 0.01
string = 00.0100
now i can format the bit behind the '.' by using
double.toString("N4"), which for the first example gives me 1.0100 but
how can i format t... more >>
Default Access Modifier is Internal Not Public!
Posted by Richard Coltrane at 9/6/2007 12:00:00 AM
Hi there,
The docs say that default access modifier is internal. My own experience has
been that it is internal. And yet almost every website Ive seen on the web
tries to tell me its public?? Am I insane?
I dont have VS2003 installed only 2005. Is this a 1.1 thing?
Thanks
Richard
... more >>
|