ASP Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming Languages - MoreASP Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old February 8th, 2011, 04:12 AM
narama87 narama87 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2011
Posts: 5 narama87 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 33 m 30 sec
Reputation Power: 0
'asp 0106 : 80020005'

َAll right ,
you are guys my last chance , so please try to help me please ,

here you are the whole story :
i'm using FPDF with asp to generate pdf files , till now every thing is fine , the pdf works well.
but , i want to add a font , a ttf file , because some characters don't show up properly , and here you are the .js file amien.js:
Code:
xtype='TrueType'; xname='Amien-01'; xdesc=lib.newArray('Ascent',1016,'Descent',-231,'CapHeight',1016,'Flags',32,'FontBBox','[-104 -231 714 1016]','ItalicAngle',0,'StemV',70,'MissingWidth',1000); xup=0; xut=0; xcw=lib.newArray( lib.chr(0),1000,lib.chr(1),1000,lib.chr(2),1000,lib.chr(3),1000,lib.chr(4),1000,lib.chr(5),1000,lib.  chr(6),1000,lib.chr(7),1000,lib.chr(8),1000,lib.chr(9),1000,lib.chr(10),1000,lib.chr(11),1000,lib.ch  r(12),1000,lib.chr(13),1000,lib.chr(14),1000,lib.chr(15),1000,lib.chr(16),1000,lib.chr(17),1000,lib.  chr(18),1000,lib.chr(19),1000,lib.chr(20),1000,lib.chr(21),1000, lib.chr(22),1000,lib.chr(23),1000,lib.chr(24),1000,lib.chr(25),1000,lib.chr(26),1000,lib.chr(27),100  0,lib.chr(28),1000,lib.chr(29),1000,lib.chr(30),1000,lib.chr(31),1000,' ',1000,'!',1000,'"',1000,'#',1000,'x',1000,'%',1000,'&',1000,'\'',1000,'(',1000,')',1000,'*',1000,'+',1000, ',',1000,'-',1000,'.',1000,'/',1000,'0',1000,'1',1000,'2',1000,'3',1000,'4',1000,'5',1000,'6',1000,'7',1000,'8',1000,'9',1000,':'  ,1000,';',1000,'<',1000,'=',1000,'>',1000,'?',1000,'@',1000,'A',1000, 'B',1000,'C',1000,'D',1000,'E',1000,'F',1000,'G',1000,'H',1000,'I',1000,'J',1000,'K',1000,'L',1000,'  M',1000,'N',1000,'O',1000,'P',1000,'Q',1000,'R',1000,'S',1000,'T',1000,'U',1000,'V',1000,'W',1000, 'X',1000,'Y',1000,'Z',1000,'[',1000,'\\',1000,']',1000,'^',1000,'_',1000,'`',1000,'a',1000,'b',1000,'c',1000,'d',1000,'e',1000,'f',1000,'g',1000,'h'  ,1000,'i',1000,'j',1000,'k',1000,'l',1000,'m',1000, 'n',1000,'o',1000,'p',1000,'q',1000,'r',1000,'s',1000,'t',1000,'u',1000,'v',1000,'w',1000,'x',1000,'  y',1000,'z',1000,'{',1000,'|',1000,'}',1000,'~',1000,lib.chr(127),1000,lib.chr(128),1000,lib.chr(129  ),1000,lib.chr(130),1000,lib.chr(131),1000, lib.chr(132),1000,lib.chr(133),1000,lib.chr(134),1000,lib.chr(135),1000,lib.chr(136),1000,lib.chr(13  7),1000,lib.chr(138),1000,lib.chr(139),1000,lib.chr(140),1000,lib.chr(141),1000,lib.chr(142),1000,li  b.chr(143),1000,lib.chr(144),1000,lib.chr(145),1000,lib.chr(146),1000,lib.chr(147),1000,lib.chr(148)  ,1000,lib.chr(149),1000,lib.chr(150),1000,lib.chr(151),1000,lib.chr(152),1000,lib.chr(153),1000, lib.chr(154),1000,lib.chr(155),1000,lib.chr(156),1000,lib.chr(157),1000,lib.chr(158),1000,lib.chr(15  9),1000,lib.chr(160),1000,lib.chr(161),1000,lib.chr(162),1000,lib.chr(163),1000,lib.chr(164),1000,li  b.chr(165),1000,lib.chr(166),1000,lib.chr(167),1000,lib.chr(168),1000,lib.chr(169),1000,lib.chr(170)  ,1000,lib.chr(171),1000,lib.chr(172),1000,lib.chr(173),1000,lib.chr(174),1000,lib.chr(175),1000, lib.chr(176),1000,lib.chr(177),1000,lib.chr(178),1000,lib.chr(179),1000,lib.chr(180),1000,lib.chr(18  1),1000,lib.chr(182),1000,lib.chr(183),1000,lib.chr(184),1000,lib.chr(185),1000,lib.chr(186),1000,li  b.chr(187),1000,lib.chr(188),1000,lib.chr(189),1000,lib.chr(190),1000,lib.chr(191),1000,lib.chr(192)  ,1000,lib.chr(193),1000,lib.chr(194),1000,lib.chr(195),1000,lib.chr(196),1000,lib.chr(197),1000, lib.chr(198),1000,lib.chr(199),1000,lib.chr(200),1000,lib.chr(201),1000,lib.chr(202),1000,lib.chr(20  3),1000,lib.chr(204),1000,lib.chr(205),1000,lib.chr(206),1000,lib.chr(207),1000,lib.chr(208),1000,li  b.chr(209),1000,lib.chr(210),1000,lib.chr(211),1000,lib.chr(212),1000,lib.chr(213),1000,lib.chr(214)  ,1000,lib.chr(215),1000,lib.chr(216),1000,lib.chr(217),1000,lib.chr(218),1000,lib.chr(219),1000, lib.chr(220),1000,lib.chr(221),1000,lib.chr(222),1000,lib.chr(223),1000,lib.chr(224),1000,lib.chr(22  5),1000,lib.chr(226),1000,lib.chr(227),1000,lib.chr(228),1000,lib.chr(229),1000,lib.chr(230),1000,li  b.chr(231),1000,lib.chr(232),1000,lib.chr(233),1000,lib.chr(234),1000,lib.chr(235),1000,lib.chr(236)  ,1000,lib.chr(237),1000,lib.chr(238),1000,lib.chr(239),1000,lib.chr(240),1000,lib.chr(241),1000, lib.chr(242),1000,lib.chr(243),1000,lib.chr(244),1000,lib.chr(245),1000,lib.chr(246),1000,lib.chr(24  7),1000,lib.chr(248),1000,lib.chr(249),1000,lib.chr(250),1000,lib.chr(251),1000,lib.chr(252),1000,li  b.chr(253),1000,lib.chr(254),1000,lib.chr(255),1000); xenc='cp1252'; xdiff=''; xfile='Amien_01.ttf'; xoriginalsize=24136;



