|
AnthonyEllis wrote: But this seems at best a kludge.
Sometimes that just happens to be the only case.
"I really like comments where I don't have to answer stupid questions" - stfx
|
|
|
|
|
Hay Lo Guys,
Any ideas how can we update our database(sql) by editing the values (adding rows or editing existing data) from DataGridView in the Win form?
Thanks
Basit
|
|
|
|
|
Use the BindinNavigator component
|
|
|
|
|
Well, binding navigators requries a datasource and a datamember to work in case of the dataset. I am using the business object.
Is there a reason why binding navigator does not recognise the business objects?
|
|
|
|
|
I am developing a new Windows database application in VB 2005. To date I have been using the .NET version of Crystal Reports to provide reports for my applications. Rather than attaching these reports to the database directly I pass in a custom DataSet at runtime to give me more flexibility.
This has worked fine to deliver my reporting requirements but I have come across many issues mainly to do with the memory overhead and bugs in the crystal designer and viewer control.
As I am about to start a new application I have the option of using the Microsoft ReportViewer in local processing mode instead. From my initial reading to achieve the same thing as what I have done with crystal I would create a custom class to pass the data through at runtime.
I just wanted some advice as to whether I would get any benefits of using the Microsoft reporting control over the crystal one. Does it manage memory better, or at least allow me to recover memory, and does it have all the features of crystal?
Alternatively are there any better third party reporting tools for .NET that are better? After a quick search on google I found Report Sharp-Shooter by Perpetuum Software and Stimulsoft Reports.NET. Does anyone have any experience with any thrird party software and if so are there any significant benefits over those shipped with Studio?
Any advice from experience would be greatly appreciated.
Cheers
Jason
|
|
|
|
|
Have you found any others that might be good? I am in the same boat...
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
I have a DataSet called ‘exportDefsDataSet’, with two tables, ‘ExportDef’ and ‘ExportDefItem’. The data set contains a relation, ‘ExportDef_ExportDefItem’ that relates the two on ExportDefID. This represents a set of export definitions, and definition items within the export definition, i.e. one export definition has many items.
I have a form with two binding sources on it, ‘exportDefBindingSource’ and ‘exportDefItemBindingSource’. The DataSource of the ‘parent’ binding source is set to ‘exportDefsDataSet’ and the DataMember to ‘ExportDef’. The DataSource of the ‘child’ binding source is set to ‘exportDefBindingSource’, and the DataMember to the relation ‘ExportDef_ExportDefItem’.
I have a ComboBox bound to ‘exportDefBindingSource’ and a BindingNavigator and two textboxes bound to ‘exportDefItemBindingSource’. When I select an export definition in the combobox, I can navigate between the definition items for that definition, but chaos ensues, as often the selected definition disappears from the combo box, or the items for another definition appear in the textboxes. I am battling to reliably preproduce this behaviour, as often the setup works correctly, and after after a seemingly random number of navigations does everything go bad.
Let me describe a typical scenario:
I start the application, and the first definition, “Access Accounting” is automatically selected, and the BindingNavigator correctly navigates between the items for “Access Accounting”. The next definition is “AccpPac DOS”, and if I select it, the correct items for “AccPac DOS” are available, BUT, “Access Accounting” is no longer visible in the ComboBox! Now there are two “AccPac DOS” entries, and the first one of them selects the items for “Access Accounting”. Now I select a third option, “AMS”, and get the AMS items, but now I have two AMS entries, and the first one still points to the “Access Accounting” items. The ComboBox is thouroughly out of sync, but I can’t find why.
I do not believe they are right who say that the defects of famous men should be ignored. I think it is better that we should know them. Then, though we are conscious of having faults as glaring as theirs, we can believe that that is no hindrance to our achieving also something of their virtues. - W. Somerset Maugham
My New Blog
|
|
|
|
|
Hey, i am trying to make a windows32 API application which clicks a button in
a TAdvListView class.
the problem is that TAdvListView seems to be borland API...
everything within the list got the same handle, ex:text,buttons, etc...
any clue how to access that button and send a click to it?
thanks
|
|
|
|
|
Hi Guys,
I have some problem setting up Icon to Form in Visual Basic.It throwing Invalid Picture as Error Message.
File name is 123.ico dimension 16 X 16
Pleae clarify it
Regards
Subash
Subash
|
|
|
|
|
Have you tried with other icons? 123.ico may be damaged in some way.
Virtual1ty "Any fool can learn from his own mistakes, but a wise man learns from mistakes of others"
|
|
|
|
|
searching for a way to 1. build a word finder(C# .net 2002), and 2. incorporate it into a windows application to navigate quickly to a word or phrase within a list box which contains a large collection.
gil
|
|
|
|
|
There are many ways, but your post is rather vague.
"Real programmers just throw a bunch of 1s and 0s at the computer to see what sticks" - Pete O'Hanlon
|
|
|
|
|
hi, can i click a button in a child window once i get the button's Handle?
i don't want to use SetCursorPos() combined with mouse_event() to click on a button cause i don't want the Mouse cursor to move/change position.
thanks
|
|
|
|
|
If you only have the handle to the button, you would have to use SendMessage[^] to send a BM_CLICK[^] message. This[^] describes how to use SendMessage in C#.
If you have the actual .Net Button object, you can use the PerformClick[^] method.
Take care,
Tom
-----------------------------------------------
Check out my blog at http://tjoe.wordpress.com
|
|
|
|
|
Thanks for help buddy,
it really helped
your reply was quick too.
thanks again Tom.
|
|
|
|
|
I am working on an application that must respond to a combination of keys, no matter which application the user is currently using, and that must know what is the application where the user was. I am using for this a keyboard hook, like in the article http://www.codeproject.com/csharp/globalhook.asp
The problem is that after responding to the hook, the only way I can think of to find out which application the user was using is to call GetTopWindow() and then find out the process to which the window belongs. The code returns always "ctfmon.exe". I don't know if this happens because the hook is triggered by ctfmon; in this case, how can I find out which application the user was in?
Can anybody help me?
See the code below:
<br />
[DllImport("user32.dll")]<br />
static extern IntPtr GetTopWindow(IntPtr hWnd);<br />
[DllImport("user32.dll", SetLastError = true)]<br />
public static extern uint GetWindowThreadProcessId(IntPtr hwnd, out uint lpdwProcessId);<br />
<br />
void FindWindow()<br />
{<br />
string processName = "Unknown";<br />
<br />
IntPtr pTopWindow = GetTopWindow(IntPtr.Zero);<br />
<br />
uint processId;<br />
if (GetWindowThreadProcessId(pTopWindow, out processId) != 0)<br />
{<br />
Process runningProc = Process.GetProcessById((int)processId);<br />
processName = runningProc.ProcessName;<br />
}<br />
<br />
processNameLabel.Text = processName;<br />
}<br />
Thanks a lot,
Alex
|
|
|
|
|
Try calling GetForegroundWindow instead.
|
|
|
|
|
Hi,
I'm just moving from MFC to .NET. In MFC, I can easily intercept any message with PreTranslateMessage and do whatever i want with a particular msg. This is especially useful if a user presses the Escape button in a dialog. before all input is gone, i can ask the user if he/she really wants to proceed and discard all input. Should be no problem in .NET neither, i thought. But either it'S so obvious i just can't see it or it's not so easy after all(which would be a surprise since this is a frequently occurring scenario). What i do in respect to the Escape Button: it's assigned the DialogResult.Cancel value and the containing form sets this button's variable name as CancelButton.
Any suggestions from someone?
Thank's in advance!
Wolfgang Puelm
|
|
|
|
|
When you drop a button on the form, you can then set the CancelButton property of your form to that button. It means that when escape is pressed the event handler of that button will be invoked. The dialogresult for that button will be set to Cancel.
|
|
|
|
|
Hi,
thank you very much for your propmpt answer!
But I'm afraid that's not my problem since the default event handler gives me no chance to remove this event (ESC pressed) from the form's message processing queue. That means the dialog will be inevitably be closed and that's what i'm trying to prevent if desired by user input. If this handler had a KeyEventArgs parameter instead of a EventArgs, the KeyEventArgs.Handled property could be set to true which might do the job (if it's passed by reference). Unfortunately, the event handler is implemented as it is.
Once again, thank you for your effort!
Regards
Wolfgang Puelm
|
|
|
|
|
For this I would normally handle the FormClosing event. You'll then get the opportunity to find out why the form is closing by checking the DialogResult property. You should normally make the Cancel button, the Escape key, and the X button in the top-right corner all do the same thing.
If you really want to go down the PreTranslateMessage route, you can implement the IMessageFilter interface and use Application.AddMessageFilter to have the framework call your filter function for each message.
DoEvents : Generating unexpected recursion since 1991
|
|
|
|
|
Hi,
Thanks a lot for your answer!
It took me on the right track - at last:
The xxx_FormClosing event has a FormClosingEventArgs parameter. From the MSDN i found out that there is a CancelEventArgs param also. Since it's possible to cast the FormClosingEventArgs into a CancelEventArgs, the latter's Cancel property can be used: if set true, the dialog stays alive, other it get's closed!
Thank's again!
Regards.
Wolfgang Puelm
|
|
|
|
|
can anyone tell me how I can create a new shell for windows xp embedded
I want complete detail regarding this i.e. how do we apporoach this problem, what are the basic skills required and which tools are helpful
|
|
|
|
|
sresth wrote: I want complete detail regarding this
So basically, you want somebody to code this up for you.
sresth wrote: how do we apporoach this problem, what are the basic skills required and which tools are helpful
If you can't answer these questions then this project is much too ambitious for you.
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
u can set any windows form as the startup shell with gpedit.msc
take a look at this article :http://www.codeproject.com/useritems/CF_kiosk_mode.asp
|
|
|
|