473,656 Members | 2,871 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Dll files

MAK
Hello everyone,
I know how to add images and icons etc to dll file.
What I would like to know is there is a way to add those icons on the forms
during the run time from the dll or to reference it to the dll during the
design time, then when I compile the project and install it, then all the
images still inside the dll file. not to be installed into winnet, or system
or system32 or any directory,
1) is it possible ? and how ? link or examples
2)do I need to open the dll file and save it as a resource then add it to my
project ?
3)add it as *.res file or what?

Any help will be appreciated , I'm using VB5 or VB6 o/s XP.

MAK
Jul 17 '05 #1
7 5629
Are you looking for a way to insert your own icons into a created .dll file
-OR-
are you trying to have several images/icons available to your program during
execution
-OR-
are you just trying to have a nice little icon in the top left of each form
(on the title bar)
?

The second and third are easy, the first one I don't have clue about.
Please elaborate.

Tom

"MAK" <Ma********@com cast.net> wrote in message
news:7p******** ************@co mcast.com...
Hello everyone,
I know how to add images and icons etc to dll file.
What I would like to know is there is a way to add those icons on the forms during the run time from the dll or to reference it to the dll during the
design time, then when I compile the project and install it, then all the
images still inside the dll file. not to be installed into winnet, or system or system32 or any directory,
1) is it possible ? and how ? link or examples
2)do I need to open the dll file and save it as a resource then add it to my project ?
3)add it as *.res file or what?

Any help will be appreciated , I'm using VB5 or VB6 o/s XP.

MAK

Jul 17 '05 #2
MAK
Thanks Kiteman,
The second option what I'm looking for the first and last I can mange them.
Would you have an example or code or link to explore such methodology?

Thanks

"Kiteman (Canada)" <NO************ @shaw.ca> wrote in message
news:odayb.5267 77$9l5.77702@pd 7tw2no...
Are you looking for a way to insert your own icons into a created .dll file -OR-
are you trying to have several images/icons available to your program during execution
-OR-
are you just trying to have a nice little icon in the top left of each form (on the title bar)
?

The second and third are easy, the first one I don't have clue about.
Please elaborate.

Tom

"MAK" <Ma********@com cast.net> wrote in message
news:7p******** ************@co mcast.com...
Hello everyone,
I know how to add images and icons etc to dll file.
What I would like to know is there is a way to add those icons on the forms
during the run time from the dll or to reference it to the dll during the design time, then when I compile the project and install it, then all the images still inside the dll file. not to be installed into winnet, or

system
or system32 or any directory,
1) is it possible ? and how ? link or examples
2)do I need to open the dll file and save it as a resource then add it

to my
project ?
3)add it as *.res file or what?

Any help will be appreciated , I'm using VB5 or VB6 o/s XP.

MAK


Jul 17 '05 #3
Hello Mak.

If you create a number of image controls at design time and place the
graphics in them, the images are saved within the executable. You can set
the Visible property to False at design time and have them appear by
changing this property during run time. You can hold bmp, jpg, gif, ico,
and wmf files within the Image control.

You could alternately create a big non-displaying form as a placeholder for
all your graphics and just have the required picture copy to your displayed
form upon code request.

eg.
frmMain.Image1. Picture = frmPlaceHolder. Image7.Picture

would have your Image1 control on your frmMain now contain the contents of
the Image7 control on your non-displaying frmPlaceHolder form. Remember
that you can add code to adjust Stretch, Placement and Size.

Is this as much detail as you require?

Tom

"MAK" <Ma********@com cast.net> wrote in message
news:X7******** ************@co mcast.com...
Thanks Kiteman,
The second option what I'm looking for the first and last I can mange them. Would you have an example or code or link to explore such methodology?

Thanks

"Kiteman (Canada)" <NO************ @shaw.ca> wrote in message
news:odayb.5267 77$9l5.77702@pd 7tw2no...
Are you looking for a way to insert your own icons into a created .dll

file
-OR-
are you trying to have several images/icons available to your program

during
execution
-OR-
are you just trying to have a nice little icon in the top left of each

