Question

Asked on 2009-10-19 at 09:40:09ID: 25039299

Using gdiplus.

by: MichaelKatz500

Rating9.5Excellent

I am trying to get full text justification into a vfp report.

I pasted some code but can't seem to find the library "system.vcx". I may have more questions after this is resolved, but at this point I have to find the library to get the report to run

DEFINE CLASS FullJustifyListener AS _ReportListener OF ;
		ADDBS(HOME(1)) + "FFC\_ReportListener.VCX"
	oGDIGraphics = NULL
	DIMENSION aRecords[1]
 
	* Doug Hennig - If ListenerType hasn't already been set, set it based on whether the report
	* is being printed or previewed.
	FUNCTION LOADREPORT
	WITH THIS
		DO CASE
		CASE .LISTENERTYPE <> -1
		CASE .COMMANDCLAUSES.PREVIEW
			.LISTENERTYPE = 1
		CASE .COMMANDCLAUSES.OutputTo = 1
			.LISTENERTYPE = 0
		ENDCASE
	ENDWITH
	DODEFAULT()
	ENDFUNC
 
	* Before we run the report, we need to Make sure that GdiPlusX
	* was initialized, and create a new Graphics object
	*!*	FUNCTION BEFOREREPORT
	*!*	   DODEFAULT()
	*!*	   WITH This
	*!*	   * Check if we already have the "System" object in "_Screen"
	*!*	   IF NOT PEMSTATUS(_Screen,"System",5)
	*!*	      DO LOCFILE("System.App")
	*!*	   ENDIF
 
	*!*	   .oGDIGraphics = _SCREEN.SYSTEM.Drawing.Graphics.New()
	*!*	   .SetFRXDataSession() && switches to the FRX cursor's datasession
	*!*	   DIMENSION .aRecords(RECCOUNT(), 13)
	*!*	   SCAN FOR "<FJ>" $ UPPER(User)
	*!*	      .aRecords(RECNO(), 13) = "FJ"
	*!*	   ENDSCAN
	*!*	   .ResetDataSession() && restores the datasession ID to the one the listener is in
	*!*	   ENDWITH
	*!*	ENDFUNC
 
 
	FUNCTION BEFOREREPORT
	DODEFAULT()
	WITH THIS
		* Check if we already have the "System" object in "_Screen"
		IF NOT PEMSTATUS(_SCREEN,"System",5)
		DO LOCFILE("System.App")
*			_SCREEN.ADDPROPERTY("System", NEWOBJECT("xfcSystem", LOCFILE("system.vcx")))
		ENDIF
		
		.oGDIGraphics = _SCREEN.SYSTEM.Drawing.Graphics.New()
		.SetFRXDataSession()
		DIMENSION .aRecords[reccount(), 13]
		SCAN FOR "<FJ>" $ UPPER(USER)
			.aRecords[recno(), 13] = "FJ"
		ENDSCAN
		.ResetDataSession()
	ENDWITH
	ENDFUNC
                              
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:

Select allOpen in new window

Related Solutions

Solution

Access this solution immediately by signing up as a member of FoxproAnswers.com--it’s quick, easy, and secure. We will return you to this solution, unlocked, when you’re done.

About this Solution
Sign up Now to View This Solution
Zone
general
Tags
gdiplus full justification
Participating Experts
3
Solution Grade
A

Replies

 by: Olaf_Doschke

Posted on 2009-10-19 at 09:57:11ID: 26263370

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

 by: pcelba

Posted on 2009-10-19 at 10:28:40ID: 26263371

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

 by: MichaelKatz

Posted on 2009-10-19 at 10:29:41ID: 26263372

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

 by: pcelba

Posted on 2009-10-19 at 10:32:22ID: 26263373

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

 by: tusharkanvinde

Posted on 2009-10-19 at 10:42:54ID: 26263374

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

 by: tusharkanvinde

Posted on 2009-10-19 at 10:49:04ID: 26263375

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

 by: pcelba

Posted on 2009-10-19 at 10:57:26ID: 26263376

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

 by: pcelba

Posted on 2009-10-19 at 10:59:42ID: 26263377

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

 by: pcelba

Posted on 2009-10-19 at 11:00:52ID: 26263378

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

 by: tusharkanvinde

Posted on 2009-10-19 at 11:11:57ID: 26263379

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

 by: Olaf_Doschke

Posted on 2009-10-19 at 14:05:58ID: 26263380

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

 by: MichaelKatz

Posted on 2009-10-20 at 05:06:43ID: 26263381

All comments and solutions are available to Premium Service Members only. Sign up to view the solution to this question. Already a member? Log in to view this solution.

Log In

Forgot your password?Sign up

Top Experts

  1. pcelba

    4,240

    0 points yesterday

    Profile
  2. mozner

    2,000

    0 points yesterday

    Profile
  3. mbarbir

    1,912

    0 points yesterday

    Profile
  4. jrbbldr

    1,500

    0 points yesterday

    Profile

BrowseAre you an Expert?