| 上一篇主題 :: 下一篇主題   | 
	
	
	
		| 發表人 | 
		內容 | 
	
	
		chen-steven
 
 
  註冊時間: 2005-08-19 文章: 11
 
  第 1 樓
  | 
		
			
				 發表於: 星期一 八月 22, 2005 9:02 am    文章主題: 打印预览问题 | 
				     | 
			 
			
				
  | 
			 
			
				| 请问有什么方法可以让预览工具栏停靠,一般情况下,在预览时总是浮在报表上面的,需要双击才能停靠,可不可以在预览时自动让其停靠? | 
			 
		  | 
	
	
		| 回頂端 | 
		 | 
	
	
		  | 
	
	
		星河
 
 
  註冊時間: 2005-08-22 文章: 21
 
  第 2 樓
  | 
		
			
				 發表於: 星期一 八月 22, 2005 11:32 am    文章主題:  | 
				     | 
			 
			
				
  | 
			 
			
				Dock Window "print preview" Position 0 
 
 
这样就可以 | 
			 
		  | 
	
	
		| 回頂端 | 
		 | 
	
	
		  | 
	
	
		bin1x
 
 
  註冊時間: 2004-08-27 文章: 462
 
  第 3 樓
  | 
		
			
				 發表於: 星期一 八月 22, 2005 11:38 am    文章主題:  | 
				     | 
			 
			
				
  | 
			 
			
				呼呼
 
又知道了一個特殊命令,沒去用還真不知道
 
但語法像是
 
物件的method 
 
但preview toolbar 的物件名字是........... | 
			 
		  | 
	
	
		| 回頂端 | 
		 | 
	
	
		  | 
	
	
		小賴
 
 
  註冊時間: 2004-12-27 文章: 477
 
  第 4 樓
  | 
		
			
				 發表於: 星期一 八月 22, 2005 5:47 pm    文章主題:  | 
				     | 
			 
			
				
  | 
			 
			
				 	  | 引言回覆: | 	 		  
 
Dock Window "print preview" Position 0 
 
 | 	  
 
 
正好用的上 ; 感謝星河兄 ! | 
			 
		  | 
	
	
		| 回頂端 | 
		 | 
	
	
		  | 
	
	
		chen-steven
 
 
  註冊時間: 2005-08-19 文章: 11
 
  第 5 樓
  | 
		
			
				 發表於: 星期六 八月 27, 2005 10:58 am    文章主題:  | 
				     | 
			 
			
				
  | 
			 
			
				很感谢,但是我用Dock Window "print preview" Position 0去测试时,为什么提示“此功能不可用”?烦请再为指点,谢谢!
  chen-steven 在 星期六 八月 27, 2005 11:20 am 作了第 2 次修改 | 
			 
		  | 
	
	
		| 回頂端 | 
		 | 
	
	
		  | 
	
	
		chen-steven
 
 
  註冊時間: 2005-08-19 文章: 11
 
  第 6 樓
  | 
		
			
				 發表於: 星期六 八月 27, 2005 11:18 am    文章主題:  | 
				     | 
			 
			
				
  | 
			 
			
				| 经过测试,发现系统所示错误是由于没有定义窗口名称而引起的,但是对于一般情况来讲,我们都是使用的系统的默认的窗口,不存在着自定义窗口,如:report form aaa preview,请问这种情况下:Dock Window "print preview" Position 0 中的"print preview"应该如何更正,才能使用? | 
			 
		  | 
	
	
		| 回頂端 | 
		 | 
	
	
		  | 
	
	
		bin1x
 
 
  註冊時間: 2004-08-27 文章: 462
 
  第 7 樓
  | 
		
			
				 發表於: 星期六 八月 27, 2005 11:25 am    文章主題:  | 
				     | 
			 
			
				
  | 
			 
			
				dock 的相關有method 和property 
 
下面就是property 的
 
只是print preview 的toolsbar 
 