form
(on the title bar)
?

The second and third are easy, the first one I don't have clue about.
Please elaborate.

Tom

"MAK" <Ma********@com cast.net> wrote in message
news:7p******** ************@co mcast.com...
Hello everyone,
I know how to add images and icons etc to dll file.
What I would like to know is there is a way to add those icons on the

forms
during the run time from the dll or to reference it to the dll during the design time, then when I compile the project and install it, then all the images still inside the dll file. not to be installed into winnet, or

system
or system32 or any directory,
1) is it possible ? and how ? link or examples
2)do I need to open the dll file and save it as a resource then add it

to

Jul 17 '05 #4
MAK
Hello Tom,
First Thanks a lot for your quick answers, and help , I deeply appreciated.
Second, I failed to say in my first post "any images", animated or not
animated and icons.

During the development of such project, forms some images which I used are
imbedded by ocx to place them on the form. Once project completed. and,
During packaging and create the installation setup.exe it will gather all
the images, and as you know I have the choice to change the insulation
directory during creating such package, and cab file.

As you know, during the installation on another machine such images must be
added back to the same exact reference directory which were chosen during
the packaging, if I delete them or move them from the referenced directory
the project still working but without the animation on such form.

This is the reason why I'm asking about using "a dynamic link library(Dll)
along with my setup.exe to be used for my images to avoid user from deleting
such images. I used this methodology with AutoCAD and successfully used the
dll with the AutoCAD tool bar menu, it was easy for me because I writ lisp/
dcl routine for AutoCAD. But not easy in this stage as implementation to do
it in VB for this portion I'm looking for help.

Sorry for my bad second language, I did not mean mislead you, but my be you
will find a link or tutorial which may lead to a resolution. I'm sure it is
there I'm still looking. Also if you come across any thing to allow encrypt
*.mdb file and decrypt, will be great... appreciated.

MAK

"Kiteman (Canada)" <NO************ @shaw.ca> wrote in message
news:otfyb.5233 06$6C4.323108@p d7tw1no...
Hello Mak.

If you create a number of image controls at design time and place the
graphics in them, the images are saved within the executable. You can set the Visible property to False at design time and have them appear by
changing this property during run time. You can hold bmp, jpg, gif, ico,
and wmf files within the Image control.

You could alternately create a big non-displaying form as a placeholder for all your graphics and just have the required picture copy to your displayed form upon code request.

eg.
frmMain.Image1. Picture = frmPlaceHolder. Image7.Picture

would have your Image1 control on your frmMain now contain the contents of
the Image7 control on your non-displaying frmPlaceHolder form. Remember
that you can add code to adjust Stretch, Placement and Size.

Is this as much detail as you require?

Tom

"MAK" <Ma********@com cast.net> wrote in message
news:X7******** ************@co mcast.com...
Thanks Kiteman,
The second option what I'm looking for the first and last I can mange

them.
Would you have an example or code or link to explore such methodology?

Thanks

"Kiteman (Canada)" <NO************ @shaw.ca> wrote in message
news:odayb.5267 77$9l5.77702@pd 7tw2no...
Are you looking for a way to insert your own icons into a created .dll

file
-OR-
are you trying to have several images/icons available to your program

during
execution
-OR-
are you just trying to have a nice little icon in the top left of each

form
(on the title bar)
?

The second and third are easy, the first one I don't have clue about.
Please elaborate.

Tom

"MAK" <Ma********@com cast.net> wrote in message
news:7p******** ************@co mcast.com...
> Hello everyone,
> I know how to add images and icons etc to dll file.
> What I would like to know is there is a way to add those icons on the forms
> during the run time from the dll or to reference it to the dll during
the
> design time, then when I compile the project and install it, then
all the
> images still inside the dll file. not to be installed into winnet,
or system
> or system32 or any directory,
> 1) is it possible ? and how ? link or examples
> 2)do I need to open the dll file and save it as a resource then add

it to