and this is the asp code :

Code:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%> <!-- #include file="fpdf.asp " --> <% Set pdf=CreateJsObject("FPDF") set objInformations = server.createobject("ADODB.RECORDSET") pdf.CreatePDF() pdf.AddFont "amien" pdf.SetPath("fpdf/") pdf.Open() pdf.AddPage() '---------------------------------------------------------------------- ' Entête du document '---------------------------------------------------------------------- pdf.SetFont "amien", "",6 pdf.SetTextColor 0,0,0 pdf.Cell 0,5, "الاتحاد المغربي" ,"",1,"L" pdf.Cell 0,5,"","",1,"C" pdf.Close() pdf.Output() %>



the result is :

<p>Objet Response</font> <font face="Arial" size=2>error 'ASP 0106 : 80020005'</font>
<p>
<font face="Arial" size=2>Types non correspondants</font>
<p>
<font face="Arial" size=2>/ing2010/ing_scripts/fr/pdf/fpdf.asp </font><font face="Arial" size=2>, line 892</font>
<p>
<font face="Arial" size=2>Un type de données non pris en charge s'est présenté.
</font>



please please please help me out of this nightmare
i'm waiting for your answers pleaaaaaaase

Reply With Quote
  #2  
Old February 8th, 2011, 04:07 PM
Doug G Doug G is offline
Grumpier Old Moderator
Dev Shed God 19th Plane (14000 - 14499 posts)
 
Join Date: Jun 2003
Posts: 14,239 Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level) 
Time spent in forums: 1 Month 4 Weeks 15 h 20 m 7 sec
Reputation Power: 4445
Your posted code is missing all line breaks and is unreadable, try reposting the code and identify any asp errors and what line they might occur on, all you showed was some html string including an error message.

If you have any 'on error resume next' statements in your asp code take them out while debugging.
__________________
======
Doug G
======
It is a truism of American politics that no man who can win an election deserves to. --Trevanian, from the novel Shibumi

Reply With Quote
  #3  
