|
hi...
how i can include help project files (.chm) in my application without need to install the application?
when i start my application (debug or release mode) the help files and folder doesn`t appear in my appplication (Debug\bin dir) folder. that way, i can't use the help files cause they are located in my root solution folder and not in my main application folder (Debug\bin).
i think the case is the same as a project that contains files not used directly by the application, like a image directory (in another project)not included in the resources, for instance.
thanks in advance... :]
|
|
|
|
|
You can use post build commands to copy files to your output directory. Under your project's properties, look for the "Build Events" there are text boxes in which you can enter commands to be executed upon completion of a successful build. I would just use a wild card xcopy to move all chm files, image directories, etc. to the ouput directory.
|
|
|
|
|
Thanks for your answer Jim.
It solved my problem.
|
|
|
|
|
I have been trying to find a way to check file security BEFORE attempting to access a file or folder.
Given the current user and a requested access method, I want to return true or false, whether the user has the given access or not.
With .NET 2.0 I was thinking that this would be provided, but apperently it is not.
Any help appreciated!
|
|
|
|
|
You might be able to put something together using the System.Security.Permissions.FileIOPermission[^] class.
Keep in mind, the best way to do this is to just try and open the file. The security checks are done for you, oddly enough - by this very class, at the time the attempt is made to open the file. So, you're not saving any time by doing this.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
hi, wise people
I'm not a great programmer, so hope you'll help me.
I need to create transparent(opaque!) control - like a panel with Opacity(0..100) property - which must be transparent not only visually, but also TRANSPARENT FOR MOUSE MOVES AND CLICKS.
Such control - of course is not a top-level window.
Such control - of course must not be under other controls on the window where it is put.
Visual C#, Studio 2005.
Windows 2000, XP or later.
If any ideas, you are welcome. I'll be very thankful.
-------------------------
lalala, I'm from Ukraine
|
|
|
|
|
try the control Visible property.
i think this works - if i have understood your trouble.
cya
|
|
|
|
|
you are a clever guy ) but I need much more - TRANSPARENCY! (OR OPACITY) - WITH CHANGEABLE POWER.
pardon me, I'm from Ukraine, so cant understand differency between transparency and opacity.
So, lets think - your post was just a joke.
----------------------------
lalala, I'm from Ukraine
|
|
|
|
|
Pardon me, shameless plug -> http://www.codeproject.com/vb/net/ClickThroughWindows.asp[^]
You can't make just a single control transparent to the mouse using this technique. It's the whole form, or nothing. Alpha-based mouse transparency doesn't work correctly, at least on 2000 and XP, it doesn't.
If you try to make just a control, like a panel transparent, then put it on a form that doesn't support transparency, it doesn't work. The click still works on the control itself. At best, it would fall to the form the control is on.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
|
RomkaFromUa wrote: I understand, you are a great programmer, but I'm also not just a user.
OK, smartass... I never said I was a "great programmer".
You better look up the definition of "opaque[^]". I can't tell what you want from your orignal description. Opaque and transparent are direct opposites of each other. Do you want a control you can see through? That's transparent. Can't see through it? That's opaque.
Which is it?
I posted the link to the article as a POSSIBLE guide to show you how to make an entire form pass through mouse moves and clicks. For you, it wasn't meant to be a guide to the WS_EX_LAYERED attribute.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
))
I see, that not just me dont know English well... cuz sometimes, in my Inet-searching experience, transparent windows meant to be fully transparent in some parts... and I want, as you understand
"Do you want a control you can see through?" - yessss )
+Thanks for terms description)
I'll reply concretely later.......
----------------------------
lalala, I'm from Ukraine
|
|
|
|
|
RomkaFromUa wrote: I see, that not just me dont know English well...
When you stop insulting people and just answer their questions, I'll take you off my blacklist...
You asked a question and, due to English not being your primary language, worded it using conflicting terminology. I THOUGHT I figured out what you wanted, but instead of clarifying, you decided to insult me. Have a nice life!
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Dave, you understood me in a wrong way!
I was talking about other people over Inet, that also dont know English well and so have made me not understand what is the difference between transparency and opacity!
I hope that this thought was written clearly for you and you'll not be angry for me...
People... he talked something about blacklist... if he dont hear me, please make him understand that I dont want to make him angry
Also I hope somebody will help me with my problem, but I begin to see that this problem is unsolveable
----------------------------
lalala, I'm from Ukraine
|
|
|
|
|
If you want the control to be absolutely transparent, you'll have to draw it yourself. Using the Color.Transparent color won't do what you want, apparently, since setting the BackColor of a control to Transparent only makes the background of the control take on the properties of the controls parent container. It's not truely "transparent". This means that any control under your control will NOT show through in the "transparent" regions of your control.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Hi its a pleasure to see you now.
I DONT want an absolete transparency. I need to control its level. Your last idea (setting BackColor) was tested in the older times, and as you said, it is not what I want (I need to see controls through)
Maybe, now everything is clear with my unperfect English )
But for this time I dont see any abilities to solve my problem
1) set BackColor to transparent value - not good, cuz dont see controls through
2) WS_EX_LAYERED - not good - it works on top-level windows, not child windows , and I need the last variant
3) Regions - also not good - they provide full transparency, not controllable.
Any other ideas - I'm waiting.
----------------------------
lalala, I'm from Ukraine
|
|
|
|
|
If you ned to click on those controls, go back and read my article. It explains what the process is to make the form "click-through" and you can still use transparency. There's even a sample application in it.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Dave, WS_EX_LAYERED does not work with child windows/controls!
----------------------------
lalala, I'm from Ukraine
|
|
|
|
|
No, it doesn't. You also cannot make just a single control click-through. It's the entire form, or nothing.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Ok, I'll try to ask for another variant - more simple.
TRANSPARENT FOR MOUSE MOVES AND CLICKS - dont pay attention to this feature for now.
Just - opaque control
----------------------------
lalala, I'm from Ukraine
|
|
|
|
|
My current C#.NET project is MDI-based.
I am using a user control that has 10 textboxes. This user control is repeated 20 times on a screen. (that gives 200 textboxes on the screen)
When I refresh the screen, I can see every textbox being drawn to the screen from top to bottom. The desired behaviour is that the screen should appear in a flash without any rollover effect.
Currently, the screen gets refreshed at a rate of 35 milliseconds. We need to minimize this to 2-3 milliseconds.
I found that When one textbox of the usercontrol refreshes, internally Paint Event of that control is raised.
The textbox Paint Event internally raises its container's (user control's) paint event.
Subsequently, the user control raises paint event of all textboxes in it.
So I tried to suppress raising the Paint Event of usercontrol when the textbox is refreshed. (by Override OnPaint and Override OnPaintBackground event).
Also, double buffering is used.
But this has not helped much.
Is there a way we can accomplish a refresh rate of < 5 milliseconds?
|
|
|
|
|
SwEr wrote: Is there a way we can accomplish a refresh rate of < 5 milliseconds?
Don't try to do so much in the painting. 200 textboxes is excessive - do you really need that many on screen at one time? A user can only use 1 at a time, and only look at a couple at a time.
|
|
|
|
|
I think you'll find the problem is that the background is painting over the textboxes before the textboxes are re-drawn.
You should be able to override the PaintBackground event of whatever contains the text boxes, and draw the background yourself without painting over the text boxes.
|
|
|
|
|
SwEr wrote: Currently, the screen gets refreshed at a rate of 35 milliseconds. We need to minimize this to 2-3 milliseconds.
With that level of refresh this window must be display only window (read-only). If that is the case using all those controls is just a bad idea. You might look into just painting that data or something.
led mike
|
|
|
|
|
Each user control, represents a device. The text boxes in the user control would display the devices' dynamic properties. There would be as many user controls as the number of devices. Right now i am assuming only 20, but in reality could be much more. I cannot replace the user controls with a datagrid as the number of properties to be displayed would be different for each device. The user control as such is rendered by the device library. All these user controls are placed in a form container. The entire data received from devices needs to be displayed on one screen (no tabs,etc) as the user needs to continuously monitor it.
Is it possible to handle this at a lower level? (like drawing the data into an off screen version of the Form and then copying it on screen in one shot).
Any thoughts?
|
|
|
|