Jul 17 '05 #5
My experience with Image controls is that if I place a picture within one,
the control AND its contents are saved within the executable. I have
written a program that has 22 separate forms and any graphic elements
(mostly just .jpg and .wmf files) are fully containted within the single
..exe file. I have also placed .wmf files within the Picture property of a
form (not inside an Image control) and it is also saved within the
executable.

My program in question can be found at
http://members.shaw.ca/kiteman/Downloads.htm
It is the NPW9b Vulture Calculator program. It gives all the steps in
making a (size of your choice) traction kite.

I have never used animated gifs or .avi files so I don't know how they are
handled. If you need to supply your graphics as separate files then you
can place them within the same folder as your .exe and load them with the
App.Path & filename string. I used to require that my end user keep
database files in a specified directory, but since learning about App.Path I
just put everything within the same folder as the .exe and everthing gets
found just nicely.

For Example:

intFileNo = FreeFile
Open App.Path & "\NPW9bStartup. ini" For Input As #intFileNo
' Read in the .ini file contents etc.
Close #intFileNo

This is about as far as I can help with my limited knowledge of VB.

Tom
Hello Tom,
First Thanks a lot for your quick answers, and help , I deeply appreciated. Second, I failed to say in my first post "any images", animated or not
animated and icons.

During the development of such project, forms some images which I used are imbedded by ocx to place them on the form. Once project completed. and,
During packaging and create the installation setup.exe it will gather all
the images, and as you know I have the choice to change the insulation
directory during creating such package, and cab file.

As you know, during the installation on another machine such images must be added back to the same exact reference directory which were chosen during
the packaging, if I delete them or move them from the referenced directory
the project still working but without the animation on such form.
Sorry for my bad second language, I did not mean mislead you, but my be you will find a link or tutorial which may lead to a resolution. I'm sure it is there I'm still looking. Also if you come across any thing to allow encrypt *.mdb file and decrypt, will be great... appreciated.

MAK

"Kiteman (Canada)" <NO************ @shaw.ca> wrote in message
news:otfyb.5233 06$6C4.323108@p d7tw1no...
Hello Mak.

If you create a number of image controls at design time and place the
graphics in them, the images are saved within the executable. You can

set
the Visible property to False at design time and have them appear by
changing this property during run time. You can hold bmp, jpg, gif, ico, and wmf files within the Image control.

You could alternately create a big non-displaying form as a placeholder

for
all your graphics and just have the required picture copy to your

displayed
form upon code request.

eg.
frmMain.Image1. Picture = frmPlaceHolder. Image7.Picture

would have your Image1 control on your frmMain now contain the contents of the Image7 control on your non-displaying frmPlaceHolder form. Remember that you can add code to adjust Stretch, Placement and Size.

Is this as much detail as you require?

Tom

Jul 17 '05 #6
MAK
Tom, nice site can I down load and use the calculator ?

Your information and experience is 100% correct, however based on the two
controls I have for animation, I have to have the path name, directory name,
and file name correct as well as the animated images reside into the
directory if I remove such images I will get blank form with other static
images such icons Jpg, gif , or any control,etc as non animated files. I saw
early your email while I was at work, and I tested my project on three
different computer with the same results No No.

Beside the above, and if I'm not mistaken that The advantage of DLL files is
that, because they don't get loaded into random access memory (RAM) together
with the main program, space is saved in RAM. When and if a DLL file is
needed, then it is loaded and run.
For example, as long as a user of Microsoft Word is editing a document, the
printer DLL file does not need to be loaded into RAM. If the user decides to
print the document, then the Word application causes the printer DLL file to
be loaded and run. When I used this method in AutoCAD I did not have any
smiley faces on my icons any more because I have them all in *.Dll

So , I want to take advantage of such technology for my application, if I
find a way out and how to declare it.

Again thanks for your post. in return if you need a flash or animation logo
to your site I will be happy to help you at no cost.

MAK

"Kiteman (Canada)" <NO************ @shaw.ca> wrote in message
news:X0qyb.5293 10$pl3.472335@p d7tw3no...
My experience with Image controls is that if I place a picture within one,
the control AND its contents are saved within the executable. I have
written a program that has 22 separate forms and any graphic elements
(mostly just .jpg and .wmf files) are fully containted within the single
.exe file. I have also placed .wmf files within the Picture property of a form (not inside an Image control) and it is also saved within the
executable.

