all groups > dotnet windows forms controls > august 2004
Filter by week: 1 2 3 4 5
rich edit control and SES_EMULATESYSEDIT
Posted by Sk at 8/31/2004 4:11:44 PM
Hello,
I am trying to use EM_SETEDITSTYLE property on the rich text box by doing
following sendmessage
WindowsAPI.SendMessage(customControl11.Handle,1228/*EM_SETEDITSTYle*/, 1,1);
From richedit.h I find that style SES_EMULATESYSEDIT is represented by 1.
But this call returns 0 indicating th... more >>
Adding an 'internal' control to the toolbox.
Posted by Chien Lau at 8/31/2004 1:56:59 PM
I frequently define internal UserControl-derived classes in my WinForms
apps:
internal class MyUserControl:UserControl{
...
}
I'll often need to embed these controls in a Form, whose class is
contained in the same assembly as the control. As far as I know, the only
way to do t... more >>
Adding Controls to User Control at Design Time
Posted by Jeff Gaines at 8/30/2004 7:57:04 PM
I am building a small control with two panels and a splitter.
At design time I want to be able to add this control to my form and
then drag other controls on to it to be contained within the panels.
Although I can drag controls on to it they do not get 'captured' by it.
I added a couple of... more >>
[FORM] Catching Minimize event
Posted by Didier BRETIN at 8/30/2004 3:56:08 PM
Hello,
I would like to catch the "minimize event" of a form and then add an icon
in the systray. I found how to add the icon, but I can't find the "minimize
event" of the form.
What is it ?
Regards.
--
Didier BRETIN... more >>
Images in ListView header
Posted by Sebastian Pusz via .NET 247 at 8/30/2004 2:36:21 PM
Hi,
I'm trying to write my own ListView control using VS2005 Beta1 (MC++). I've got problem with displaying images in ListView headers. When
Application::EnableVisualStyles() is NOT call then the code below works, but I have no idea why it dosen't work with Application::EnableVisualStyles(). Any ... more >>
Clone control in run-time?
Posted by James Wong at 8/30/2004 12:09:32 PM
Dear all,
I would like to know how I can clone a control in run-time. Let say I have
a status bar on one form and I want to clone it to all other forms with
original property values. I've tried to create a new instance on the target
form and set the source object to the new instance, but fai... more >>
Urgent: Embedd application
Posted by Gharbi Taoufik via .NET 247 at 8/30/2004 11:06:41 AM
(Type your message here)
Hi Everybody
Let's assume that we have a standalone GUI-based application called "myApp.exe"
and another .net form-based application called "form.exe".
All what I want to do is that to embedd myApp into form.
I have to code in this way:
Process p = new Process();
p.... more >>
RichTextBox WYSIWYG
Posted by Gerrit at 8/30/2004 2:02:54 AM
Hi.
I'm trying to put a RichTextBox into WYSIWYG mode, so that line breaks on
the screen are the same as printed. I can successfully set the standard word
wrap mode:
SendMessage(MyBase.Handle, EM_SETTARGETDEVICE, IntPtr.Zero, 0)
But I can't figure out how to set the WYSIWYG mode. It is ... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
ExtendedDataGrid
Posted by Jurjen de Groot at 8/29/2004 3:04:56 PM
I'm trying the ExtendedDataGrid (http://dotnet.leadit.be/extendeddatagrid/),
having a small form trying to get the ComboBoxColumn to work but can't seem
to make it work, it just shows a textbox. I've also added a
FormattedTextBoxColumn but this one also seems to be shown as a standard
textbox in... more >>
Unreliable Datagrid doubleclick event..
Posted by W.G. Rowland at 8/29/2004 11:39:27 AM
I'm trying to get three events working on a datagrid:
1) When a user clicks a row that row highlights..
That works fine using the mouseup event for the datagrid
2) When a user right clicks a row a context menu pops up.
Also works fine using the mouseup event
3) When a user double-clic... more >>
Form editor control
Posted by shahar NO[at]SPAM log-on.com at 8/29/2004 5:34:32 AM
I'm looking for a component that is like the form designer editor like
the VS.NET IDE, the control need to supply some kind of panel that I
will inherit from and I will be able to drag my panel to the editor
and move it like the IDE,
Any ideas? (I'm willing to buy one if necessary).
Thanx.... more >>
Panel.ParentForm??
Posted by lukasz at 8/29/2004 3:15:50 AM
How can I retrieve ParentForm for a Panel? I have a control derived from
Panel that runs some threads, and I need to stop these threads when the form
with the control is closed so I thought of setting a handler on the form's
Closed event. Or is there an other solution to stop the threads? I'd pre... more >>
Custom Cursor and Control Border problem
Posted by john.westlund NO[at]SPAM gmail.com at 8/29/2004 12:29:12 AM
If you create a form and place a textbox on it and set
the cursor property for both of them to something other
than the default cursor, the outer edges of the textbox
(about 2 pixels wide) revert back to the default pointer.
Any thoughts?... more >>
Free Version of Magic Library
Posted by w.binz NO[at]SPAM gmx.de at 8/27/2004 12:23:26 PM
Hi,
the version 2.0 of Magic Library is commercial. The older versions
were for free. Has someone an older version and would share this
version with me?
Thanks
Werner... more >>
Return file as string
Posted by Microsoft at 8/26/2004 6:59:04 PM
Is there a way in vb.net to have the user browse to a file and return that
file's name and path as strings?
... more >>
Read stream one line at a time
Posted by Microsoft at 8/26/2004 6:39:21 PM
I am trying to use the openfilediaolog to open a file and read it one line
at a time.
openfiledialog returns a stream and from what I can see, streamreader is the
only way to read a file one line at a time
Anyone offer some guidance as to how to get around this.
... more >>
How to construct System.Drawing.Color?
Posted by Klaus Bonadt at 8/26/2004 11:47:39 AM
I would like to retrieve Color settings, serialize them via XML and
construct the Color struct afterwards in order to use
RichTextBox.SelectionColor.
This would be easy if do not have to serialize the color, for example:
ColorDialog colorDialog1 = new ColorDialog();
// Set the initial... more >>
Override ImageIndex property
Posted by dan.fontanesi NO[at]SPAM ngc.com at 8/25/2004 3:22:01 PM
I'm subclassing the button control and would like to change it so that
instead of just an ImageIndex property, the user sees four properties
called:
ImageIndexNormal
ImageIndexPressed
ImageIndexHover
ImageIndexDisabled
And each of these properties acts like the ImageIndex property, ie.,
... more >>
Building an array of checkboxes
Posted by steven.cooper NO[at]SPAM infocision.com at 8/25/2004 1:58:09 PM
I have a form that has a GroupBox1 with 4 check boxes in it. Test1
checkbox, Test2 checkbox, etc..
I need a way to iterate through the checkboxes and store in an array
all checkboxes whos values is checked.
Here is what I have :
For Each ctl In Me.GroupBox1.Controls
If TypeOf ctl Is... more >>
is reset datasource of bound combobox possible?
Posted by njp at 8/25/2004 10:37:02 AM
BlankHi,
I can't get this to work and don't even know if it's possible. Bottom line,
can a datasource be reset via code?
1) I have two bound comboboxes on a tab page control (have no idea if the
tab page causes a problem). The comboboxes are bound via their SelectedValue
property.
2) Bot... more >>
Remove dynamically created PictureBoxes from form
Posted by Henry at 8/25/2004 2:57:05 AM
Hi,
I have added dynamically a variable amount of pictureboxes (names are
PictureBox_000000, PictureBox_000001 ....) in my form (according to a
selected list item). If another list item is selected I want to remove these
PictureBoxes from the form and add the new Pictureboxes according to t... more >>
Localizing PrintPreviewDialog
Posted by Nick Carter at 8/24/2004 7:55:21 PM
It looks as if the PrintPreviewDialog control cannot be localized and I
wondered if anyone can confirm or deny this. All of the other dialog
controls appear to be based on their equivalent Windows controls and
therefore they get localized if you use a localized version of Windows. The
PrintP... more >>
obtain a refference to parent form in child controls initialization
Posted by Bamse at 8/24/2004 4:02:06 PM
Hi,
I have this problem:
In several custom controls, derived from Windows.Forms.{TextBox, CheckBox,
TabControl, etc} I need to get a refference to the hosting form as early as
possible.(I need to subscribe to events in order to execute some code).
the problem is that some controls can be pl... more >>
Can't hide tabs of tab control???
Posted by jqpdev at 8/24/2004 2:32:47 PM
Does anyone know how to hide the tabs of the tab control? I've tried
changing the height of the tabs to zero but that doesn't fix it. I've also
found a bug in the tab control. The bug is when a developer sets the
alignment to bottom and the tabs style to flat buttons. When the form is
loaded... more >>
What Button Was Clicked ??
Posted by Charles A. Lackman at 8/23/2004 12:22:46 PM
Hello,
I have a project with multiple child forms (created from DLLs). When a
button in the child form is clicked the Parent form needs to know what
button was clicked. Any Suggestions will be greatly appreciated.
Thanks,
Chuck
... more >>
Form doesn't close w/ two instances of usercontrol
Posted by at 8/23/2004 10:19:21 AM
Hi,
I have create a user control which is basically an extension of a list box.
The listbox allows to edit the items by showing a control (e.g a text box,
but not necessarily) when an item is double clicked.
Due to requirement for generic implementation, the editing control is
acquired ... more >>
user controls scrolling problem
Posted by thivyaa77 NO[at]SPAM yahoo.com at 8/23/2004 8:19:12 AM
Hi All
i am creating a user control that holds controls.. the problem is when
i add controls to the container control, the controls added scrolls
up.. wot shud i do to stop the scrolling in the container control.. i
am inherting the parentcontroldesigner and not
scrollablecontroldesigner..
... more >>
Listview MouseUp not Firing
Posted by WaydeWyatt at 8/22/2004 7:01:02 PM
I recieved some excellent help from this newsgroup to modify the ListView's
shift-click multiselect behavoir (see below). The problem I'm having now is
that MouseUp event will not fire until the mouse is moved. Anyone have any
ideas how to workaround this?
""Ying-Shen Yu[MSFT]"" wrote:
... more >>
ToolBarButton image not recognizable when setting Enabled property to false
Posted by Klaus Bonadt at 8/21/2004 8:43:32 PM
I use VS .Net 2002 and a C# project.
When I set ToolBarButton.Enabled to false, the corresponding icon is just
gray. I mean it is not grayed a little bit in a way that you have the chance
to recognize the underlying image, the image is completely hidden. This is
very ugly, not user friendly and ... more >>
Build own MonthCalendar Control
Posted by Stefan Huber at 8/21/2004 5:26:24 PM
Hello,
I am make my first steps with Windows.Forms and would like to build my own
control on basis of the System.Windows.Forms.MonthCalendar.
the goal is to inherrit my control from the MonthCalendar in such a way that
i can add a date to the calendar and a specific backbround color of this
... more >>
Datagrid editing problem
Posted by Todd McCarty at 8/20/2004 4:43:59 PM
I have a windows application with a form that contains a bound datagrid. On
the form's closing event, I call MyDataAdaptor.Update. My problem is that if
I edit a field in the datagrid, and I dont move the focus off the edited
cell, the new value is never saved. How do I test if the current cell a... more >>
Tab control
Posted by HungTrinh at 8/20/2004 3:25:36 PM
Hi
I use a tab control in window form. When I remove all of the pages in
tab controll, the screen is flicked. Could you tell me how to avoid the
screen is flicked?
Thanks
Hung
... more >>
How do I invalidate only part of my nonclient area?
Posted by johnrlewis NO[at]SPAM hotmail.com at 8/20/2004 2:26:21 PM
I am doing some drawing in the nonclient areas of my control by
intercepting the WM_NCPAINT message in my WndProc.
I need to reduce the amount of flicker in the nonclient area. But it
seems that I cannot invalidate only certain portions of my nonclient
area like I could in the client area.
... more >>
Can PrintPreview show Excel, Word, PDF, etc...?
Posted by Walter G at 8/20/2004 1:59:04 PM
I'm working on a VB.Net applications that saves any file (txt, word, excel,
pdf, etc...) in SQL Server as binary. Then, I need to show them and I thought
of printpreviewcontrol + printdocument.
I managed to show a text, but not a binary. Is there a way to make this
work? or is there a better ... more >>
Message Thread Notifying the UI Thread
Posted by msnews.microsoft.com at 8/20/2004 1:28:28 PM
Hey, since I obviously can't be the first guy to hit this problem, was
wondering what the preferred solution is ...
I have two threads ... a message thread and the UI thread.
On the message thread I would like to update the OrderBindingList ... but
when I add another order to the list, since... more >>
Related datagrid issue, end edit ect
Posted by gordonmoore01 NO[at]SPAM operamail.com at 8/20/2004 7:38:53 AM
I wonder if someone could explain what is happening and suggest how to
overcome this issue (with theory?)
I have two tables in a dataset. One holds the questions: with Stem the
actual question text and QID as a unique identifier. The second table
holds the options for the question (i.e in mult... more >>
Retrieving information over the Internet on .NET
Posted by hester at 8/20/2004 12:31:01 AM
Hi,
here's the info:
I have a problem with retrieving information from a file
over the internet on .NET and I hope that you will be able to help me. When I
try to retrieve information from a file, say an xml file, over the internet,
I get the following error :
The... more >>
Focus on a TextBox
Posted by msnews.microsoft.com at 8/19/2004 10:35:08 PM
Was wondering if anyone else has run into this?
I have a dialog that has three textboxes ... A, B and C. The tab order is
simply ... 1, 2, and 3 respectively.
Eventhough that is the tab order, if A and B have text in them (lets say b/c
it was restored from a config file) then textbox should ... more >>
Datasets? Properties? Values?
Posted by Charles A. Lackman at 8/19/2004 2:37:23 PM
Hello,
I have been working with an application that sends a dataset to other forms
that are called from individual DLL's.
I have noticed that, a dataset that is passed to another form, when changed,
changes the dataset in all of the forms.
But, if you send a string to the other forms, that ... more >>
How to set Text for the images in the Imagelist
Posted by Mary at 8/19/2004 1:55:20 PM
Hi,
My windows app has a toolbar which points to a imagelist.
I would like to display besides the image.
I couldn't find any text property for the image in imagelist.
Let me know how can I accomplish this.
Thanks for ur time,
Mary
... more >>
Forecolor of Selected item in a listview
Posted by Gerry Viator at 8/19/2004 1:17:24 PM
Hi all,
I have a owner drawn list view control. And view is set to details, I have
only one Column.
How do I change the forecolor(blue) of a selected item to another color?
thanks
Gerry
... more >>
KeyPress Event not Firing???
Posted by Darryn Ross at 8/19/2004 11:25:51 AM
Hi,
I am trying to catch the KeyPress event on my datagrid but it isn't
working... i have also tried registering the handler with the event like
this...
dgGLBatch.KeyPress += new KeyPressEventHandler(dgGLBatch_KeyPress);
but nothing changed. I was wondering wether a custom table and colum... more >>
TabControl
Posted by Lachlan at 8/18/2004 8:03:01 PM
I have created a class inherited from TabControl (below) which adds 4
properties to control the font and backcolor of selected and unselected tabs.
These use the drawItem event when the OwnerDrawFixed DrawMode is set.
My problem is that if the mouse pointer tail is over one of the tabs when ... more >>
Detecting a new Datagrid Row
Posted by Paul J. Lay at 8/18/2004 7:53:50 PM
BlankI have an app which includes a winform datagrid bound to a dataset. =
At times a new row is added to the dataset and sometimes the datagrid =
displays the new row as the last row and other times the row is=20
displayed as the first row. My code works great if the new row is =
displayed l... more >>
PlugIn Architecture
Posted by TusharP at 8/18/2004 7:23:41 PM
Hi,
Before asking my doubt, first I want to tell you about my application
structure. I want to design a Client Desktop program, which has an MDI form.
This MDi Form has one Horizontal Toolbar. Button of Toolbar get added
whenever it find Plug-in dlls in "Plug-In" directory. Now this Plug in dll
... more >>
ComboBox default selection
Posted by SpikeGuy01 at 8/18/2004 4:33:02 PM
Hello,
I have a form with multiple ComboBoxes with the style of DropDown. When
loading my form, I prepopulate the combo boxes with items and select one item
by default via the .selectedindex .items.getindexof(myobject).
The issue I have is that when the form becomes visible, all the combo... more >>
Custom Sorting a DataTable Using DataGrid
Posted by rettigcd NO[at]SPAM bigfoot.com at 8/18/2004 12:07:22 PM
I have a DataTable with several columns. One column is a string that
represents distances.(1 foot, 5 meters, 3 cm, etc) I want to click on
the column header and have the rows sort based on the distances: 3cm,
1 foot, 5 meters.
I know how to create the "sort value" of each distance but I don'... more >>
OpenFileDialog (C#)
Posted by John Beard at 8/18/2004 11:11:16 AM
Does anybody know if STAThread is a requirement when using OpenFileDialog?
I have an app that is using MTAThread Form and the OpenFileDialog hangs on
the OpenDialog() method under Win2k. No problems under WinXP.
Thanks in advance.
... more >>
True XP style owner draw menu
Posted by jon morgan at 8/18/2004 10:56:14 AM
Hi,
To make an XP style owner draw menu really look the part it's necessary to
make a main menu item appear as a tab to its' menu when it is clicked.
All the owner draw menus I've seen lack this feature - probably because you
can't implement it in the OnDrawItem method.
Does anyone know h... more >>
.net 2003 SelectNextControl deletes text from multiline text box!
Posted by snocoProg at 8/18/2004 9:31:02 AM
I am using selectnextcontrol to tab when the enter key is pressed. Works
great except for multiline text boxes. Both sendkeys and selectnextcontrol
delete the text from all of my multiline text boxes. The following is the
code that does the work - I use addhandler to add the event to my cont... more >>
|