|
I believe the only way you're are going to accomplish this would be to override the control's OnPaint method and draw your text.
|
|
|
|
|
By drawing it in the OnPaint method, I still have not figured out how to make the Graphics object the top most control.
|
|
|
|
|
You can't make the graphics object the top most control because it isn't a control. The graphics object is the representation of the control, or image, or print page, etc. The control is painted on the screen using the graphics object so in your case you would do something like
public void OnPaint(...)
{
base.OnPaint()
Graphics.DrawString(...)
}
Caution: Not actual working code.
|
|
|
|
|
Thank you so much for your help. Your explanation is helping me to better understand the problem. I now believe that it must be an ordering problem.
I have tried drawing the strings in the OnPaint method but the strings still appear behind the controls. I believe that the controls are being drawn after the onPaint method is called. I tried overriding the onPaint method exactly as you suggested (calling base.OnPaint() first and then Graphics.DrawString()) - however, the string is still painted behind the controls.
How can I ensure that my Graphic is drawn last on the control?
|
|
|
|
|
To anyone who has this same problem, I finally found a good solution. Please visit the following link:
http://www.codeproject.com/cs/miscctrl/SimpleLine.asp
|
|
|
|
|
Hi,
I installed the Enterprise Library January 2006 on my PC and it compiled and built the project. Now when I rebuild the solution, it still says to me that the date on the dll or of 2 days ago (the date when I installed Enterprise Library).
I'm referring to adding a reference to the Data Application Block dll. Why is it that when I add it to my bin folder in my Web Project using Add Reference, then it goes and adds about 6 files, namely:
Microsoft.Practices.EnterpriseLibrary.Common.dll
Microsoft.Practices.EnterpriseLibrary.Common.xml
Microsoft.Practices.EnterpriseLibrary.Data.dll
Microsoft.Practices.EnterpriseLibrary.Data.xml
Microsoft.Practices.ObjectBuilder.dll
Microsoft.Practices.ObjectBuilder.xml
I read at that I must add the following 2 DLL files:
Microsoft.Practices.EnterpriseLibrary.Common.dll and,
Microsoft.Practices.EnterpriseLibrary.Data.dll
When I check at the SDK of the PayPal Starter Kit, then the DAAB dll that they reference is called something like Microsoft.ApplicationBlocks.Data.dll.
Why is this?
Please can someone explain.
Regards,
ma se
|
|
|
|
|
...Common.dll is, well, for common pieces of the EntLib
...Data.dll is of course for the data access block (previously called Data Access Application Block, PayPal must be using an older version)
..ObjectBuilder.dll is used to create the objects necessary for the Data block
The xml files are the compiled documentation files and should not be included in your application
|
|
|
|
|
"previously called Data Access Application Block", what do you mean by this and what is it used for now?
So if I remove the xml files nothing will crash?
Are all 3 dll files required?
Have you got extensive knowledge about the new application blocks? Just curious.
|
|
|
|
|
|
I just want to ask something. I usually had my classes broken up into BLL classes and my DAL classes. Would I still make use of the DAL classes?? I'm assuming so because you would have different method calls, like GetOrders(), or GetCustomers(), and each method would do it own thing with the results returned.
|
|
|
|
|
Obsolutely. Your design doesn't change, you just use the EntLib in the DAL.
|
|
|
|
|
Hi Mark,
I just want to thank you in guiding me. I appreciate it. Once I know a bit more about the DAAB, then I want to start with the the other application blocks, lets say caching, exception and logging.
Take care!!
|
|
|
|
|
Dear All
How can I create Visual Studio Analyzer and incorporate wit Windos Management Instrument to filter widnows matadata
Sunil Sharan
Sunil
|
|
|
|
|
Hi Friends,
I am having an windows application created using C#. Its having a MDI form and many child forms. What i have to do is when i click a menu from the MDI window i get a form having a datagrid and many other calculations done and at the end of the page i have a print button. I want to print that entire page when i click the print button. I got a code from google but what it does is capture the screen and then prints. since it captures only what we can see in the screen i dont get the rest of the content which is visible only if i scroll down the window. i want the entire page to be printed.
Vipin
|
|
|
|
|
Look up PrintDocument. You will need to handle the events such as OnBeginPrint and OnPrintPage to format your data and print it to the printer.
|
|
|
|
|
can u please send me the code to print the entire form.
Vipin
|
|
|
|
|
Send me your specifications and I'll write the application for you.
You have to do some things on your own. Do a little research on the subjects I pointed out and if you have specific questions about something you don't understand or isn't working then ask, but don't ask to have someone do your work for you.
|
|
|
|
|
Mark Nischalke wrote: Send me your specifications and I'll write the application for you.
Now thats cool. I'll come back to ya next week when I have really lots of stuff to do...
|
|
|
|
|
...and the week after that I'll send you my bill.
|
|
|
|
|
|
You just cut off my revenue stream for the month. I was going to do the work for him
|
|
|
|
|
Hey!! No hard feelings partner.;)
|
|
|
|
|
Hello,
I'm not sure if this is the correct forum, but I will try my luck. So my problem is that when I want to build my PPC application I get the following error: "Invalid resx file".
After using Google for a while I found a solution which is using a tool called "regenresx". Unfortunately the link to the Microsoft download site doesn't work anymore.
So if somebody has this tool and could be so nice to send it to me (mail: Basti@shared-files.de), I would be very happy.
Thanks a lot
Regards Sebastian
|
|
|
|
|
I am not sure what is wrong with your resx file.
But MS supports generating resx files and there is a tool that comes along with the SDK.
If you have SDK installed it should be straight forward:
Check in your Program Files folder : Microsoft Visual Studio .NET 2003\SDK\v1.1\Samples\Tutorials\resourcesandlocalization\resxgen
|
|
|
|
|
Hi,
thanks for your fast answer. I converted a PPC project from VS 2003 to VS2005. As I read within different forums, the style of the resx file changed. I get the following error:
Invalid Resx file. Invalid Resx input. Valid resheader-Tags for reader and write type names could not be found.
To convert the old resx files there should be a tool called regenresx, but this is not available anymore.
Regards
Sebastian
P.S.: Couldn't find the proposed resxgen tool, maybe it is not included within .NET 2.0?
|
|
|
|