|
You can open a pdf window inside a winforms app using this[^] but I'm not sure that will help you if you want to use the information in you app that you have clicked on.
A better method would be to get an open source pdf library from sourceforge: here[^]
|
|
|
|
|
I have several of the open source libraries now available to me. I have looked at many of the examples, and there is an issue that I have not yet been able to resolve. Can you open the document in the Adobe Reader, but reference it's button click events through one of the other libraries??? I'm having a hard time figuring out how to identify it as an object of another library if the document is in the Adobe Reader. All of the examples are opening documents in their own adobe windows. I can't find a way to reference one in my Active X control....
Again, I'm new at this.
BTW, does anyone have a link that will give me a quick rundown of what I'm looking at exactly when i download a library... I'm looking at folders without a clue of what they mean (bin, debug, release)...and i'm not sure about what all of the implications are behind file extensions(.cs, .dll, .csproj, .sln). I was hoping to find a tutorial or something to put it all together. (I'm trying to learn Visual C# with a strong background in VBA for excel. This means i understand syntax and stuff like that alright, but i'm still having a hard time with the framework of it all.)
|
|
|
|
|
When you download a library these are the file types:
*.cs = c# file can be opened in notepad but opens as default in Visual Studio
*.csproj = a c# project file
*.sln = a solution file to be opened with Visual Studio which opens all the .cs and .csproj related to it.
*.dll = dynamic linked library. The compiled project.
release folder should contain the .dll or .exe which is the finished compiled project
debug is where Visual studio places compiled projects when they are being tested(debugged)
Sorry I don't have any more info on your problem. I've never had to do it before
|
|
|
|
|
using System;
using System.Drawing;
using System.Collections;
using System.Windows.Forms;
using System.IO;
using System.Data;
using System.Reflection;
using System.Data.Common;
......
static void Main()
{
Application.Run(new FormCerca());
string aPath1 = System.Windows.Forms.Application.ExecutablePath;
}
why do i get the COMPILE ERROR
'System.Windows.Forms.Application' does not contain a definition for 'ExecutablePath' ??
Thanks
|
|
|
|
|
IFDTCACT wrote: why do i get the COMPILE ERROR
'System.Windows.Forms.Application' does not contain a definition for 'ExecutablePath' ??
Er..... that would mostly be because System.Windows.Forms.Application does not contain a definition for ExecutablePath .
It does, however contain a definition for StartupPath , which may suit your needs.
BTW is your Intellisense not working?
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
|
Thanks.
And there was me thinking an MS compiler would get it right.
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
I just tried in on VS2005 and didn't have a problem:
using System.Windows.Forms;
.
.
.
Debug.WriteLine( Application.ExecutablePath );
Verify you have a reference to System.Windows.Forms.dll.
Try Cleaning the solution, then do a full rebuild of the project.
|
|
|
|
|
Thank You
I found the problem raises from the version of references
I referenced Old Compact Framework in tha project, taht was originally built on Version 1.1 .
SO the right way is to remap references..
thanks everyone
|
|
|
|
|
I am learning how to create WCL and have problem. I have created a custom ctlLabelTextbox control project and successfully built. I have created a test Form project in the same project solution. I have made the test Form project the startup project. The C# book I am using says that Visual Studio should automatically recognize that the Control project and create a new tab for the ctlLabelTextbox Component in the Toolbox containing the component. The Toolbox tab is not being created and the ctlLabelTextbox is not anywhere in the existing toolbox. Can someone help?
Thanks
|
|
|
|
|
Try doing a rebuild of your controls project
|
|
|
|
|
I have tried that but still nothing. Is the book correct in saying that studio should detect the the control or is there something I must do?
|
|
|
|
|
Yes it should detect your control, you might have missed something though, using the following steps worked fine for me
1. Create a new solution with a windows control library project
2. Add a windows application project to the solution
3. Build the solution
4. Open the designer for Form1 in the windows application project
5. Open the toolbox
6. There should be a new tab with the name of your controls project eg. WindowsControlLibrary1 Components
7. Under that tab there should be the user control that was created by default (UserControl1)
I have run into situations where this would stop working at random, if all else fails try creating a new solution
Oh and make sure to derive your control from System.Windows.Forms.Control, UserControl or another control and make your class public
|
|
|
|
|
I have tried that and it still doesn't work. I must have some quirk in my install.
I can get by with manually adding the control.
Thanks for your help.
|
|
|
|
|
I've tried to search the forums/articles for what I am looking for but was unable to find what I need. I am new to the site so if someone has a link to what I'm about to ask that would be great too.
As I am looking up OCR and other types of recognition I find that they go into great depth and complexity to account for the ever changing characters and/or images they will be trying to recognize. I need a very simple example of OCR as I only have 2 images that I will ever need to read.
Problem:
I have an old security system on our building in that when people come and go with their access card a message is displayed in the access programs status window. The window shows 1 of 2 images. A door open for exiting and a door closed for entering. Next to the picture is the name of the person. The problem is that this software does not log this information and after a set number of records the status window runs out of room and it is pushed off of the list.
What I need is to have some code that will scan the status window of this program which is always in the same place, recognize the icon and mark entering/exiting (the icon is always in the same place) and record the name that shows up next to it.
As stated in my introduction, most code I have found on this site goes into a lot of complexity or "neural networking". I think that based on the non-dynamic nature of my problem this would have to be easier to solve. Once I see an example of anything similar I can reconfigure it to my needs. I just don't know where to start.
Any help would be great and thank you all for your time.
|
|
|
|
|
Hi,
AFAIK you could get the text from any Control on any window by issuing some messages to that window; and you could get the image of the screen using Graphics.CopyFromScreen. Checking the color of one or a few pixels should be sufficient to decide which of two possible pictures is shown.
|
|
|
|
|
How do I determine the X/Y coords for use int he Graphics.CopyFromScreen?
|
|
|
|
|
Joorstard wrote: How do I determine the X/Y coords for use int he Graphics.CopyFromScreen?
Great question. How should I know, you can see the screen, I can't.
Would you dare copying the entire screen, see how that works out; then maybe reduce it to the
relevant part? Be adventurous, try a little experiment, instead of asking one question a week.
|
|
|
|
|
I'm sorry that your dad touching you when you were young has manifested itself today. Here is a website that can help you. http://www.notmyfamily.org/[^]
My prayers are with you.
|
|
|
|
|
If there is an onscreen output of the peoples names, there is most likely a data interface for logging, since the system has to store the names in order to bring them up.
There's probably a data port of some kind or a file system that can be scanned to get the information. An interface of some kind would be a better goal than trying to read the video output. The harder part might be if it's using some proprietary or obsolete data connection.
The true man wants two things: danger and play. For that reason he wants woman, as the most dangerous plaything.
|
|
|
|
|
Dear sir,
how can i generate phone ring sound? is it possible?? i am searching in google but i m not getting anything. do u have any idea.
i want to make a project to call pc to pc. whenever i press Call button ringing sound should come.
yogesh
|
|
|
|
|
Can't you just use the C:\WINDOWS\Media\ringin.wav file?
If it's copyrighted, just search around - there's plenty of free ones for mobile (cell) phone ringtones.
[Edit] There's one here[^] [/Edit]
DaveBTW, in software, hope and pray is not a viable strategy. (Luc Pattyn) Visual Basic is not used by normal people so we're not covering it here. (Uncyclopedia) Why are you using VB6? Do you hate yourself? (Christian Graus)
|
|
|
|
|
ok it is working but i dont want to play sound in any player. it should come automatically without use of any player.
yogesh
|
|
|
|
|
Be very careful.
I once programmed a 'ting' (just an imitation of a standard bell 0x07) in assembler, 2500 lines of code. What you are proposing is very complex, and C# is probably not the best language to use for it.
However, best of luck!
Henry Minute
Do not read medical books! You could die of a misprint. - Mark Twain
Girl: (staring) "Why do you need an icy cucumber?"
“I want to report a fraud. The government is lying to us all.”
|
|
|
|
|
Use the System.Media.SoundPlayer class. If I remember correctly, it will just play the sound from your application - and I think it has a PlayLoop (or something like that) method.
DaveBTW, in software, hope and pray is not a viable strategy. (Luc Pattyn) Visual Basic is not used by normal people so we're not covering it here. (Uncyclopedia) Why are you using VB6? Do you hate yourself? (Christian Graus)
|
|
|
|