|
Hi!
I am doing a windows desktop application. I have a tab control which is aligned on thr gith, meaning that the tabs for the tab pages are displayed on the right. It is working fine. But when I added the "Application.EnableVisualStyle();", the titles for the tabs are not displayed anymore. They will display again if the alignment is Top or Bottom. But I really need to place them on the right since that is what is required of me.
Help anyone?
Regards,
Aldrich
|
|
|
|
|
It's a bug. If you add .manifest file to any application, wich contains control with right tabs, you'll see the same picture sigh:
My english is bad. Please, correct my errors.
Best regards, Alexey.
|
|
|
|
|
aww.. ok. I guess I won't be able to use the XP style for my desktop application..
Thanks!
Your english isn't bad. It's very understandable. My English is not very good too, but as long as it is understandable, then I guess it's ok. Practice makes perfect! hehe!
Regards,
Aldrich
|
|
|
|
|
Aldrich Caw wrote: ok. I guess I won't be able to use the XP style for my desktop application..
Don't give up, you can draw tab text yourself.
My english is bad. Please, correct my errors.
Best regards, Alexey.
|
|
|
|
|
Ok. I'll try. Thanks! Wish me luck!
|
|
|
|
|
Can any body help me to get a detailed book on Microsoft content management server 2002?
i am very much in a need of that.
advanced ThanX
Ramesh.Kanjinghat
|
|
|
|
|
My project is .Net VC++.
I need to use functions defined in SetupDi.lib
I've added additional dependancies as "setupdi.lib"
but I still receive error as follows. How can I solve the problem??
Form1.obj : error LNK2001: unresolved external symbol "void * __stdcall SetupDiGetClassDevsA(struct _GUID const *,char const *,struct HWND__ *,unsigned long)" (?SetupDiGetClassDevsA@@$$J216YGPAXPBU_GUID@@PBDPAUHWND__@@K@Z)
My statement:
hDevInfo = SetupDiGetClassDevs(&GUID_DEVINTERFACE_VOLUME, NULL, NULL,DIGCF_DEVICEINTERFACE | DIGCF_PRESENT);
prototype of the function in MSDN:
HDEVINFO
SetupDiGetClassDevs(
IN LPGUID ClassGuid, OPTIONAL
IN PCTSTR Enumerator, OPTIONAL
IN HWND hwndParent, OPTIONAL
IN DWORD Flags
);
-- modified at 15:28 Wednesday 12th July, 2006
|
|
|
|
|
In the derived class of an interface class, the implementation of the interface method involves calling a function that specific to the derived class. How to invoke the function that declared in the child class whithout having error indicating unknown function???
For example, I receive error:
error C3861: 'Build_StationRecord': identifier not found, even with argument-dependent lookup
Build_StationRecord is a function has been defined ahead. It's a public function of the child class.
-- modified at 12:15 Wednesday 12th July, 2006
|
|
|
|
|
I couldn't get your question. Could you rephrase a bit, or maybe add some a littl code to show what you did?
Best,
Jun
|
|
|
|
|
I found solution for it..
I have list the function prototype of virtual function in derived class(.h) as public function, then implement it in derived class (.cpp) with scope of derived class name (classname: .
|
|
|
|
|
I have a control that is derived from the standard ComboBox. I have an override for the OnPaint method that paints a border, drop down arrow button, background, and foreground. The only problem is that something (some other event/subcontrol) is drawing a black text box with a large font over top of the text box region of the combo box control.
I am drawing a background in my OnPaint event, and it is being draw on top of. I can see that the background is drawn because there is a border around the text box region. My code looks like the following:
<br />
protected override void OnPaint(PaintEventArgs e)<br />
{<br />
base.OnPaint(e);<br />
<br />
DrawBorder();<br />
DrawBackground();<br />
DrawArrowButton();<br />
DrawForegroundText();<br />
}<br />
What am I missing here??? By the way, this control works just fine if the DropDownStyle is set to DropDownList, however I'm need it to work as a DropDown (being able to edit the text box).
--Ian;
|
|
|
|
|
In calling all of your painting functions, are you passing the Graphics object sent inside the PaintEventArgs or are you creating another one?? You should be passing the Graphics given to you by the PaintEventArgs.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Sorry for my simple example. Yes, I am passing the PaintEventArgs that is passed to the event. So the GC is being used to do all the painting.
--Ian;
|
|
|
|
|
That's why we always suggest Copy-'n-Paste the code instead of retyping it.
You said that this text is being painted OVER what your code painted?
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
I'm painting the background a green with a FillRectangle, and when it is displayed to the screen, I see a 2 or 3 pixel border of green surrounding a black text box region (that was not drawn by me). This is what I mean when I say that it was drawn over top of what I had drawn.
The sample class below does not contain all the code, however it will give you an idea of the problem. Just drop this class into your a project, compile, and drop it the ComboDraw control onto a form.
<br />
using System;<br />
using System.Collections.Generic;<br />
using System.Drawing;<br />
using System.Text;<br />
using System.Windows.Forms;<br />
<br />
namespace ComboTest<br />
{<br />
class ComboDraw : ComboBox<br />
{<br />
public ComboDraw()<br />
{<br />
DrawMode = DrawMode.OwnerDrawFixed;<br />
DropDownStyle = ComboBoxStyle.DropDown;<br />
FlatStyle = FlatStyle.Flat;<br />
SetStyle(ControlStyles.UserPaint, true);<br />
}<br />
<br />
protected override void OnPaint(PaintEventArgs e)<br />
{<br />
base.OnPaint(e);<br />
<br />
e.Graphics.FillRectangle(new SolidBrush(Color.Green), ClientRectangle);<br />
}<br />
}<br />
}<br />
--Ian;
-- modified at 9:19 Thursday 13th July, 2006
|
|
|
|
|
OK. I see what you're looking at.
You're seeing the TextBox being drawn by the underlying ComboBox class. The bad news is, as far as I can tell, you can't get rid of it and can't override it. It's completely hidden behind "private" everything.
I've also never had to custom draw the entire Combobox. I've only done the drop down list and that turned out to be pretty easy.
Why are you trying to custom paint the entire thing?
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Why? I ask myself that question all the time. The answer is the same old story of having all controls behave consistently to the color scheme that has been chosen. Sometimes you can't choose your battles, you just have to fight. I have a few more hacks to try in the meantime.
--Ian;
|
|
|
|
|
I have no idea how to get past this one. If it wasn't such a PITA composite control, it'd be real easy!
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Hi,
How can add a dropdown button in a Windows Application?
Regards,
Wasif Ehsan.
|
|
|
|
|
What do you mean by a dropdown button?
---
b { font-weight: normal; }
|
|
|
|
|
A dropdown button is a normal button with a separate section on the right (or left) side with an arrow image. When you click on the arrow, a little dropdown container pops open. The container can provide other options related to action performed by clicking the button.
:josh:
My WPF Blog[^]
|
|
|
|
|
The Infragistics NetAdvantage suite has the UltraDropDownButton control. Other than that, there's no dropdown button control in WinForms that I know of.
:josh:
My WPF Blog[^]
|
|
|
|
|
I am using Microsoft visual studio 2005
Now Bussiness objects provide 3 different kinds of merge modules....
1-> Crystal Report for .Net Framework 2.0 x86 Redistributable package(32 bit)
2-> Crystal Report for .Net Framework 2.0 IA 64 Redistributable package(64 bit)
3-> Crystal Report for .Net Framework 2.0 x64 Redistributable package(64 bit)
Now i am not able to figure out which modules will suite my application.
Can any one help me in figuring it out.
How to find wheather my .net framework is x86 (or) IA 64 (or) x64.
Thank U.
Jats
|
|
|
|
|
Hi,
I am hosting a browser control(framework 2.0) in a form of fixed size. Control is docked as fill in the win form.
The control navigates to some url and displays the web page. Now if the web page size exceeds the win form size scrollbars appears.
I want to calculate the complete height and width of control(complete scrollable height and width). Let me know how i can do it.
Note that i can do it using the HTMLDocument's scrollheight and scrollwidth properties but the problem is it returns correct values only when the height and width are specified. Correct values are not guaranteed through it.
Thanks,
Yash
|
|
|
|
|
Why can’t we use Exception class for handling all exceptions. Why do we use specific calsses like Arithmetic Exception, IOException etc...
Thanks
Simha
simha
|
|
|
|