My program in question can be found at
http://members.shaw.ca/kiteman/Downloads.htm
It is the NPW9b Vulture Calculator program. It gives all the steps in
making a (size of your choice) traction kite.

I have never used animated gifs or .avi files so I don't know how they are
handled. If you need to supply your graphics as separate files then you
can place them within the same folder as your .exe and load them with the
App.Path & filename string. I used to require that my end user keep
database files in a specified directory, but since learning about App.Path I just put everything within the same folder as the .exe and everthing gets
found just nicely.

For Example:

intFileNo = FreeFile
Open App.Path & "\NPW9bStartup. ini" For Input As #intFileNo
' Read in the .ini file contents etc.
Close #intFileNo

This is about as far as I can help with my limited knowledge of VB.

Tom
Hello Tom,
First Thanks a lot for your quick answers, and help , I deeply appreciated.
Second, I failed to say in my first post "any images", animated or not
animated and icons.

During the development of such project, forms some images which I used

are
imbedded by ocx to place them on the form. Once project completed. and,
During packaging and create the installation setup.exe it will gather all
the images, and as you know I have the choice to change the insulation
directory during creating such package, and cab file.

As you know, during the installation on another machine such images must

be
added back to the same exact reference directory which were chosen during the packaging, if I delete them or move them from the referenced directory the project still working but without the animation on such form.
Sorry for my bad second language, I did not mean mislead you, but my be

you
will find a link or tutorial which may lead to a resolution. I'm sure it

is
there I'm still looking. Also if you come across any thing to allow

encrypt
*.mdb file and decrypt, will be great... appreciated.

MAK

"Kiteman (Canada)" <NO************ @shaw.ca> wrote in message
news:otfyb.5233 06$6C4.323108@p d7tw1no...
Hello Mak.

If you create a number of image controls at design time and place the
graphics in them, the images are saved within the executable. You
can set
the Visible property to False at design time and have them appear by
changing this property during run time. You can hold bmp, jpg, gif, ico, and wmf files within the Image control.

You could alternately create a big non-displaying form as a
placeholder for
all your graphics and just have the required picture copy to your

displayed
form upon code request.

eg.
frmMain.Image1. Picture = frmPlaceHolder. Image7.Picture

would have your Image1 control on your frmMain now contain the

contents of the Image7 control on your non-displaying frmPlaceHolder form. Remember that you can add code to adjust Stretch, Placement and Size.

Is this as much detail as you require?

Tom


Jul 17 '05 #7
Hello MAK.
Tom, nice site can I down load and use the calculator ?
It says free, so, ummm, I guess you can :-)
It's free for anyone. I hate going to sites that say it is a free download
but then they ask for money when you try to install or use the program.
Sure, the download was free, but the program isn't. In my case, it is
free, free, free. If you use the program to build a kite you are only
asked to send me a picture of the finished kite in flight.
Your information and experience is 100% correct, however based on the two
controls I have for animation, I have to have the path name, directory name, and file name correct as well as the animated images reside into the
directory if I remove such images I will get blank form with other static
images such icons Jpg, gif , or any control,etc as non animated files. I saw early your email while I was at work, and I tested my project on three
different computer with the same results No No.
Beside the above, and if I'm not mistaken that The advantage of DLL files is that, because they don't get loaded into random access memory (RAM) together with the main program, space is saved in RAM. When and if a DLL file is
needed, then it is loaded and run.
For example, as long as a user of Microsoft Word is editing a document, the printer DLL file does not need to be loaded into RAM. If the user decides to print the document, then the Word application causes the printer DLL file to be loaded and run. When I used this method in AutoCAD I did not have any
smiley faces on my icons any more because I have them all in *.Dll
I will have to defer to the great minds that contribute here. I am out of
my league now.

"Kiteman (Canada)"wrote in message..
My program in question can be found at
http://members.shaw.ca/kiteman/Downloads.htm
It is the NPW9b Vulture Calculator program. It gives all the steps in
making a (size of your choice) traction kite.

