|
Closing form while processing
Hi
I have a while loop in a win form code. Also a close button on the form
calls Me.Close. How can I let the user close the form using the close button
even though the loop is still running? Right now pressing Close button waits
for loop to finish and then closes the form.
Thanks
Regards
...
|
1 |
12/31/2008 9:31:10 AM |
|
Accessing another form's fields
Hi
From FormA I am opening another form FormB using ShowDialog(). Is there a
way to access a text field on FormA (calling form) from FormB (called form)?
Thanks
Regards
...
|
11 |
12/30/2008 5:53:33 PM |
|
DataGridView - Change selection color when focus lost
(I had posted this in the C# group and then found this group which I think is more appropriate)
I realized tonight that the DataGridView doesn't support a different selection color when it doesn't have focus. After
realizing this I set out on what I thought would be a quick and simple task to solve the problem.
Granted I'm no DataGridView expert, but to me this seems like it should work a...
|
1 |
12/30/2008 4:01:20 PM |
|
DataGridView (DataSource) not updating correctly when underlying DataTable is changed.
Hello,
I have unusual one:
' in DataManager class...
objDataTable.Reset()
objDataAdapter.SelectCommand.CommandType = enumCommandType ' <-- in
this case, CommandType.Text
objDataAdapter.SelectCommand.CommandText = strParameter ' <-- SQL
Query
objDataAdapter.Fill(objDataTable)
' In ControlsManage class...
objDataGridView.DataSource = nothing
objDataGridView.DataSource = objDat...
|
2 |
12/30/2008 3:20:28 PM |
|
Scrolling control under mouse cursor
I'm looking for a way to smoothly scroll the control under the mouse cursor
(not necessarily part of my application). I'm using C# with WindowFromPoint
to get the handle, and I've tried SetScrollPos and ScrollWindowEx without any
success. I'm simulating mouse wheel events right now, but this only scrolls
the active window and doesn't allow horizontal scrolling except in Vista.
Also, i...
|
1 |
12/30/2008 8:30:01 AM |
|
GUI Like VS
Hello all, I was wondering how you go about designing a GUI like visual
studio. What I am looking for is the ability to pull a window out of the
main GUI and then be able to drag it back to the GUI locking it back into
place, similar how you can move the properties and solution explorer around.
Are there any examples out there? If so can someone please point me into
the right directio...
|
5 |
12/29/2008 7:58:48 PM |
|
Enum is not clear
Something I did not understand the joke humor
What's the magic of 0 in enums?
class Program
{
static void Main(string[] args)
{
Foo a_obj = new Foo();
SubjectStatus a_s = a_obj.Status;
Console.WriteLine(a_s + "-" + a_obj.Status);
a_obj.Status = SubjectStatus.New;
Console.WriteLine(a_obj.Status);
...
|
3 |
12/29/2008 4:14:15 PM |
|
How do I allow Alt-key shortcuts to always display?
Currenlty, such as in Visual Studio 2005, our C# .NET 2.0 app is only showing
Alt-key shortcuts aftre the user first presses the Alt key. How do we have
the shortcut keys get displayed alwyas without having to require the user to
first select teh Alt key? FYI, we are using Winforms.
Thank you for any help, Dan
...
|
4 |
12/29/2008 3:24:01 PM |
|
AccessViolationException while disposing StringFormat on x64
We have such a piece of code:
using (StringFormat tempFormat = GridProperties.StringFormat)
{
StringFormat tempFormat = GridProperties.StringFormat;
StringFormat stringFormat = new StringFormat(tempFormat);
stringFormat.Alignment =
(StringAlignment)formatRule.Layout.AlignHorizontal;
stringFormat.LineAlignment =
(StringAlignment)formatRule.Layout.AlignVertical; ...
|
7 |
12/29/2008 12:24:30 PM |
|
wpf font scaling
I have an area where I want to have some text displayed with the largest font
possible but the scaled text should be no larger than 300 wide and 50 high.
I was wondering what is the best way to do this in WPF.
I know pre-WPF you would do something like this:
http://blog.paranoidferret.com/index.php/2007/10/10/csharp-tutorial-font-scaling/
thanks,
...
|
2 |
12/29/2008 10:18:30 AM |
|
plugging windows form application to mfc application
1) i have a windows form based (CLR , visual studio 2005 )
application , which is running fine.
2) i have two more application in MFC ( VC++, visual studio 2005 ),
which are running fine.
Now i need to make a combined application which will kind of contain
all three. Basically the idea is to have 3 tabs and each tab showing
a
different application.
This means i have to either port wi...
|
1 |
12/29/2008 9:51:41 AM |
|
Message.Box: Questions
Hi all,
having a Message.Box like this:
MessageBox.Show("File " + fileName + " already exists.
Overwrite them?", "Rendiconto Export Files", MessageBoxButtons.YesNoCancel);
how can I intercept the Yes, or No button, to run separate methods?
And if I have several files, how can I implements a button like "Yes to
all", or "No to all"?
Thanks in advance.
--
Luigi
...
|
5 |
12/28/2008 4:22:57 PM |
|
Call Hierarchy
I need the call hierarchy of procedures in a project in order to trace the
calling path of procedures.
I googled and found this nifty functionality is included in VS 2010, but I
can't wait, I kind of need this right now.
Anyone knows of something available?
I'm using VS 2008 and the project is a VB .net project.
Thanks.
...
|
7 |
12/28/2008 10:09:08 AM |
|
Trapping KeyDown Events
I have a complex control based on a UserControl that is largely a graphical
rendering of data. While a user is viewing this data I would like to respond
to certain keyboard events.
(PageUp, PageDown, Home, End, ArrowUp, ArrowDown)
Since the control is mouse driven by "clicking" on various regions, there
are no controls contained that capture the focus.
The built in KeyDown event ap...
|
1 |
12/28/2008 3:40:01 AM |
|
Enlarge image on mouseover (.NET 2.0)
I'm trying to create a smoothly animated doubling in size of an image when
the user moves the mouse over it and shrinking back to normal when the mouse
leaves. The image needs to enlarge/shrink while staying centered, NOT pinned
to the top-left corner. With WPF this is apparently only a couple lines of
XAML code but I'm at a loss so far in doing it efficiently and cleanly in
..NET 2.0.
...
|
1 |
12/28/2008 1:15:00 AM |
|
Pasting HTML text doesn't work in Firefox
I need to copy a piece of HTML to the clipboard. I'm doing this
DataObject clipData = new DataObject();
clipData.SetData(DataFormats.Html, true, html);
Clipboard.SetDataObject(clipData, false);
If I paste, it works fine in any HTML edit box in Internet Explorer
and Chrome but it doesn't work in Firefox. Should I use another
format? What's the problem with it?
Thanks.
Andrea...
|
3 |
12/26/2008 7:05:33 PM |
|
elementHost repaint problem in MDI application
Hi
I am having a refresh\repaint problem with the ElementHost control. I have
created a Windows Forms MDI application and inserted ElementHost on a child
form with a very simple XAML. When I move a child form out of MDI parent
working area, and then use MDI parent scroll bars to bring it back,
ElementHost located in a child form does not repaint itself and brings back
visual garba...
|
1 |
12/25/2008 3:16:00 AM |
|
multiple occurences of HandleCreated for a single control
I’m using control that needs to be register to asynchronous events.
The events will be raised in the UI thread using the ISynchronizeInvoke
interface implemented by WinForms controls
I can’t register to the event at the constructor because it will allow
calling the event handler before the control is fully created. during which
calls to ISynchronizeInvoke are not allowed.
Soluti...
|
2 |
12/25/2008 3:00:32 AM |
|
How to design I2C communication functionality
Hi,
I have a question about how to design my classes in the following situation:
I have a communication port. It connects to an I2C bus. Through this port I
can communicate to a number of devices on the I2C bus. I am always the master
on the I2C bus. With each device I have a different protocol.
I think it will be ok to leave the port open all the time, and communicate
each time with ...
|
1 |
12/24/2008 7:13:00 AM |
|
Deploy satellite assemblies
I have an app deployed with clickonce.
In this app I am using some custom assemblies (DexExpress controls) deployed
also with clickonce (not in GAC).
For theese assemblies I have also some satellite assemblies for romanian
language.
I've copied theese sattelite assemblies in bin/debug/ro folder and from
visual studio it's working fine.
How can I deploy theese satellite assemblies wit...
|
1 |
12/23/2008 11:38:04 AM |
|
Clearing a listview
What is the fastest way to clear the contents of a ListView?
listView1->Clear() takes far too long.
Cheers,
K
...
|
4 |
12/23/2008 1:31:20 AM |
|
DataGridViewRowHeaderCell and DataBinding
I have a class that implements IBindingList and ITypedList. All well and
good DataGridView displays data. Now I would like to display other than
column headers and even row headers. How to do it without changing
DataGridView? This is possible?
Thanks in advance!
http://www.alvas.net - Audio tools for C# and VB.Net developers + Christmas
Gift
...
|
1 |
12/22/2008 1:12:32 PM |
|
Richtextbox: how are pictures stored?
I'm using the RichTextBox component to store formatted text and
pictures. I noticed that inserted pictures are always stored as WMF,
that causes the size of the generated RTF to become very big.
Is there a way to use an alternative way to store pictures (for
example, in JPG, PNG or GIF) instead of bitmap?
Thanks.
Andrea...
|
3 |
12/20/2008 8:34:35 AM |
|
Connecting to a remote Web Service Error, help plz
There's a problem in my windows application that calls a remote web service's
method, when it tries to connect to the webservice it displays this error:
"The request failed with HTTP status 407: Proxy Authentication Required (
The ISA Server requires authorization to fulfill the request. Access to the
Web Proxy service is denied. "
How the hell can i connect to the remote webservice ?
...
|
4 |
12/20/2008 7:24:01 AM |
|
Where to put code to have it execute only when form actually comes up (i.e. is visible)
I have code that I want to execute as soon as the form comes up. This
code includes code that shows a status form indicating processing
activity, a form that immediately closes once the processing activity
is completed. I can't call it from the Load event as it will execute
before the form is visble. Where is the best place to put code like
this? I thought that perhaps the place would be in t...
|
4 |
12/19/2008 4:47:18 PM |