查了一下toolbar 也有建立的方法
 
用工具列查一下就知道
 
只是
 
已存在的toolbar 名稱如何抓取
 
不然這個問題很簡單
 
"把工具列拉到頂端",下一次開啟時就在頂端了
 
 
 
Specifies the position where a user-defined ToolBar object is docked. Read-only at design time and run time.
 
Syntax
 
 
ToolBar.DockPosition[= nPosition]
 
 
Settings
 
 
nPosition   The values for nPosition are:
 
 
Setting	Position
 
?1	Undocked
 
0	Top
 
1	Left
 
2	Right
 
3	Bottom
 
 
建立toolbar 
 
查一下就有了,想要圖示也有圖示,"照著抄"就行了
 
說到底,我還是不曉得print preview 的物件名稱如何抓,這才是我想知道的
 
ToolBar Object Example
 
The following example demonstrates how you can create a toolbar from the Toolbar class. Visual FoxPro rearranges the buttons when the toolbar is resized. When the ToolBar object is created, Visual FoxPro automatically places the controls from left to right in the order they are added to the class definition, ignoring the controls?Top and Left properties.
 
 
PUBLIC tbrDesktop
 
tbrDesktop = CREATEOBJ('mytoolbar')
 
tbrDesktop.SHOW
 
 
DEFINE CLASS myToolBar    AS Toolbar
 
	ADD OBJECT btnBold    AS CommandButton
 
	ADD OBJECT sep1	       AS Separator
 
	ADD OBJECT btnItalics AS CommandButton
 
	
 
	btnBold.HEIGHT = 20
 
	btnBold.WIDTH = 50
 
	btnBold.Caption = "Bold"
 
	btnItalics.HEIGHT = 20
 
	btnItalics.WIDTH = 50
 
	btnItalics.Caption = "Italic"
 
	btnItalics.FontBold = .F.
 
	
 
	LEFT	= 1
 
	TOP = 1
 
	WIDTH = 25
 
 
CAPTION = "Desktop Attributes"
 
	
 
	PROCEDURE Activate 
 
	this.btnBold.FontBold = _SCREEN.FONTBOLD
 
	this.btnItalics.FontItalic = _SCREEN.FONTITALIC
 
	ENDPROC
 
	
 
	PROCEDURE btnBold.CLICK
 
	_SCREEN.FONTBOLD = !_SCREEN.FONTBOLD
 
	This.FontBold =_SCREEN.FONTBOLD
 
	ENDPROC
 
	
 
	PROCEDURE btnItalics.CLICK
 
	_SCREEN.FONTITALIC = !_SCREEN.FONTITALIC
 
	This.FontItalic = _SCREEN.FONTITALIC
 
	ENDPROC
 
ENDDEFINE | 
			 
		  | 
	
	
		| 回頂端 | 
		 | 
	
	
		  | 
	
	
		chen-steven
 
 
  註冊時間: 2005-08-19 文章: 11
 
  第 8 樓
  | 
		
			
				 發表於: 星期六 八月 27, 2005 11:35 am    文章主題:  | 
				     | 
			 
			
				
  | 
			 
			
				| 回复bin1x的"把工具列拉到頂端",下一次開啟時就在頂端了",如果resource=off的话,这样操作是不起作用的,所以关键还是要找到如何找到"toolbar"的使用方法 | 
			 
		  | 
	
	
		| 回頂端 | 
		 | 
	
	
		  | 
	
	
		chen-steven
 
 
  註冊時間: 2005-08-19 文章: 11
 
  第 9 樓
  | 
		
			
				 發表於: 星期六 八月 27, 2005 11:52 am    文章主題:  | 
				     | 
			 
			
				
  | 
			 
			
				| 另外,在vfp的报表设计器中,能否有方法找到其init事件? | 
			 
		  | 
	
	
		| 回頂端 | 
		 | 
	
	
		  | 
	
	
		 |