|
hi,
thank you.i got it.
sivamyneni
|
|
|
|
|
Hi Code project people,
can anyone help me out with how to page table control?
will be expecting your responses.
thanks in advance.
|
|
|
|
|
AFAIK you can't. Take a look at the DataGrid instead.
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
how can i open(visualize) a System.Windows.Forms.MenuItem of System.Windows.Forms.MainMenu by code?
jaye
|
|
|
|
|
if this menuItem has other menuItems under it you use the following statment
<br />
menuItem1.ShowDropDown();<br />
if it doesn't have you show use the above statment on its parent menu item
|
|
|
|
|
|
jaimeaye wrote: sorry but this metod (ShowDropDown) isn´t appear in my Visual Studio 2003 C#.
It can't. The ShowDropDown method is member of the ToolStripMenuItem class that is new in .NET Framework 2.0.
I think the classes in Framework 1.1 provide no support for what you're trying to achieve, so you're somehow at a loss.
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
I suggest you try MenuItem.PerformClick()
Luc Pattyn
|
|
|
|
|
|
jaimeaye wrote: with menuItem1.PerformClick(); you send a event of Click.
that's right, but if you do this on the parent menuItem it will do what you wish
cz the click event of the parent menu item is to open its drop down items.
for example if your have a File menu item and under it New.
if you like to view nuew you write:
fileMenuItem.PerformClick();
|
|
|
|
|
Did you tested this? I've tried and it doesn't work. Also the PerformSelect method doesn't show the menu.
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
Stefan Troschütz wrote: Did you tested this?
Sorry i didn't do that, but i assumed it will work.
anyway i will try to figure out another solution
|
|
|
|
|
quiteSmart wrote: Sorry i didn't do that, but i assumed it will work.
No need to apologize. I was just curious if it may work on other computers.
quiteSmart wrote: anyway i will try to figure out another solution
Maybe one could disassemble the ToolStripMenuItem and see what they are doing inside the ShowDropDown method. Or use Windows API to really simulate a mouse click on the menu item.
"Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning." - Rick Cook www.troschuetz.de
|
|
|
|
|
I need to develop an application, in C#.Net . I have two Touch panles connected to the system. My program have display different frames in different touch panels. Have anybody worked in such application? If so please tell me how to design it? How we can tell windows GDI to distinguish frames for different display?
Thanks
Bil
|
|
|
|
|
When you have a multi-monitor setup the two monitors are seen as one continuous area. e.g. You have two monitors of 1024x768 each. The screen will be 2048 pixels wide. 0-1023 is on one monitor and 1024-2047 is on the other. So, telling GDI which monitor to display something on is just a matter of drawing at the appropriate coordinates.
|
|
|
|
|
Thanks Colin for your reply.
Your answer gives me some idea what to do.
I have some more questions to ask you.
Do we need to tell the windows that we are using 2 monitors. If so where we need to configure it?
If I am creating an application I have to create in such a way that it will cover up the the 2 monitors? Do c# allows to do so?
Is there any way we can configure GDI?
Thanks and Regards
Binil
|
|
|
|
|
Hi,
I once had a two-monitor system, and did some .NET work on it.
I remember you could move the relative positions of the monitors, and you could set both
monitors to different settings (e.g. bits per pixel).
So when shifted by 384 for instance, having two 1024*768 monitors could result in a desktop 2048 wide and 1152 high, with two rectangles of 1024*384 invisible.
You can extend a form to use whole or part of both monitors, simply drag as usual.
You dont have to tell GDI, just use the coordinates of this "extended desktop".
I think I also recall a form will maximize on the monitor that shows its top lefthand corner.
One of the monitors is the "primary monitor", you can choose which one.
The primary monitor is the one that displays boot progress, and shows the task bar.
FYI: programs such as screensavers most often ignore all but the primary monitor;
they should however handle all monitors, either with one big picture, or with multiple
pictures.
Hope this helps,
Luc Pattyn
|
|
|
|
|
Thanks for your reply Luc.
My requirement is little bit different. I have two touch panles in which I need to show two different frames. User can control the system from both the touch panels.
So an action in a touch panel is expected to reflect on the same touch panel only. It means there are logicaly 2 users using a same application.
Is there any way to design such a user interface program.
Thanks
Bil
|
|
|
|
|
Well, I guess there are many possibilities:
1. run two apps, each using part of the extended desktop, each part corresponding to
one touch panel.
2.run a single app that shows two modeless forms, one on each tp
3.run a single app that has a single borderless form encompassing both tp, and two
Panels, one for each tp.
The third one seems the easiest, whatever you choose you must dispatch input events
to the right app/form/panel, but that is not a GDI issue. GDI is taking care of the
graphical output.
I am not familiar with the touch side of touch panels, I expect it should behave much
like a mouse, with mouse down events etc.
I would go for 3. and create a TouchPanel class that extends from Panel and holds
whatever specific functionality you want to give it, including the touch event stuff.
If you know how to handle one touchpanel, the above should be sufficient to deal
with two of them.
Luc Pattyn
|
|
|
|
|
Thanks Luc.
That gives me better idea. Do we need any extra configuration in the GDI or display level , so that the display will be properly taken care and routed to different monitors. Do we need to write a display driver for it? Does windos XP embedded supports it?
Thanks
Bil
|
|
|
|
|
Hi,
I dont know the answers to those questions; I am unfamiliar with WinXP embedded.
Two thoughts:
- the people selling you the touchpanels should take care of whatever is required to
interface it properly to the Windows version you choose; and it must be in such a way
that it works under GDI+. (Remark: GDI+ is technology outside .NET, it started of as GDI,
.NET simply offers a wrapper on top of it).
If they dont offer this, it is the wrong vendor !
- you would also need confirmation that the multi-monitor behavior that I described
before (and applied to WinXP) also applies to your Windows version. This is primarily
a Windows matter, but then there is a posibility your touchpanel's driver might be incapable
of handling two panels or of running twice in parallel.
-- modified at 8:34 Tuesday 6th February, 2007
Luc Pattyn
|
|
|
|
|
Hi,
I wish to have the format of the date saved into my database as a short date format.
The MS Access DB field is configured for the datetime format.
Thanks,
Glen Harvy
|
|
|
|
|
You can't change the access database, or you don't want to ? How does this relate to the datetimepicker ?
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
The text and value fields are bound to the database and are being saved to the db in the long format ie including the time.
I just don't want the time portion saved in the database field.
-- modified at 9:21 Monday 5th February, 2007
I think this is the only way :-
this.dtpMailInDateRcd.Value = this.dtpMailInDateRcd.Value.Date;<br />
this.dtpMailInDate.Value = this.dtpMailInDate.Value.Date;<br />
this.dtpMailInRepliedDate.Value = this.dtpMailInRepliedDate.Value.Date;
before I save the data.
Glen Harvy
|
|
|
|
|
Hi,
I dont think even that might be a solution, since the value that you pass from your front-end is first parsed to the date format at the time of saving in the database. Hence, if the date format is "LONG" in your Access Database, then in that case, it will add time to the value passed from the front-end.
However, one solution could be that you change the format of the date (in the Design View) of the table to "mm/dd/yyyy" in the Format textBox in the General Tab and from the front -end you pass the value as
suggested by you in your previous thread.
this.dtpMailInDateRcd.Value = this.dtpMailInDateRcd.Value.Date;
This probably might help.
Thanking you in Advance
Regards
Pratik Shah
|
|
|
|