Old February 9th, 2011, 02:02 AM
narama87 narama87 is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2011
Posts: 5 narama87 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 33 m 30 sec
Reputation Power: 0
hello Doug ,
thank you for answering me ,
here you are the code test.asp :

Code:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
 
 
<!-- #include file="fpdf.asp " -->
<%
   Set pdf=CreateJsObject("FPDF")
   set objInformations = server.createobject("ADODB.RECORDSET")
   pdf.CreatePDF()
   pdf.SetPath("fpdf/")
   pdf.Open()
   pdf.AddPage()
  
 
'Here the code for adding the font and it's the cause of the 
'problem
	pdf.AddFont "amien"
	'pdf.SetFont "amien", "",6
	pdf.SetTextColor 0,0,0
'here is the arabic text that i want to display in pdf
	pdf.Cell 0,5, "الاتحاد المغربي" ,"",1,"L"
	pdf.Close()
	
	
	pdf.Output()
%>


this link will show this code too (test.asp) : http://www.mediafire.com/?hd92z3ca3npufh2

the code of the font amien.js is here :

Code:
xtype='TrueType';
xname='Amien-01';
xdesc=lib.newArray('Ascent',1016,'Descent',-231,'CapHeight',1016,'Flags',32,'FontBBox','[-104 -231 714 1016]','ItalicAngle',0,'StemV',70,'MissingWidth',1000);
xup=0;
xut=0;
xcw=lib.newArray(lib.chr(0),1000,lib.chr(1),1000,lib.chr(2),
1000,lib.chr(3),1000,lib.chr(4),1000,lib.chr(5),1000,lib.chr(6),
1000,lib.chr(7),1000,lib.chr(8),1000,lib.chr(9),1000,lib.chr(10),1000,lib.chr(11),1000,lib.chr(12),1  000,lib.chr(13),1000,
lib.chr(14),1000,lib.chr(15),1000,lib.chr(16),1000,lib.chr(17),
1000,lib.chr(18),1000,lib.chr(19),1000,lib.chr(20),1000,
lib.chr(21),1000,lib.chr(22),1000,lib.chr(23),1000,lib.chr(24),
1000,lib.chr(25),1000,lib.chr(26),1000,lib.chr(27),1000,
lib.chr(28),1000,lib.chr(29),1000,lib.chr(30),1000,lib.chr(31),
1000,'',1000,'!',1000,'"',1000,'#',1000,'x',1000,'%',1000,'&',
1000,'\'',1000,'(',1000,')',1000,'*',1000,'+',1000,',',1000,'',1000,
'.',1000,'/',1000,'0',1000,'1',1000,'2',1000,'3',1000,'4',1000,'5',
1000,'6',1000,'7',1000,'8',1000,'9',1000,':',1000,';',1000,'<',
1000,'=',1000,'>',1000,'?',1000,'@',1000,'A',1000,'B',1000,'C',
1000,'D',1000,'E',1000,'F',1000,'G',1000,'H',1000,'I',1000,'J',
1000,'K',1000,'L',1000,'M',1000,'N',1000,'O',1000,'P',1000,'Q',
1000,'R',1000,'S',1000,'T',1000,'U',1000,'V',1000,'W',1000,'X',
1000,'Y',1000,'Z',1000,'[',1000,'\\',1000,']',1000,'^',1000,'_',
1000,'`',1000,'a',1000,'b',1000,'c',1000,'d',1000,'e',1000,'f',
1000,'g',1000,'h',1000,'i',1000,'j',1000,'k',1000,'l',1000,'m',1000,
'n',1000,'o',1000,'p',1000,'q',1000,'r',1000,'s',1000,'t',1000,'u',
1000,'v',1000,'w',1000,'x',1000,'y',1000,'z',1000,'{',1000,'|',
1000,'}',1000,'~',1000,lib.chr(127),1000,lib.chr(128),1000,
lib.chr(129),1000,lib.chr(130),1000,lib.chr(131),1000,
lib.chr(132),1000,lib.chr(133),1000,lib.chr(134),1000,
lib.chr(135),1000,lib.chr(136),1000,lib.chr(137),1000,
lib.chr(138),1000,lib.chr(139),1000,lib.chr(140),1000,
lib.chr(141),1000,lib.chr(142),1000,lib.chr(143),1000,
lib.chr(144),1000,lib.chr(145),1000,lib.chr(146),1000,
lib.chr(147),1000,lib.chr(148),1000,lib.chr(149),1000,
lib.chr(150),1000,lib.chr(151),1000,lib.chr(152),1000,
lib.chr(153),1000,lib.chr(154),1000,lib.chr(155),1000,
lib.chr(156),1000,lib.chr(157),1000,lib.chr(158),1000,
lib.chr(159),1000,lib.chr(160),1000,lib.chr(161),1000,
lib.chr(162),1000,lib.chr(163),1000,lib.chr(164),1000,
lib.chr(165),1000,lib.chr(166),1000,lib.chr(167),1000,
lib.chr(168),1000,lib.chr(169),1000,lib.chr(170),1000,
lib.chr(171),1000,lib.chr(172),1000,lib.chr(173),1000,
lib.chr(174),1000,lib.chr(175),1000,lib.chr(176),1000,
lib.chr(177),1000,lib.chr(178),1000,lib.chr(179),1000,
lib.chr(180),1000,lib.chr(181),1000,lib.chr(182),1000,
lib.chr(183),1000,lib.chr(184),1000,lib.chr(185),1000,
lib.chr(186),1000,lib.chr(187),1000,lib.chr(188),1000,
lib.chr(189),1000,lib.chr(190),1000,lib.chr(191),1000,
lib.chr(192),1000,lib.chr(193),1000,lib.chr(194),1000,
lib.chr(195),1000,lib.chr(196),1000,lib.chr(197),1000,
lib.chr(198),1000,lib.chr(199),1000,lib.chr(200),1000,
lib.chr(201),1000,lib.chr(202),1000,lib.chr(203),1000,
lib.chr(204),1000,lib.chr(205),1000,lib.chr(206),1000,
lib.chr(207),1000,lib.chr(208),1000,lib.chr(209),1000,
lib.chr(210),1000,lib.chr(211),1000,lib.chr(212),1000,
lib.chr(213),1000,lib.chr(214),1000,lib.chr(215),1000,
lib.chr(216),1000,lib.chr(217),1000,lib.chr(218),1000,
lib.chr(219),1000,lib.chr(220),1000,lib.chr(221),1000,
lib.chr(222),1000,lib.chr(223),1000,lib.chr(224),1000,
lib.chr(225),1000,lib.chr(226),1000,lib.chr(227),1000,
lib.chr(228),1000,lib.chr(229),1000,lib.chr(230),1000,
lib.chr(231),1000,lib.chr(232),1000,lib.chr(233),1000,
lib.chr(234),1000,lib.chr(235),1000,lib.chr(236),1000,
lib.chr(237),1000,lib.chr(238),1000,lib.chr(239),1000,
lib.chr(240),1000,lib.chr(241),1000,lib.chr(242),1000,
ib.chr(243),1000,lib.chr(244),1000,lib.chr(245),1000,
lib.chr(246),1000,lib.chr(247),1000,lib.chr(248),1000,
lib.chr(249),1000,lib.chr(250),1000,lib.chr(251),1000,
lib.chr(252),1000,lib.chr(253),1000,lib.chr(254),1000,
lib.chr(255),1000);
xenc='cp1252';
xdiff='';
xfile='Amien_01.ttf';
xoriginalsize=24136;


