MDI Child Form Not Releasing DataSet
I have an application that creates MDI child windows to edit different datatables in the same
dataset.
At one point in the application cycle, users have the opportunity to log off the database server (so
they can reconnect to a different one). As part of that log off, I clear the dataset.
Unfortunately, if an MDI child form has been opened and then closed, the datatable for that form
hangs on the clear (i.e., aDataTable.Clear() stalls forever). This problem does not occur if that
table's form has not been opened and closed.
This seems to be a problem where the MDI child form, while "closed", is still maintaining a
reference to the datatable (probably through databinding?).
How do I get rid of this reference so that datatable can be cleared? I've tried setting the
MDIParent property of the MDIChild form to null in an event handler for the MDIParent form that
watches for MDIChild Close events, followed by a call to MDIChild.Dispose(). Unfortunately, that
does't solve the problem.
Any leads or workarounds would be greatly appreciated.
- Mark
p.s. BTW, this is looks to be the second "silent failure" of the NET Framework I've come across in
the past week (the first had to do with the way the Framework's handling of DBNull values for bound
DateTimePicker controls breaks the BindingContext.Position code, with no outward sign of a problem).
I'm beginning to think the NET Framework design team didn't take enough advantage of exception
handling in developing the Framework. Tag: ListView.SelectedIndices does not work Tag: 56184
automatic code generation
I'm not sure if this is the right forum, but it has to do
with the automatic code generation of a WinForm for the
Compact Framework.
Anyway, I thought I'd report an issue I've been having. I
subclass a control to define my own button class that can
draw custom images (since the CF does not permit this as
is). Anyway, to add it to my winForm, I manually add it
in among the automatically generated code, adding it to
the proper tab control, etc.
I build it, run it, and it works fine. Sometimes if I
then hide the automatically generated code (w/ my newly
added code interspersed) and proceed to edit the WinForm
through the GUI interface provided in VS .NET 2003 C#, at
some point, the code I intertwined w/ the automatically
generated code disappears.
I haven't nailed down the exact procedure that causes the
problem b/c each test I have to re-write the inter-mixed
code. Right now it isn't a big deal for me, but in the
future it might become an issue. I suspect that at some
point, the compiler may be re-generating the
automatically generated code but doesn't realize I've
edited it? Oh, and before it removes the code, an error
might pop up saying my class is uninitialized, but if I
build my project, it sees that it is initialized (among
the auto-gen code) and builds fine. Tag: ListView.SelectedIndices does not work Tag: 56183
Alternative to TransparencyKey property?
Hi,
I'm trying to convert an application from C++ to CSharp.
Under C++ I used the SetLayeredWindowAttributes() API
to make parts of my form transparent. Now in CSharp, I
was trying the forms TransparencyKey property. However,
it doesn't work on my system with 32bit display and I found
this confirmed by other posts on this topic.
I asked myself if I could avoid this problem by dllimport-ing
the API function. I'm very new to CSharp and Dotnet and
could not get it working, yet. I would really appreciate if
anyone could tell me what is wrong in the following code:
//the original function signature
/*
BOOL SetLayeredWindowAttributes(HWND hwnd,
COLORREF crKey,
BYTE bAlpha,
DWORD dwFlags
);
*/
//define the key constant
private const int LWA_COLORKEY = 0x00000001;
[DllImport("user32.dll", SetLastError=true)]
public static extern int SetLayeredWindowAttributes(int hwnd,
int cKey, byte bAlpha, int dwFlags);
//in the forms constructor
int ret = SetLayeredWindowAttributes(this.Handle.ToInt32(), 0x00FFFFFF, 0,
LWA_COLORKEY);
if(ret == 0)
{
try
{
throw new Win32Exception();
}
catch(Exception err)
{
MessageBox.Show(err.Message);
}
}
thanks for any ideas,
Nick Tag: ListView.SelectedIndices does not work Tag: 56177
Mouse Events in Nested Controls
Hi all,
I am wondering what the "normal" behavior for mouse events(click,down,
etc..) within nested controls is. Do the mouse events fire for the
container control and the child control if you click on the child control?
Or only the child control? or only the parent control?
The reason I am asking is because I have a Panel which has many child Panels
within it. When I hook up a mouse event (mousedown,click) to the parent, it
does not fire when I click on the child control. I was hoping it would fire
so I could use GetChildAtPoint to access the child control. The event DID
fire when I clicked on part of the panel without a child control.
I then opted to hook up the mousedown event inside my child control and
simply have it act upon the parent control to do the work. Unfortunately,
the event does not fire here either!?
Am I missing something? Is there a property that must be set correctly to
make this work?
Thx in advance,
Cole Tag: ListView.SelectedIndices does not work Tag: 56176
DataGrid and unbound text boxes
I'm building a VB.Net Windows form application.
I have a DataGrid and 5 unbound textboxes on a form.
The DataGrid is populated with a OleDbDataAdapter and is using a table
called Clients.
What I want to do is have the users fill in the unbound textboxes and click
a button and have those values inserted into the table clients. I will then
refresh the datagrid and the new values will appear.
I created a New Connection, A New DataSet and A New Select Command to the
table Clients.
When I Create a datarow like so:
Dim drw2 As DataRow
drw2 = DataSet1.Tables("tblClients").NewRow
I recieve a error " Object reference not set to an instance of an
object......"
When I look up the error it looks like the new select command I've built is
interfering with the one on the OleDbDataAdapter.
Does anybody have any workaround ideas?
Thanks
Erik Tag: ListView.SelectedIndices does not work Tag: 56172
drop down list events
I have created a drop down list and populated from db. When an item is
selected, I want to then populate and make visible a second list based
on the value of the first.
My problem is that I can't get the selection to be detected...
I have coded
Sub ddlDistricts_SelectedIndexChanged(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles ddlDistricts.SelectedIndexChanged
Dim wsGetAreas As New localhost.myWebservice1()
dsAreas = wsGetAreas.GetAreas(ddlDistricts.ID, boolerr)
ddlAreas.DataSource() = dsAreas
ddlAreas.Visible() = True
End Sub
but the event never triggers..
What am I doing wrong?
kate
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it! Tag: ListView.SelectedIndices does not work Tag: 56171
Can userControl's menu item have shortCut?
Even if I set the shortCuts of a user control's menu items, they do not
work. What's the tricks?
Thanks, Tag: ListView.SelectedIndices does not work Tag: 56170
MyMainMenu - Urgent
Hi
I need to catch the event MouseDown and MouseUp on a MainMenu but this
classe haven´t those methods.
How can i write them??
Thank You Tag: ListView.SelectedIndices does not work Tag: 56166
Unable to add short key key to tab sheet in tab control
Hello,
I'm not able to add shortcut key to the tab sheet, which is a part of
default tab control. If I place a '&' in the text property of the tab sheet,
the ampersand chararter gets displayed in the tab sheet caption. If I add
another ampersand, the second one is not shown.
How do I add a shortcut key to the tab sheet.
Deepak Kashyap MJ Tag: ListView.SelectedIndices does not work Tag: 56165
Memory Issue
I am developing a application and I think I have a memory
leak, but I am not sure.
TESTS:
1: I open and close a edit window I have work on for 2
weeks the memory grows by 6MB
2: I open and close the same edit window with no code, no
data just controls and the memory grows by 6MB
3: I create a brand new form with a couple of random
controls and no code and I open and close it the using the
same SUB, memory does not increase at all.
Something seems to be wrong with my window however I have
no idea what. Could someone give me some insight into why
this would be happening.
I really do not want to cut and paste all my code and
controls into another window just to find out I still have
the same problem. Tag: ListView.SelectedIndices does not work Tag: 56163
how to set focus on a combobox on a tab when the form is loaded?
Hi,
I have a form with 3 tabs and each tab has a combobox on
it. When the form is loaded, I determine which tab to
display based on parameters passed into the form's New()
method.
When the form is loaded, I would like to place the cursor
in the combobox of the selected tab, place some text in
the combobox, and highlight the text. However, not only
am I unable to get the cursor in the combobox (combo.focus
() executes, but does not do it), assigning the text to
combo.text does not show the text in the combobox.
combo.SelectAll
combo.SelectedText = [my text]
creates an error, apparently because combo has not been
fully loaded yet.
Any ideas how to get the text into the combobox,
highlight the text, and put focus in the combo?
Thanks,
David Tag: ListView.SelectedIndices does not work Tag: 56161
how to set focus on control in a tab on tab click?
Hi,
When I click a tab on my form, I want a combobox on that
tab to be given the focus (I want the cursor to be
sitting in the combo, blinking, and if the user starts
typing, the text should appear in the combo). Setting
the focus from the tab.SelectedIndexChanged event does
not do it. The combo seems to have focus (if I type, the
characters appear in the combo), but the cursor is not
visible until I click in the combo.
Any thoughts?
Thanks,
David Tag: ListView.SelectedIndices does not work Tag: 56159
.NET DataGrid vs. 3rd party controls
I have not done much work with .NET yet but we are trying to decide
whether the grid that Microsoft provides is going to provide enough
functionality for us. As far as VB 6, we use the Videosoft FlexGrid
now and have found it to be very useful. Does anyone know what how
good/bad the .NET grid is? Are there different versions for web forms
versus windows forms?
Any help would be appreciated.
Thanks! Tag: ListView.SelectedIndices does not work Tag: 56155
Problem with Web Service and Inherited Forms
Hallo, I have a big problem with Windows Forms and Web Services. When
I add a Web Service to my solution, the forms inherited from other
forms don't get opened in design mode and I get a reference error.
Am I the only one who has got this problem?
I have Visual Studio 2003 and framework 1.1
Please help me... Tag: ListView.SelectedIndices does not work Tag: 56153
Book Suggestions Please!
I have had VS7 for about a year now and use C# mainly.
The apps that I write are for my own use on the desktop so ASP/Web
applications hold little interest for me. I tend to use the Win API a
lot still but I suspect that there are better ways.
I am looking for book(s) that give details of the various namespaces
and the functionality within them (I know it's in the help but I can't
read that in the bath) and especially any books that will ease the
transition from the API to inbuilt functionality (assuming it's
there). Books that show how to use the API for things like shell hooks
and how to show the system context menu would be very much of
interest.
I liked the earlier Petzold books because they gave a complete
breakdown of the API and also Appleman's book on VB6 and the API.
I have I got Petzold's Programming Windows, Jesse Liberty's
Programming C# and Mueller's .NET Framework Solutions. They look good
on the face of it but are very basic once you get into them and really
add nothing beyond the excellent help system in VS.Net.
Any suggestions would be appreciated, those I have searched for
usually end up being about writing Web apps rather than Windows Forms
apps.
Regards
--
Jeff Gaines Damerham Hampshire UK Tag: ListView.SelectedIndices does not work Tag: 56148
How to detect closed form?
I have opened form from another form and I have an variable with reference
on it. But what if someone close referenced form? I tryed to test an
variable on Nothing value but there is still reference on closed form. The
questin is: How can I find out that the referenced form is closed.
I have two ideas:
1) Exception handling
2) Handle closed event of closed form
Is there some better way?
And another problem. When a referenced form is closed, I can still run
frm.Hide() without throwing exception, but frm.Show() fires exception.
Object is closed, so why frm.Hide() doesn't throw the exception too?
Thanks Martin Skrenek Tag: ListView.SelectedIndices does not work Tag: 56144
Data Entry via DataGrid
Is it possible to do add records via a datagrid? For
example, an application opens a datagrid with its source
a datatable with 2 records. Can one add a third record
to the source datatable via the datagrid? If so, how
please? Thank you.
JT Tag: ListView.SelectedIndices does not work Tag: 56137
ANN : Klik! SizeLib.Net v1.2 has been released...
This is a multi-part message in MIME format.
------=_NextPart_000_0081_01C37618.C29B82D0
Content-Type: text/plain;
charset="iso-8859-9"
Content-Transfer-Encoding: quoted-printable
=DDstanbul, Turkey - 05 September 2003
=20
Klik! Software today announced availability of SizeLib.Net v1.2 to make =
your .Net applications resolution independent.
=20
SizeLib.Net consists of 2 controls. The first one is a full blown =
Resizer control which keeps your controls size/font proportion related =
with it's container. The second one is SizePos control which completes =
the well known resolution independent paradigm claimed by most of the =
resizer products. This control tracks the screen resolution and adjusts =
your forms whenever the resolution changes and also has the ability to =
save your form/size and position to ensure that your forms will always =
open on the same size and position.
=20
".Net Windows Forms has brought us great layout management features like =
ability to dock and anchor controls." said =D6zden Irmak, President of =
Klik! Software. "But sometimes they don't let you to achieve the layout =
management you want. This brought us with the conclusion of SizeLib.Net. =
We aimed not to give only a Resizer control but also wanted to complete =
the well known resolution independent paradigm with the SizePos control =
and more...".
=20
Please come and visit us on http://www.kliksoft.com/ to have more =
info...
=20
About Klik! Sofware :=20
=20
Founded in 2002, Klik! Software is a privately held company with the aim =
of developing quality software components and tools for software =
development community.
=20
Our aim is to provide easily usable and most functional products on the =
market which also reflected to our slogan, "the rest is just a few =
kliks...".
------=_NextPart_000_0081_01C37618.C29B82D0
Content-Type: text/html;
charset="iso-8859-9"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-9">
<META content=3D"MSHTML 6.00.2800.1170" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY>
<DIV>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><FONT face=3DArial><FONT =
size=3D2><STRONG>=DDstanbul,=20
Turkey – 05 September 2003<?xml:namespace prefix =3D o ns =3D=20
"urn:schemas-microsoft-com:office:office"=20
/><o:p></o:p></STRONG></FONT></FONT></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><o:p><FONT face=3DArial=20
size=3D2> </FONT></o:p></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><FONT face=3DArial><FONT size=3D2>Klik! =
Software today=20
announced availability of SizeLib.Net v1.2 to make your .Net =
applications=20
resolution independent.<o:p></o:p></FONT></FONT></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><o:p><FONT face=3DArial=20
size=3D2> </FONT></o:p></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><FONT face=3DArial><FONT =
size=3D2>SizeLib.Net consists=20
of 2 controls. The first one is a full blown Resizer control which keeps =
your=20
controls size/font proportion related with it’s container. The =
second one is=20
SizePos control which completes the well known resolution independent =
paradigm=20
claimed by most of the resizer products. This control tracks the screen=20
resolution and adjusts your forms whenever the resolution changes and =
also has=20
the ability to save your form/size and position to ensure that your =
forms will=20
always open on the same size and =
position.<o:p></o:p></FONT></FONT></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><o:p><FONT face=3DArial=20
size=3D2> </FONT></o:p></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><FONT face=3DArial><FONT =
size=3D2>“.Net Windows Forms=20
has brought us great layout management features like ability to dock and =
anchor=20
controls.” said =D6zden Irmak, President of Klik! Software. =
”But sometimes they=20
don’t let you to achieve the layout management you want. This =
brought us with=20
the conclusion of SizeLib.Net. We aimed not to give only a Resizer =
control but=20
also wanted to complete the well known resolution independent paradigm =
with the=20
SizePos control and more...”.<o:p></o:p></FONT></FONT></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><o:p><FONT face=3DArial=20
size=3D2> </FONT></o:p></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><FONT face=3DArial size=3D2>Please come =
and visit us on=20
</FONT><A href=3D"http://www.kliksoft.com/"><FONT face=3DArial=20
size=3D2>http://www.kliksoft.com/</FONT></A><FONT face=3DArial><FONT =
size=3D2> to have=20
more info...<o:p></o:p></FONT></FONT></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><o:p><FONT face=3DArial=20
size=3D2> </FONT></o:p></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><FONT face=3DArial><FONT =
size=3D2><STRONG>About Klik!=20
Sofware :</STRONG> <o:p></o:p></FONT></FONT></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><o:p><FONT face=3DArial=20
size=3D2> </FONT></o:p></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><FONT face=3DArial><FONT size=3D2>Founded =
in 2002,=20
Klik! Software is a privately held company with the aim of developing =
quality=20
software components and tools for software development=20
community.<o:p></o:p></FONT></FONT></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><o:p><FONT face=3DArial=20
size=3D2> </FONT></o:p></SPAN></P>
<P class=3DMsoNormal style=3D"MARGIN: 0cm 0cm 0pt"><SPAN=20
style=3D"FONT-FAMILY: Verdana"><FONT face=3DArial><FONT size=3D2>Our aim =
is to provide=20
easily usable and most functional products on the market which also =
reflected to=20
our slogan, “the rest is just a few=20
kliks...”.<o:p></o:p></FONT></FONT></SPAN></P></DIV></BODY></HTML>
------=_NextPart_000_0081_01C37618.C29B82D0-- Tag: ListView.SelectedIndices does not work Tag: 56132
docking forms
Hello,
I have a form (mdiclient) containing 2 docked forms
frmprojecttree and frmProjectinfo
The following code creates the docked form frmProjectinfo
Public shared cProjectinfo as content
' Create the object that manages the docking state
DkManager = New DockingManager(Me,
Crownwood.Magic.Common.VisualStyle.IDE)
cProjectInfo = DkManager.Contents.Add(New
frmProjectInfo, "Project Info ", internalImages, IntCount
Mod 6)
IntCount += 1
' Setup initial state to match menu selections
DefineContentState(cProjectInfo)
' Setup the correct starting colors to match the
menu selections
DefineControlColors(cProjectInfo)
' Request a new Docking window be created for the
above Content on the right edge
DkManager.AddContentWithState(cProjectInfo,
State.DockTop)
The fields within this docked form are bound to a
collection, this works fine as the index of the
collection "projlist" changes.
below is the binding code
ProjList = Projectlist.GetProjectsArray()
'bind all the form fields to their respective
properties of Project
'MyProjectDet.MdiParent = Me.MdiParent
mdiClient.CProjectInfo.Control.Controls
(6).DataBindings.Add("text", ProjList, "ProjectCode")
mdiClient.CProjectInfo.Control.Controls
(4).DataBindings.Add("text",
ProjList, "ProjectSiteAddress")
mdiClient.CProjectInfo.Control.Controls
(3).DataBindings.Add("text", ProjList, "ProjectSiteName")
mdiClient.CProjectInfo.Control.Controls
(8).DataBindings.Add("text",
ProjList, "ProjectSiteTownCity")
The only problem is that when you click to dock the
projectinfo form by clicking on the bell the binding is
lost. Any idea how to stop the binding from been lost on
docking (clicking the pin icon) of the projectinfo form.
Regards
Robert Tag: ListView.SelectedIndices does not work Tag: 56130
DataGrid
Hello,
i'm using DataGrid in my WinForm application, now i'd like to know how to
get notified when the data is changed by the bindingmanager, because i've a
master detail form and i'd like to know when the data in my detail
(datagrid) is changed when master data change.
than you Tag: ListView.SelectedIndices does not work Tag: 56126
.net localization problem
can i specify the localization (which language to display) each time when i
run a window application instead of localize by the windows system
automatically? Tag: ListView.SelectedIndices does not work Tag: 56115
String Builder - not appended
Hi
I am using a variable of StringBuilder to form a string.
After appending a string of value like this
{\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttbl{\f0\fnil\fcharset0
Verdana;}}
\viewkind4\uc1\pard\f0\fs17 saesae \b esrdsr esrdsr\i refetwe\b0\i0\par
}
This value is appended to that string builder.
Whatever appended after this value, not getting appended to the
StringBuilder.
How to solve this problem?
Thanks and Regards
Karuppasamy Natarajan Tag: ListView.SelectedIndices does not work Tag: 56114
Toolbar buttons dont' show
I just wrote a quick Windows app with some toolbar buttons. In design view,
the buttons show up fine, but when I run the app, the toolbar button images
don't show up. Is there some simple setting that I am missing? I've tried
using both .GIF and .BMP format, and both show up fine in the designer
(although the GIF is the only one that has transparency working normally). Tag: ListView.SelectedIndices does not work Tag: 56107
Printing Problems
I am printing several pages.
Problem 1:
While the printout looks fine on one printer (OKI C9400 PCL) it comes out as
gibberish on another one (HP LaserJet 5/5M PostScript)
Other Windows applications (such as Word, Excel) print OK to both.
Problem 2:
If I preview the pages (using any of these printers), the printout looks OK
on screen.
When printing from the Preview dialog only partial data is printed (same on
both printers except for the gibberish).
Any ideas? Tag: ListView.SelectedIndices does not work Tag: 56104
UserControl Load Event
Does anyone know of an event that is fired after a
UserControl is created regardless of whether it is visible
or not. I have a data bound UserControl that needs to
populate it's contents when it is loaded at runtime, but
not at design time. If i try to load the data in the
constructor, the DesignMode property is not set so I can't
skip the data loading in the designer. If I handle the
Load event, it doesn't fire when the control is first
created, only after the parent form is hidden, then re-
displayed.
Anyone? Anyone? Tag: ListView.SelectedIndices does not work Tag: 56101
Application slow down
Hi there.
I have written a kiosk application in C# where the user can browse the
internet amongst other things.
When there has been no user activity for a while (e.g. half an hour) the
application seems to slow down and responds slowly to the next user.
I was wondering if anybody has an idea as to what could be the reason for
this.
Thanks,
Anders Schultz Tag: ListView.SelectedIndices does not work Tag: 56100
Images on button with XP-Theme
I have an application that has bitmap images on the
button. The applicaton was displaying them fine until I
added a manifest to the application to display them as XP
style buttons. I used the example manifest in the VS
2003 documentation in C#.
I have spent a couple hours scanning the web looking for
the answer to this..
What do I have to do differently to the image on a button
when it is displayed using an XP them.?
Anyone able to nudge me towards a solution?
Thanks... Tag: ListView.SelectedIndices does not work Tag: 56095
Form's Location
I am trying to possition a main application form (Form)
at a specific location. I used Bounds and Location
properties to set the x and y of the form and with no
avail. The form get displayed anywhere but where I want
it to be. Tag: ListView.SelectedIndices does not work Tag: 56091
Project
Is anybody interested in joining me and Marc
(http://www.codeproject.com/useritems/AAL-1.asp?
print=true) in working on a .NET based product that could
potentially lead to a commercial release?
Please, don't replay unless you are serious and have time
and energy to see it through.
Roman Tag: ListView.SelectedIndices does not work Tag: 56088
How to change the ForeColor and BackColor of a listview subitem?
Is there any way to change only the ForeColor and
BackColor of a subitem of a listview item? That means
if the listview is displayed in detailed mode, only one
field of a listview item has a different color instead of
the whole row. Tag: ListView.SelectedIndices does not work Tag: 56085
PropertyGrid
Hi all
Could some onne point me to the right direction please? I am trying to
create a new PropertyGrid derived class and add a new property tab on it.
Put it on a form and use it as a customised property display of any selected
object. I have found no suitable method to add a PropertyTab in the
PropertyTabCollection of the PropertyGrid. I have tried using the
PropertyTabAttribute on a target object's class definition, but that doesn't
work either. Surely I am missing something obvious.
Thanks
RK Tag: ListView.SelectedIndices does not work Tag: 56084
listview item looses forecolor
Hello All,
I have a listview item on listview with the property HideSelection set to
False.
I set the listview item forecolor to green and set the font to be bold.
When the listview loses its focus, the listview item that was selected
looses its color (goes back to default black), preserving its boldness.
I want to keep the forecolor, even upon lost focus
Is this a known bug??
Can anyone help??
Thx
Iris Tag: ListView.SelectedIndices does not work Tag: 56056
Embed Excel in Windows Form?
You could embed excel in a VB6 form using an OLE
container control. Is it possible in a VB.NET Windows
form? Tag: ListView.SelectedIndices does not work Tag: 56049
Picture box
I have an application that draws an image from a number of
points inside a picturebox.How can I capture the image
drawn in the picturebox and save it as a file like:
Bitmap.Save("image.jpg");
Thanks Tag: ListView.SelectedIndices does not work Tag: 56045
tabcontrol backcolor
Is there a simply way to avoid the standard "BackColor" of
the TabControl?
I mean, if you put on a form a TabControl with one
TabPage. Set the BackColor of the form and of the TabPage
to, say, Blue.
You will still have the "tab zone" of the TabControl to be
colored by SystemColor.Control
Can we change that? Is there a property somewhere I missed?
Do we have to do that manually using GDI methods? (if so,
does somebody has some code or tricks?) Tag: ListView.SelectedIndices does not work Tag: 56043
Cancelling current activity in progress indicator
Hi all,
in my application I want to implement a progress
indicator which has 'Cancel' button allowing to interrupt
the current activity. What is the best way to do such a
thing? I'm considering the following variant:
The progress indicator is created on demand on the
separate thread and stored in the local memory of the
thread that has initiated its creation ('initiating
thread'). The progress indicator also stores a reference
to the initiating thread. When a user clicks 'Cancel'
button, a delegate is executed on the initiating thread
that throws an exception, so that it can be handled
somewhere on the initiating thread.
The purpose of creating progress indicator on a separate
thread is that it will be unable to handle windows
messages (like clicking 'Cancel') if it is created on the
initiating thread.
Am I right or I'm reinventing the wheel and there is an
easier way? I would prefer simpler design, but I'm not
competent enough in WinForms to figure it out.
Thanks in advance,
Dmitry Tag: ListView.SelectedIndices does not work Tag: 56042
Date Web Service
Has anybody seen a web service that can check the date. I wish to use this
as a simple shut down for a software product. Instead of checking the
computer's date, which can be changed by the user, I could require an
Internet connection and check the real date with a web service. A simple yet
effective way to shut down a program. Anybody seen this web service?
Derek Tag: ListView.SelectedIndices does not work Tag: 56037
Rich Text Box
Hi..
I am having a Rich Text Control in a Form.
Whatever Text entered into the RichText, i want to save the Text along with
Format.
I want to display the Text again with same format using the saved Text and
Format.
How to do that??
Thanks and Regards
Karuppasamy Natarajan Tag: ListView.SelectedIndices does not work Tag: 56035
How to hide Icon on MDI Form?
Is there a way to hide the Icon (and its placeholder) on a maximized MDI
child form?
Thanks!
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it! Tag: ListView.SelectedIndices does not work Tag: 56034
Vertical Text on a Button
any simple way to rotate the text on a button to a vertical orientation?
specific examples would be most usefull.
thanks,
-andrew Tag: ListView.SelectedIndices does not work Tag: 56032
Panel autoscroll position
Can anyone help?
Why do some controls reposition themselves to the correct position
automatically when I scroll my panel. Others I have to manually reposition.
In the If statement: control is to the left of the autoscroll position.
The ElseIf: control is to the right of the autoscroll position.
This works fine on all controls that do not reposition themselves
automatically.
They are all invisible before reposition.
Could it have something to do with the ZOrder. I've tried bringing them to
front first.
'move groupbox according to autoscrollposition of panel(pnlcategory).
Public Function MoveGroupbox(ByRef pnl As Panel, ByVal grpbox As GroupBox)
As Integer
With grpbox
If Math.Abs(pnl.AutoScrollPosition.X) > .Location.X Then
.Location = New Point(0 + pnl.AutoScrollPosition.X - .Location.X,
.Location.Y)
ElseIf Math.Abs(pnl.AutoScrollPosition.X) < .Location.X Then
.Location = New Point(0 + pnl.AutoScrollPosition.X + .Location.X,
.Location.Y)
End If
End With
Return grpbox.Location.X
End Function
Thanks ,
Daniel Jenkins Tag: ListView.SelectedIndices does not work Tag: 56028
PropertyGrid Collections do not fire PropertyValueChanged
Hi,
I have a collection in an object that can be edited by a propertygrid. When
the user edits properties the
PropertyValueChanged event fires and I can mark my object as dirty (ie needs
saving) but if the user edits a collection contained in the object the event
doesnt fire.
Whats the best way to get notifications if collection contents are changed?
BM Tag: ListView.SelectedIndices does not work Tag: 56027
How do I support MouseHover over different TreeNodes in one TreeView?
I have a TreeView with more than one TreeNode. I would like to do
something like set a ToolTip during a MouseHover event.
Unfortunately, since TreeNodes don't generate events. The TreeView
owns the MouseHover event, but it generates only one event per session
of moving from TreeNode to TreeNode. I could move most of my logic
into the MouseMove event, but I don't want to recalc everything
everything on every MouseMove over the TreeView, as it could slow down
the mouse motion. I greatly prefer the delay the MouseHover event
gives me.
Ideally, there would be a way that I can cause subsequent MouseHover
events to be generated after a MouseMove event over a different node
from the last MouseHover event. Is there something?
Thanks,
Eric
EricP@ActiveState.com Tag: ListView.SelectedIndices does not work Tag: 56026
Datagrid Index Out of Bounds
Hi,
I have a form with a datagrid that loads a modal dialog
when the f3 button is clicked. A value from a read only
datagrid in the modal dialog is double clicked, the modal
dialog is closed and the value is returned to the main
form's datagrid cell. This works fine but when I attempt
to tab out of the cell, I get an index was outside the
bounds of the array error, which is coming from the modal
dialog. I have tried things such as setting
currentrowindex but no success. Any ideas? Thanks in
advance. Tag: ListView.SelectedIndices does not work Tag: 56023
drag a menuitem?
In XP, I can drag menu items (for example - I can drag an item on my
Start Menu to the Desktop to create a shortcut for it).
Can this action be accomplished in .NET? I want to be able to drag an
item off of a ContextMenu.
matt tag Tag: ListView.SelectedIndices does not work Tag: 56021
DataGrid
Does anyone know how to customize datagrid error messages.
When I set AllowDBNull = false for a datacolumn in a
datatable, the bound
datagrid displays an unfriendly message for null
columns, "Error when
committing the row to the origianl data store ...
Column '[x]' does not
allow nulls. Do you want to correct the value?".
Does anyone know how to customize that message, override
it, or intercept
and handle it via some event? Tag: ListView.SelectedIndices does not work Tag: 56020