473,320 Members | 1,856 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Errors installing a font using GDI

Hi

In my vb.net Installer class, I check the InstalledFontCollection for
myFont, if it isn't there I try to install it using the GDI function
AddFontResource.

I am getting the following error and don't know why:

"System.EntryPointNotFoundException: Unable to find an entry point named
AddFontResource in DLL gdi32.dll"

I am declaring the GDI function as follows

Private Declare Function AddFontResource Lib "gdi32.dll"
(<MarshalAs(UnmanagedType.LPWStr)> ByVal fileName As String) As Integer

and then calling it...

Me.AddFontResource(FileName)

What am I doing wrong anyone?
Jul 21 '05 #1
0 1371

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

Similar topics

3
by: Bruno G. | last post by:
Hello! Is it possible for IIS to send some sort of notification when an ASP error occurs on a page? I can see them in the web logs, but I was wondering if there was a way to receive an email...
2
by: Johan Mårtensson | last post by:
Hi I was wondering if anyone knows how to install a system font using C#? I know it doesn´t do the trick to simply copy the font to the font directory, it just doesn´t become active. Any...
3
by: Jim in Arizona | last post by:
I'm going insane! I don't know if it's just that the .net 2.0 framework is buggy or if it really is my code. This is pretty hard to explain since I can't even begin to nail down why this is...
0
by: Helen W | last post by:
Hi In my vb.net Installer class, I check the InstalledFontCollection for myFont, if it isn't there I try to install it using the GDI function AddFontResource. I am getting the following error...
19
by: pamelafluente | last post by:
Hi Guys, I am trying to include my little script in my html report. I have done an external JS file which contains it. If you remember, you have helped me to detect if the asp page was present...
7
by: Rulenoff | last post by:
I want to thank you in advance. I was able to clean up 20 errors since iv'e last posted and now I have what I believe the right doctype loading correctly. However I have 10 errors remaining on my...
4
by: ganesh | last post by:
I have a piece of C# code using ShellExecute API to install a TrueType font on Windows XP. The font is installed correctly and is visible with programs like WinWord. However, the font file seems to...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

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.