I have never used animated gifs or .avi files so I don't know how they are handled. If you need to supply your graphics as separate files then you can place them within the same folder as your .exe and load them with the App.Path & filename string. I used to require that my end user keep
database files in a specified directory, but since learning about App.Path
I
just put everything within the same folder as the .exe and everthing

gets found just nicely.

Jul 17 '05 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
14159
by: Mike | last post by:
I am sure that I am making a simple boneheaded mistake and I would appreciate your help in spotting in. I have just installed apache_2.0.53-win32-x86-no_ssl.exe php-5.0.3-Win32.zip Smarty-2.6.7.tar.gz on a system running WindowsXP SP2. Apache and PHP tested out fine. After adding Smarty, I ran the following http://localhost/testphp.php
44
4031
by: Xah Lee | last post by:
here's a large exercise that uses what we built before. suppose you have tens of thousands of files in various directories. Some of these files are identical, but you don't know which ones are identical with which. Write a program that prints out which file are redundant copies. Here's the spec. -------------------------- The program is to be used on the command line. Its arguments are one or
0
6117
by: Tom Lee | last post by:
Hi, I'm new to .NET 2003 compiler. When I tried to compile my program using DEBUG mode, I got the following errors in the C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7 \include\xdebug file as folows. I need help to resolve them ASAP: cl /c /nologo /MDd /W3 /Od /GR /GM /Zi /GX /D "_DEBUG" /D " WIN32" /D "_W INDOWS" /D "_WINDLL" /D "_AFXDLL" /D "_MBCS" /D "_USRDLL" /
18
3166
by: JKop | last post by:
Here's what I know so far: You have a C++ project. You have source files in it. When you go to compile it, first thing the preprocessor sticks the header files into each source file. So now you have your ".cpp" files all ready, without any "#include" or "#define" in them. Let's assume that there's 2 source files in this project, "a.cpp" and
3
3087
by: pooja | last post by:
Suppose i have created a class c1 with f1()in c1.cpp and included this c1.cpp in file1.cpp file , which is also having main() by giving the statement #include "c1.cpp". the same i can do by using header file. i can create a class c1 with f1() in c1.h and include this c1.h in file1.cpp by giving the statement #include "c1.h" tell me that what exactly is the difference between c1.h and c1.cpp? Since they both are doing the same things.
11
5573
by: ambika | last post by:
Iam just trying to know "c". And I have a small doubt about these header files. The header files just contain the declaration part...Where is the definition for these declarations written??And how does that get linked to our program when we run it??I would appreciate any helpful info..And I would like to thank you for that in advance -ambika
22
3001
by: Daniel Billingsley | last post by:
Ok, I wanted to ask this separate from nospam's ridiculous thread in hopes it could get some honest attention. VB6 had a some simple and fast mechanisms for retrieving values from basic text files, which in turn could be simply and easily maintained with notepad. I understand the benefits of XML, really, but in the case of configuration files it seems it is almost always nothing more than unnecessary complexity, both in accessing them...
18
2291
by: UJ | last post by:
Folks, We provide custom content for our customers. Currently we put the files on our server and people have a program we provide that will download the files. These files are usually SWF, HTML or JPG files. The problem as I see it - if you know the name of the file, you could download it off the server (currently we are using an HTTP/Get but I'm going to be using WebClient in the new version.) If there any way to password protect the...
0
1507
by: wal | last post by:
How does one attach files to emails using libgmail? The following code http://pramode.net/articles/lfy/fuse/4.txt works fine when said files are simple text files, but it failes as soon as the files are wild binary files, even attaching the source of an email in a text file (.eml files) failes. What am I missing here? Any hints? The output I get when attemting to send binary files using the code above is pasted below. have fun,
3
5176
by: aRTx | last post by:
I have try a couple of time but does not work for me My files everytime are sortet by NAME. I want to Sort my files by Date-desc. Can anyone help me to do it? The Script <? /* ORIGJINALI
0
8382
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8297
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8816
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8717
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8600
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6162
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4150
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2726
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1930
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.