How to compare two string
How to compare two string
e.g
i compare two string
e.g User == user is true
however i want User == user is false by 'U' and 'u'
do u know what i said Tag: Get Rich Tag: 97124
Does anyone have an example of the UndoEngine workign with a custom IComponentChangeService implementation?
Just trying to figure out how to get a service working that has no
viable public methods... My current problem is that nothign ever gets
added to the undo stack... All of the other methods are getting
called. So my base assumption right now that is that my custom
implementation is either preventing the UndoEngine service from getting
called or that the designer example from MS that doesn't use a designer
class, is unaware of the UndoEngine.
ANyway, my head for the designer class is this:
public class RootDesigner : IContainer, IDesignerHost,
IDesignerLoaderHost,
IComponentChangeService, IExtenderProviderService,
IToolboxUser, IDesignerEventService
{
Changing my OnChanged event to trigger the UndoEngine is possible, I'll
have to make some public accessor methods on the UndoEngien
implementation. However, currently my changed event get's called more
than once for 1 user operation. In the case of coping, 1 for the copy
and 3 or 4 more for changing properties... This of course would not be
a very optimal implementation of undo to have 4 entries for 1 user
change. :(
Anyways, any help appreciated. Tag: Get Rich Tag: 97122
populating combo with ds
Hi, I'm trying to populate a combo with a typed dataset (I am filling the
dataset in the form load) by using the databindings , (Selected Item &
Selected value) I get a blank combo box. (Unless I bind the text property,
but then I only get the first row as the combo text.)
Am i missing a step?
Many thanks for any answers
Ant Tag: Get Rich Tag: 97119
Resizing Form
Hi,
I am having a number of panels containing other panels and controls on
my form. When I resize my form, the redrawing is quite slow.
How do I properly handle this so that it redraws form faster when I
resize it? I am using VS2005 and C#
Any help wll be appreciated
Dino Tag: Get Rich Tag: 97118
ReportViewer & PageSettings.HardMarginX
In a report, I tell a table or a text box to print at specific coordinates
but it is off. How do I teach ReportViewer to take PageSettings.HardMarginX
and PageSettings.HardMarginY into consideration?
This occurs in .NET Framework 2.0. Tag: Get Rich Tag: 97117
How many Dll loaded when form start
Hi Gurus,
Is there any way to find out how many Dll got loaded when my application
started.
Any help greatly appreciated.
Thanks, Dan Tag: Get Rich Tag: 97112
How do I fin that Form.Show() is already called?
Hi,
What would be the best way to find if Form.Show() is already called?
If I call Form.Show() methid several times, does it have any side effects?
Does it call eny events?
Than k you,
Alan Tag: Get Rich Tag: 97110
Ampersand as Ampersand in mdi tab
I have an application that uses mdi. If a file that is an mdi child has an
ampersand in the name of the file, the ampersand is getting read as a hotkey
in the tab text.
Does anyone know of a way in vb.net to make sure that the ampersand is
represented as an ampersand and not as a hotkey.
Thanks for your help!
-J Tag: Get Rich Tag: 97101
multiple BindingNavigators on a single Form?
Is it possible to get multiple BindingNavigators on a single form, in that
there is a TableLayoutPanel oder mulitple Panels and each section can hold
its own BindingNavigator.
When using a DataSource and Drag&Drop Databinding, I failed.
thanks herbert Tag: Get Rich Tag: 97100
Autocomplete textbox
Hello all!
I'm looking for ideas on implementing a textbox with autocomplete
functionality, just like the one found in Excel.
As the user types values into the textbox a lookup for matching values
is performed. For example lets assume that the user types the character
'1' and that the candidate values are '01', '02', '03', '10', '12' etc.
I need the textbox to display the first candidate value that partially matches
the characters typed ('01'). The cursor should be located at the end of the
user typed value (1|0) and the rest of the text must be selected.
As the user goes on typing, the selected text is replaced with the typed
character and the lookup
is performed again.
I am very close. I use the Textbox.SelectionStart and
Textbox.SelectionLength properties but the problem is that the caret is
allways placed at the end of the selection when I need it to be located at
the begining.
Any Ideas?
Thanks!
PS: I cannot use a combobox! Tag: Get Rich Tag: 97098
AutoClose = False behaves strange
Hi.
Does AutoClose property works for ContextMenuStrip ?
Steps to reproduce:
1. Create new Windows Application Project
2. Add ContextMenuStrip.
2.1 Add some items (ToolStripMenuItems)
2.2. Set AutoClose = False
3. Set Form1.ContextMenuStrip = contextMenuStrip1
Run the project and rightclick the form. Context Menu does not appear for
me.
If you set AutoClose = True (default value) - everything works fine.
Thank You. Tag: Get Rich Tag: 97096
Two values for combo box
Hi,
Firstly, I'm using C# if that will make a difference to the answer...
Is there any way you can assign two values for a combol box like in the vb6
'old days', so you have say, a string 'UserName' displayed in the combo box,
but that returns an integer 'userID' for that selection?
If not, what would be the best way to impliment this? An array? I am wanting
to use the Datareader, holding two columns of data to populate the combo box.
Any ideas would be most appreciated
Many thanks in advance
Ant Tag: Get Rich Tag: 97093
Newbie User Interface hangs in multi-thread app
Hi,
* Apologies for reposting this from .NET Academic *
I am having problems updatingh the user interface in a multi-threaded
application.
BACKGROUND
My App has a user interface (the starting class containing main) and a
CPU class to handle many asynchronous comms routines.
The user interface will be kept updated on the status of the comms by the
CPU class.
My user interface creates an instance of a class called CPU and passes itself
in the constructor this way the CPU can update the user interface by calling
a method of UI
PROBLEM
The user interface is becoming unresponsvie.
The cursor turns to the hour glass and it doesnt repaint
Although all the comms threads run happily in the background as soon as
the CPU tries to call the UpdateScreen method the UI hangs.
ASSISTANCE REQUIRED
Could you please advise me on how i should go about resolving such a problem.
I may well be using bad coding strtegy so pleas advise as you see fit on any
aspect.
Thanks,
Shaun
PSEUDO CODE
// within the UI class
private CPU theCPU;
public UI()
{
theCPU = new CPU(this);
}
UpdateScreen(string status)
{
textBox1.Text = status;
panel1.Visible= ! panel1.Visible;
}
// within the CPU class
public CPU (UI userInterface)
{
this.userInterface = userInterface;
// start threads to run async comms
}
private void ReceivedStatusChange()
{
userInterface.UpdateScreen("Some new status info");
} Tag: Get Rich Tag: 97091
Hiding MDI 'sunken' border
Hi,
I have seen some code which is basically GetWindowLong + SetWindowLong with
AND NOT ws_ex_clientedge, but it either removes the caption or nothing at
all.
Jared Tag: Get Rich Tag: 97088
CloneMenu in ToolStripMenuItem?
In the framework 1.1 I liked using CloneMenu() to clone menu items from a
main menu to a contenxt menu during a contenxt menu pop up. Is there anything
like CloneMenu in 2.0 for ToolStripMenuItem? Tag: Get Rich Tag: 97082
ComboBox and Tab character '\t'
Hi,
I am trying to show TAB character (char(9) or '\t') in a combobox dropdown
list, but it doesn't show it. Is there anyway to show '\t' as a TAB in
dropdown list text?
If I can show \t in dropdown text, then I can make it like multicolumn list.
This trick used to work back in win16 days.
Thank you,
Alan Tag: Get Rich Tag: 97081
Tactics for Debugging Custom Components with CodeDom Serialized State
I have a custom component which has a complex internal state that is serialized using CodeDom serialization. It is part of a library
used in a moderately complex project. The component has a custom design-time interface displayed within VS2003. All of the library
assemblies are loaded into the global assembly cache on my development machine.
This is all under VS2003 and .NET 1.1.
Unfortunately, for reasons I have not been able to fathom, the project is very "touchy". Changes to any one of the library
assemblies (there are 17) tends to break the deserialization process. I suspect this is due to known problems with VS2003's
synchronization of changed global cache assemblies.
The resulting error messages are not at all helpful (e.g., Method not found, object cannot be converted to target type). What's
worse, I can't seem to "break" on where the problem is occuring, and single-stepping through the component's initialization process
doesn't run into any problems.
The only clue I've been able to find is that commenting out the following line in InitializeComponent() makes the "object cannot be
converted to target type" error message go away):
this.AccessControl = new OlbertMcHughLLC.DBFramework.Security.AccessControl("acl", "idnum", "name", "acl_detail", "acl_id", "name",
"can_read", "can_write", "can_add", "can_delete");
What's weird about this is that the object being created >>is<<, in fact, of the correct Type...which is why I think the problem is
with VS2003's support for syncing assemblies.
I'd appreciate hearing any tactics/strategies which others have found helpful debugging these kinds of problems.
- Mark
p.s. and please, MS support staff, don't ask me to send the entire project to someone -- it's megabytes of source code, and it'd
take me a week to explain how it ought to work. Tag: Get Rich Tag: 97078
Auto Complete/Suggest (On Steroids)
I am looking to implement a search feature into a Windows Forms MDI
application. Specifically I plan to embed 3 textboxes into a toolbar; one
for LastName, another for FirstName, and one for CustomerID. When the user
starts typing into any of these textboxes I would like to pop up another
form that shows the user a dynamic list of the closest matches. The user can
then use the up- and down-arrow keys to select a customer from that pop up
form.
To see an example of similar ("close-but-not-quite") functionality, go to
http://www.thebusco.com/ and in the upper left-hand corner there is a
textbox with 'Enter Part Search Here'. Start typing 'air vent cover' to see
the behaviour in question. Yes, it's a Web application and I'm doing a
Windows Forms app, but it shows you the general idea of what I'm trying to
accomplish with Windows Forms.
Please note that I am familiar with the new 2.0 features: AutoCompleteMode,
AutoCompleteSource, and AutoCompleteCustomSource.
But those won't work for my situation because I'm *not* looking to simply
populate a textbox or a combo box from the list.
What I am needing to do is let the user select the customer for which info
is to appear in the currently active MDI form (and not only the control into
which they are typing). The idea is that the user starts typing into any one
of the 3 textboxes; as they type - the pop up window appears and shows the
closest matches. The user then hits the down arrow key a few times to select
the desired match, then hits Enter to (1) close the popup window, and (2)
trigger logic that shows the selected customer's info in the currently
active MDI form.
Note that I want to pop up another window [for the closest matches] so that
I can show the user many property values for the possible matches (and not
simply show them a list of names similar to the one they are searching, for
example).
What do you see as the biggest challenges in accomplishing this dynamic
search capability (and reasonable solutions)? What are the building blocks
you might suggest for the solution?
Thanks for your time and consideration! Tag: Get Rich Tag: 97077
ComboBox: How can I limit user to list items?
Hi,
How can I limit user to only available items in the combobox list?
By default user can choose one of the list items and also type anything
she/he wants!
Thank you,
Alan Tag: Get Rich Tag: 97074
Generic windows error message
I've built a windows app on .NET 2.0. I have a few users that run it without
issue. One user reports that it immediately pops up the standard windows
window that reports:
<program> has encountered a problem and needs to close. We are sorry for the
inconvenience.
What does this possibly mean ? How can I trace the problem?
NB. I have a "run in debug mode" option which writes to a debug log file but
even that is not generated. Tag: Get Rich Tag: 97066
Security Model
I am designing a new Windows Forms client application (with SQL Server db on
the back end) for which users will authenticate via NT authentication
(network), or SQL Server authentication. Users who are granted access to the
application must also be granted access to specific forms and controls on
forms. The menu must show/hide items based on the user's access level. Also,
some controls should allow editing by some users but not others (based on
their security level).
My first thought is to have a static class that gets populated when the user
is authenticated. This static class would contain "user profile data", one
piece of which is some "security access level" value. Then the menu and all
forms (in their form_load event procedure) look to that static class to
determine what controls to enable/disable/hide.
What do you think about that? Is there some [other] standard/better way to
accomplish the security objectives?
Thanks! Tag: Get Rich Tag: 97065
Prevent scroll into view on getting focus
Hi all. I have a scrollable panel and a bunch of controls on it.
When one of the controls gets input focus the panel automatically
scrolls so that the control becomes visible in all it entirety.
I have a listbox which is originally half-hidden, when a user clicks
on it to select an item, it suddenly jumps up (according to the logic
I described above) and the user ends up with selecting wrong item.
Is there a way to work around this behavior? Any help is appreciated.
This is VS2003, .NET 1.1. Tag: Get Rich Tag: 97062
Can a windows service msg via smtp?
Is it fairly straightforward to write a window service in either .net
2003 or 2005 that periodically interrogates a local data store (Access
mdb) and based on records from that, sends emails out to a smtp server ?
The idea is to send email reminders based on data in the db. SMTP server
is probably another box. If this is not a great route to take, what
would be more appropriate? And if .Net is a good approach, is 2005 going
to make is much simpler than 2003? A SQL server job could initiate
emails too; that would be simpler; but I need an alternative to that
approach. Not sure if this is the best ng to post in for this? Tag: Get Rich Tag: 97058
code clean up
Hi,
I have added some buttons and boxes on the VB.net form. After deleting these
buttons and boxes from the form, I find that the code is still there.
Does VB.net have a feature to clean up these unwanted codes?
thanks Tag: Get Rich Tag: 97057
'DisplayMember' is not a member of 'System.Windows.Forms.ListView'.
Hi,
I am trying to display the processes running on my system to a listbox. but
i got 'DisplayMember' is not a member of 'System.Windows.Forms.ListView'.
during debug.
any clues? below is the code
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button2.Click
Try
Dim prc As Process
' Remove existing items from the control.
ListView1.Items.Clear()
' Fill the control. Indicate which member of
' the items added to the list box should be
' displayed.
ListView1.DisplayMember = "ProcessName"
For Each prc In Process.GetProcesses()
ListView1.Items.Add(prc)
Next
ListView1.Sorted = True
Catch exp As Exception
MessageBox.Show(exp.Message, Me.Text)
End Try
End Sub Tag: Get Rich Tag: 97055
ToolStripStatusLabel blinking tooltips
Does anybody know how to get the blinking to stop. When I hover over the
ToolStripStatusLabel sometimes it blinks and sometimes it doesn't. So the
tooltips seem to behave inconsistently. The blinking is very annoying and
makes the tooltip unreadable.
And what does AutoToolTip property do.
The help says
"true to use the Text property for the ToolTip; otherwise, false. The
default is true. "
Umm what does that mean? Use the Text Property of the ToolStripStatusLabel
for the Tool Tip?
I tried both and true and false and it made no difference. It seems to
always display what I put in ToolTipText Property.
Any tips to get rid of blinking would be appreciated Tag: Get Rich Tag: 97054
Alternative .NET smart client bootstrapper - LagLoader.NET
Hi there.
In last January, My previous employer got a proof-of-concept project
requiring hand drawing on the web; the customer is a fashion design
house. I created a .NET Windows Forms control based smart client,
encapsulating Tablet PC InkPicture. It worked well (at least for demo)
on all my computers.
Since .NET framework runtime is a Windows Update optional install,
and in the impression that everybody should update their operating
systems often with Windows Update, before that project, I got a
wrong image that .NET framework runtime should be available easily
on every Windows XP PC. No, it is not that case. My customer is no
where close to IT industrial; they just made enough bucks, and their
younger new boss (whose university major was computer science)
decided to invest in a design workflow system. Even though every
designer of that customer got a Windows XP PC on each of their
desktops for long, and they do have a MIS group doing Windows
Update time from time, no .NET framework runtime was preinstalled;
they just not awared of that optional install.
We found no way to automatically install .NET framework runtime
in Windows XP machines of my supposed-to-be users, having to
install it one by one, MANUALLY. There were 20+ machines with
no .NET framework runtime preinstalled. Remember, this is a smart
client solution integrated with a back-end workflow web application
solution. It is suppose that no explicit install/setup files should be
run on every possible user's Windows.
Anyway, even though I have best performance over the category of
hand drawing/writting in all competitors, we failed to get that
customer to adopt my solution. .NET framework deployment is
really an issue. No, it should not be an issue.
It was already 1 year ago. Now, .NET 2.0 was released for weeks,
ClickOnce is out there, and I got the image that ClickOnce does
not support .NET 1.x smart clients. So I am still glad to share my
solution to every .NET smart client developer: LagLoader.NET 1.0.
Features of LagLoader.NET 1.0:
+ Detect if the required .NET framework version is installed.
Automatically download and install it if not installed.
+ No code modification is required in existed .NET Windows Forms
controls, only minor change in the OBJECT tags in web pages
needed. Javascript code worked in the same way to script
Windows Forms controls deployed in web pages.
+ In case that some smart clients are not compatible with the latest
version of .NET framework, they may be run fixed to a compatible
version of .NET framework, while others being run with the latest
version of .NET framework, all in the same web page.
+ An optional FULL TRUST mode to run Windows Forms control
based smart client fully trusted. Smart clients run as fully trusted
as their desktop/local peers, but loaded from remote servers.
Sure, the full trust mode may hint a security issue,
but if you have to do so to perform some tasks, then let it be.
The product web page of LagLoader.NET 1.0:
http://en.ezlag.com/site/335/lagloadernet.aspx Tag: Get Rich Tag: 97048
Opening, Closing, Launching Forms
I'm an experienced ASP.NET C# developer who's just beginning to develop
applications in Windows Forms and I would appreciate some references to
online material on the above topics. The information is not as prevalent as
I would have expected (or maybe I'm searching the wrong topic.)
Basically, I'm looking for everything you need to know to launch a Windows
Forms application using the static Main() method, how to shut the
applications down properly, and specifically how to shut down applications
using COM Interop and ActiveX controls. In other words, when working with
classes that implement Systems.Windows.Forms.Form while interfacing to
unmanaged code, how do you determine at which class level you need to call
Dispose() or do you just call it on the Control, the Container and the Form?
--
Regards,
Fred Chateau
fchateauAtComcastDotNet Tag: Get Rich Tag: 97046
Project Data Source Using Derived Interface
I've created a project data source based on an interface that in turn derives
from another interface. When in Visual Studio Data Sources view I examine the
properties exposed by the data source, I see only those properties in the
derived interface and none from the base interface.
A data source created from a class that implements the derived interface
exposes properties from both the derived interface and the base interface.
Is it possible to create a data source based on a derived interface that
also exposes properties from the base interface? At the moment the only work
around I see is to use a data source based on a class that implements the
derived interface. Since at runtime I may be displaying data from one of
several different classes that implement the interface, I'll be running the
risk of a runtime error if I happen to select at design time a property
exposed by the class I used as the data source type but that is not declared
in the interface.
Thank you,
Mike Tag: Get Rich Tag: 97039
multiple forms/common menu structure
I have project where I need multiple forms using a common menu structure
(like a web solution but with WinForms). Is there a best way to do it? I'm
currently trying inherited forms, but I'm not sure that's the best way as it
seems to present challenges. Tag: Get Rich Tag: 97038
DoubleClick Event Won't Fire
I have a form with labels that can be dragged and dropped onto
different regions of the form either individually or in groups. I
signify labels which have been selected by toggling the BorderStyle
between FixedSingle and Fixed3D. Upon a single click the toggle
occurs. Upon a double click I display a simulated tool tip (label)
containing more information about the label selected.
I am using the MouseDown event of the label and am using if conditions
to branch the single and double click logic using e.Clicks. When the
BorderStyle is changed (toggled) on every single click, the double
click will never fire.
I need to find a way around this without introducing a delay equal to
the DoubleClickTime.
I also thought I should post this so Microsoft can add it to their
patch list.
Thanks in advance for any advice you can provide.
Here is a sample of code that will reproduce this "feature".
Private Sub Pallet_MouseDown(ByVal sender As Object, ByVal e As
System.Windows.Forms.MouseEventArgs)
'// FYI - handler to this event added elsewhere in code
'// closes any open tool tip (not necessary to reproduce bug)
CloselblOverFlow_MouseDown(sender, e)
'// branches based on # of clicks (type check not necessary to
reproduce bug)
If e.Button = MouseButtons.Left And e.Clicks = 1 And
sender.GetType.Equals(GetType(PalletLabel)) Then
Dim lblPallet As PalletLabel = CType(sender, PalletLabel)
'// change BorderStyle of sender
If lblPallet.BorderStyle = BorderStyle.Fixed3D Then
lblPallet.BorderStyle = BorderStyle.FixedSingle
Else
lblPallet.BorderStyle = BorderStyle.Fixed3D
End If
'// iniate drag (not necessary to reproduce bug)
lblPallet.DoDragDrop(sender, DragDropEffects.Move)
ElseIf e.Button = MouseButtons.Left And e.Clicks = 2 Then
'// this code will never execute
Call ShowOverflow(CType(sender, Control))
End If
End Sub Tag: Get Rich Tag: 97036
Odd behavior with .NET 2.0 winforms
Maybe this is normal, but as I type in the code file, the designer tab
shows the little asterisk indicating the file has changed in the
designer as well.
Normally this wouldn't bother me, but in my case the designer files
(including the .licx and resx) are also tagged as changed and get
checked out of source control. I am not changing the form itself, only
the code behind.
Even more troubling is that occasionally when the designer tab is open,
but not active and I am editing the code behind, every letter i type
causes a delay as long as 2-3 seconds. Closing the designer resolves
the problem.
One more oddity is that one of my toolstrips visible property is often
changing to false in the designer!
I have a feeling it may be a third party library I am using
(DevExpress) but I am not sure where to start troubleshooting this. It
is not easily reproducible if I create a new project, but it is very
common is a specific project.
Can someone provide me with some guidance please? Tag: Get Rich Tag: 97033
Recommendations for graphical application
Hi,
I am at the early stages of defining the technology requirements for a
graphical, 2D Windows Forms application with display features along the
lines of MS Visio. It has a requirement to display it's data in a number of
tree or network like formations.
The "workspace" will take up the bulk of the UI space and must be able to
cope with large numbers of objects, connector lines, pictures, etc and allow
the user to scroll, zoom, drag and drop, select objects within their work
area. The number of objects that it needs to cater for runs into the
thousands. The same information then must be able to be transferred to
printed documents and various other image formats.
What graphics technology would people recommend to implement a system such
as this on .NET Framework 2.0?
I have investigated using GDI+ (although with Framework 1.1) but have found
that performance is too slow with large (virtual) workspaces, large numbers
of objects and zooming/scrolling/panning.
Due to this, I've started looking into the Managed DirectX extensions but
most of the information I have found relates to games development rather
than traditional Office like diagramming tools hosted in Windows Forms
application.
Any suggestions to approaches or sources of information would be greatly
appreciated.
Thanks,
Craig
Note: This is a repost due to previous post using incorrect reply address. Tag: Get Rich Tag: 97032
Blink datagrid cell when updated
I want to create a datagrid where the cell that is updated blink for 1
second. The datagrid is bound to a datatable.
I have tried deriving from the DataGridTextBoxColumn class and overload
the pait method. But how do I remove the color after 1 second. I have
tried with a second thread to reset the color, but with no luck.The
paint method also fire whenever something happens to the form/grid,
which then cause the application to run slowly.
If I handle the ColumnChanged event in the Datatable, would I be able
to find the current position for this element in the datagrid and then
set the color?
Thanx
/ps Tag: Get Rich Tag: 97030
Databinding between two forms in .NET 2.0
Hi,
I would like to data bind two different forms with each other. I would like
to have employees on the first form and orders on the second. When the
selected employee changes, the orders should change two. It is easy to do on
a single form where you can add a new bindsource which points to the
relation. But how can I do this across forms?
I have tried to do it manually where I am passing the BindingSource and the
DataSet, but then I cant use the designers.
What is the best way to do this?
Regards
Henrik Skak Pedersen. Tag: Get Rich Tag: 97029
Recommendations for graphical application
Hi,
I am at the early stages of defining the technology requirements for a
graphical, 2D Windows Forms application with display features along the
lines
of MS Visio. It has a requirement to display it's data in a number of tree
or
network like formations.
The "workspace" will take up the bulk of the UI space and must be able to
cope with large numbers of objects, connector lines, pictures, etc and allow
the user to scroll, zoom, drag and drop, select objects within their work
area. The number of objects that it needs to cater for runs into the
thousands. The same information then must be able to be transferred to
printed documents and various other image formats.
What graphics technology would people recommend to implement a system such
as this on .NET Framework 2.0?
I have investigated using GDI+ (although via Framework 1.1) but have found
that performance is too slow with large (virtual) workspaces, large numbers
of objects and zooming/scrolling/panning.
Due to this, I've started looking into the Managed DirectX extensions but
most of the information I have found relates to games development rather
than
traditional Office like diagramming tools hosted in Windows Forms
application.
Any help/thoughts/ideas on technologies or implementation approaches to
improve performance would be greatly appreciated.
Thanks,
Craig Tag: Get Rich Tag: 97027
Outlook Frame
Hi There,
Hope everyone is well? Im after a sample Application where the front screen
looks like the Outlook 2002 or 2003 screen, ie with the Frames etc.I would
like this to be free if Poss. Anybody got any Ideas?
Many Thanks
Si Tag: Get Rich Tag: 97022
WebBrowser control and postdata
Hi,
I'm having some trouble using the new WebBrowser control in .NET 2.0.
(System.Windows.Forms.WebBrowser)
I'm trying to use the Navigate method to post form data (in my case, a
login form)...
This is the code I'm using:
------------------------------------------------------------------------------------
string url = "http://mysite.com/login.php";
string userName = textBoxUserName.Text;
string password = textBoxPassword.Text;
string postData = "username=" +userName+ "&password=" +password;
byte[] postDataBytes = ASCIIEncoding.ASCII.GetBytes(postData);
string headers = "Content-Type: application/x-www-form-urlencoded" +
"\n" + "\r";
m_browser.Navigate(url, "", postDataBytes, header);
------------------------------------------------------------------------------------
Am I doing something wrong, or is the WebControl not working???
Thx in advance,
Gert Tag: Get Rich Tag: 97021
How to get the List Component Servcies installed in a machine using dotnet ?
Hi
I want to list the available "Component Services " (COM+) in a machine .
i am trying to get the list of Componenet services in a machine using
windows forms in dotnet , how can i retrive the list of componenet services,
i know we can get the list of windows services, but i dont know how to get
the list of Component services ?
can any one let me know how to do this ?
Thanks
Senthil Tag: Get Rich Tag: 97019
Excel => .NET...Grid, Chart
Hi
We have a lot of applications created in Excel, but now we want to move from
Excel to the .NET platform. The application will use grids and charts. What I
know the .NET controls are good basic ones, but not suitable in advanced
applications unless you create them yourself.
Can you recommend any good Grid and Chart controls on the market?
Regards
/Niklas Tag: Get Rich Tag: 97018
Combo box selected index
I have set a datasource to a combo box. COmbo box style is drop down list. I
am trying to set it's selcted index to 0 at run time bit it is throwing
following error :
An unhandled exception of type 'System.OutOfMemoryException' occurred in
system.windows.forms.dll
Additional information: Error creating window handle.
Pls help,
RbanBph Tag: Get Rich Tag: 97015
datetimepicker question
How to get the month or day of datetimepicker
e.g if day 1 it show 1, i want it to be 01
Moveover, can i change the datetimepicker into three combo box, one is day,
month, and year? Tag: Get Rich Tag: 97008
BindingSource - Detail view - Is Current record dirty?
In a Windows Form, I have a set of detail controls bound to a table in a
dataset through a BindingSource. I cannot figure out how to tell if the
user has edited any data in the controls that needs to be saved to the
database.
The EndEdit method will force any changes to update back to the dataset, but
how can you tell if any changes were made. Where is the IsDirty property?
In a DataGridView, there is a IsCurrentRowDirty flag that can be checked on
RowLeave, but I cannot find anything equivelant on the Detail view controls.
Thank you,
Alan Tag: Get Rich Tag: 97004
DBAccess in Winforms
Hi EveryOne,
What is the best approach for data access while developing applications
using Windows Forms ? Is it opening, working with and closing a new
SQLconnection and SQLcommand object everytime a DB access is needed , or
maintaining a single open connection/command object at the application level
( one for each user ) and then just reusing it again and again. The
connection string that the connection will use can be assumed to be static.
Thanks
--
Vedanshu Mandvikar Tag: Get Rich Tag: 96997
NullReferenceException in Windows.FormsUnsafeNativeMethods.CallWindowProc in .NET 1.1
I have a stack trace of a NullReferenceException and the only code in the
stack trace is from System.Window.Forms.
System.NullReferenceException: Object reference not set to an instance of an
object.
at System.Windows.Forms.UnsafeNativeMethods.CallWindowProc(IntPtr
wndProc, IntPtr hWnd, Int32 msg, IntPtr wParam, IntPtr lParam)
at System.Windows.Forms.NativeWindow.DefWndProc(Message& m)
at System.Windows.Forms.Control.DefWndProc(Message& m)
at System.Windows.Forms.Control.WmUpdateUIState(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.ParkingWindow.WndProc(Message& m)
at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg,
IntPtr wparam, IntPtr lparam)
Can someone tell me how this can happen? Also, how can a PInvoke method
such as CallWindowProc ever raise this exception? One of our employees ran
into this using Windows XP embedded in a production facility. I can't be
sure of what was happening exactly when this occurred. Such exceptions are
automatically sent to me via email when they occur.
Thanks,
Stan Tag: Get Rich Tag: 96996