the line 892 that generates the problem is :
Code:
if (!this.hasBinary){
				Response.Write(this.buffer)}
			else{
				xfile=Server.MapPath(lib.fso.GetTempName())
				xf=lib.fopen(xfile,"wb");
				if(xf.number)this.Error("Unable to create output file: " + xfile);
				lib.fwrite(xf,this.buffer);
				lib.fclose(xf);
				outB = Server.CreateObject("ADODB.Stream")
				outB.Type = 1
				outB.Open()
				outB.LoadFromFile (xfile)
'THIS IS THE LINE 891
				Response.BinaryWrite(outB.Read())
				outB.Close()
				lib.fso.DeleteFile(xfile);
				}


fpdf.asp is in this link :http://www.mediafire.com/?krut876p02r388p

i hope you can find something

Reply With Quote
  #4  
Old February 9th, 2011, 01:40 PM
Doug G Doug G is offline
Grumpier Old Moderator
Dev Shed God 19th Plane (14000 - 14499 posts)
 
Join Date: Jun 2003
Posts: 14,239 Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level)Doug G User rank is General 52nd Grade (Above 100000 Reputation Level) 
Time spent in forums: 1 Month 4 Weeks 15 h 20 m 7 sec
Reputation Power: 4445
I don't know an answer. If you have any 'on error resume next' statement in your code take it out for debugging.

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreASP Programming > 'asp 0106 : 80020005'

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap