是德科技
直播中

沈艳丽

7年用户 151经验值
私信 关注
[问答]

vrf窗口技巧

非常感谢Vinod和Tom的例子。
从这些我可以看到我应该使用SetWindowPos()而不是MoveWindow(),并相应地更新了附加的示例。
我想我真正想要的是保存.VXE文件的能力,该文件包含仅适用于该文件的各种选项。
例如
所有当前可用作veerun命令行开关的选项,加上一些新的选项:noresize,disablemaximize,disableminimize VEE愿望清单的另一个选项Cheers Paul F. ---订阅请发送电子邮件至:“vrf-
request@lists.it.agilent.com“在邮件正文中使用了subscribe一词。
要取消订阅,请发送一封空白电子邮件至“leave-vrf@it.lists.it.agilent.com”。
要将邮件发送到此邮件列表,请发送电子邮件至“vrf@agilent.com”。
如果您需要有关邮件列表的帮助,请发送邮件至“owner-vrf@it.lists.it.agilent.com”。
在“www.oswegosw.com/vrf_archive/”上搜索“unofficial vrf archive”。

以上来自于谷歌翻译


     以下为原文

  
Many thanks to Vinod and Tom for the examples.

From these I can see that I should be using SetWindowPos() rather than MoveWindow(), and I have updated the attached example accordingly.

I guess what I would really like is the ability to save a .VXE file with various options that will apply just to that file.
e.g. all the options that are currently available as veerun command-line switches, plus a couple of new ones: noresize, disablemaximize, disableminimize

Another one for the VEE wishlist  

Cheers
Paul F.

---  To subscribe please send an email to: "vrf-request@lists.it.agilent.com" with the word subscribe in the message body. To unsubscribe send a blank email to "leave-vrf@it.lists.it.agilent.com". To send messages to this mailing list, email "vrf@agilent.com". If you need help with the mailing list send a message to "owner-vrf@it.lists.it.agilent.com". Search the "unofficial vrf archive" at "www.oswegosw.com/vrf_archive/".  

回帖(5)

付华一

2018-9-10 17:13:04
以上来自于谷歌翻译


     以下为原文
举报

沈艳丽

2018-9-10 17:30:44
在“www.oswegosw.com/vrf_archive/”上搜索“unofficial vrf archive”。

以上来自于谷歌翻译


     以下为原文

  Search the "unofficial vrf archive" at "www.oswegosw.com/vrf_archive/".
举报

沈艳丽

2018-9-10 17:40:27
您好VRF我可以通过使用Kernel32中的Get / WritePrivateProfileStringA函数从INI文件中删除密钥(或部分)吗?我附上了我做的一个例子(INI-file.vee)。我在互联网上找到了这个VisualBasic示例,
这解释了怎么回事:============================================
= Private Sub ProfileDeleteItem(sSection As String,sKeyName As String,sIniFile As String)'此调用将从sSection中的sepcified部分删除键名及其“对应值”。
这是通过将'vbNullString作为sValue参数传递来实现的。
例如,'假设一个ini文件有:'[Colors]'Colour1 = Red'Colour2 = Blue'Colour3 = Green''这个子被称为传递“Colour2”'作为sKeyName,生成的ini文件'将包含:
'[Colors]'Colour1 = Red'Colour3 = Green Call WritePrivateProfileString(sSection,_ sKeyName,_ vbNullString,_sIniFile)End Sub(参见完整链接:http://vbnet.mvps.org/index.html?code /
file / pprofilebasic.htm)============================================
我只是无法在VEE中实现这一点!?!?
如何制作“vbNullString”?
有人必须在此之前完成此操作..... HELP!问候,Alex ---您目前订阅了vrf:r***@soco.agilent.com要订阅,请发送电子邮件至:“vrf-request@lists.it。
agilent.com“在邮件正文中单词subscribe。要取消订阅,请发送一封空白电子邮件至”leave-vrf@it.lists.it.agilent.com“。要向此邮件列表发送邮件,请发送电子邮件至”vrf @ agilent。
COM”。
如果您需要有关邮件列表的帮助,请发送邮件至“owner-vrf@it.lists.it.agilent.com”。在“www.oswegosw.com/vrf_archive/”上搜索“非官方vrf档案”。

以上来自于谷歌翻译


     以下为原文

  Hi VRF

How can I delete a Key (or section) from an INI-File, by using the
Get/WritePrivateProfileStringA functions from Kernel32?
I have attached an example I made (INI-file.vee).

I found this VisualBasic example on the internet, which explains how to
do it:
=============================================
Private Sub ProfileDeleteItem(sSection As String, sKeyName As String,
sIniFile As String)
  'this call will remove the keyname and its
  'corresponding value from the section sepcified
  'in sSection. This is accomplished by passing
  'vbNullString as the sValue parameter. For example,
  'assuming that an ini file had:
  ' [Colours]
  '  Colour1=Red
  '  Colour2=Blue
  '  Colour3=Green
  '
  'and this sub was called passing "Colour2"
  'as sKeyName, the resulting ini file
  'would contain:
  ' [Colours]
  '  Colour1=Red
  '  Colour3=Green
  
   Call WritePrivateProfileString(sSection, _
                                  sKeyName, _
                                  vbNullString, _
                                  sIniFile)
End Sub
(see entire link here:
http://vbnet.mvps.org/index.html?code/file/pprofilebasic.htm )
=============================================


I just can't make this happen in VEE!?!? How can I make a
"vbNullString"? Someone must have done this before..... HELP!

Regards,
Alex

---
You are currently subscribed to vrf as: [email=r***@soco.agilent.com]r***@soco.agilent.com[/email]
To subscribe please send an email to: "vrf-request@lists.it.agilent.com" with the word subscribe in the message body.
To unsubscribe send a blank email to "leave-vrf@it.lists.it.agilent.com".
To send messages to this mailing list,  email "vrf@agilent.com". 
If you need help with the mailing list send a message to
"owner-vrf@it.lists.it.agilent.com".
Search the "unofficial vrf archive" at "www.oswegosw.com/vrf_archive/".
举报

沈艳丽

2018-9-10 17:50:58
保罗也许你可以使用这些工具。
第一个将VEE程序作为顶部窗口。
第二个从VEE窗口中删除最小化,恢复和关闭图标。
我相信,代码是我在vrf上的另一张海报略微修改的东西。
也许原始的海报会识别他们的代码。(参见附件:保持VEE程序在Top.vee上)(参见附件:删除Min Max和关闭窗口Icons.vee)最好的问候,Tom DanielsSr。
测试工程师Morey Corporation100 Morey DriveWoodridge,IL 60517T:(630)754-2256F:(630)754-2656tdaniels@moreycorp.com Paul.Fowler@rayth eon.co.uk至08/30/2006 05:31 VRF AM cc主题
请回复[vrf] Window Tricks Paul.Fowler@rayth eon.co.uk再次问好你的VRF ...我一直在使用winAPI来处理一些代码,以防止用户调整VEE窗口的大小。用以下内容替换可调整大小的边框
固定的一个很简单,但是我在尝试重新绘制边框区域时遇到了问题。看起来这样做的任何功能(刷新等)实际上似乎都在实践中工作。附带的示例确实有效(VEE 7.52)
,但我不得不求助于调用MoveWindow()以重新绘制边框区域。这包括在GetWindowRect()上进行另外不必要的调用,以找到原始窗口大小和位置以给予MoveWindow()。实际上,这是
好吧,因为我通常希望在锁定它之前重新调整窗口的大小 - 让我真正使用MoveWindow()c
all.However;
肯定有一个更好的方法来强制边缘重绘?足够漫无边际 - 我想我真正的问题是:是否有一种令人眼花缭乱的防止窗口调整大小的方法,我已经错过了?CheersPaul F .---您目前订阅了vrf
如:TDaniels@moreycorp.com要订阅,请发送电子邮件至:“vrf-request@lists.it.agilent.com”,邮件正文中包含subscribe一词。
要取消订阅,请发送一封空白电子邮件至“leave-vrf@it.lists.it.agilent.com”。
要将邮件发送到此邮件列表,请发送电子邮件至“vrf@agilent.com”。
如果您需要有关邮件列表的帮助,请发送邮件至“owner-vrf@it.lists.it.agilent.com”。
在“www.oswegosw.com/vrf_archive/”上搜索“非官方的vrf档案”。(参见附件:NoResize.vee)---如需订阅,请发送电子邮件至:“vrf-request@lists.it.agilent。
com“在邮件正文中单词subscribe。要取消订阅,请发送空白电子邮件至”leave-vrf@it.lists.it.agilent.com“。要向此邮件列表发送邮件,请发送电子邮件至”vrf@agilent.com“

如果您需要有关邮件列表的帮助,请发送邮件至“owner-vrf@it.lists.it.agilent.com”。在“www.oswegosw.com/vrf_archive/”上搜索“非官方vrf档案”。

以上来自于谷歌翻译


     以下为原文

  Paul maybe you could use these utilities.  The first one keeps the VEE program as the top window.  The second one removes the minimize, restore, and close icons from the VEE window.  I believe, the code is something I modified slightly from another poster here on the vrf.  Maybe the original poster will recognize their code.

(See attached file: Keep VEE Program On Top.vee)(See attached file: Remove Min Max and Close Window Icons.vee)

Best Regards,

Tom Daniels
Sr. Test Engineer
The Morey Corporation
100 Morey Drive
Woodridge, IL 60517
T: (630) 754-2256
F: (630) 754-2656
tdaniels@moreycorp.com


                                                                          
             Paul.Fowler@rayth                                            
             eon.co.uk                                                    
                                                                        To
             08/30/2006 05:31          VRF               
             AM                                                         cc
                                                                          
                                                                   Subject
             Please respond to         [vrf] Window Tricks                
             Paul.Fowler@rayth                                            
                 eon.co.uk                                                
                                                                          
                                                                          
                                                                          
                                                                          





Hello again VRF...

I've been working on some code using the winAPI to prevent the user from resizing the VEE window.
Replacing the resizable border with a fixed one is simple enough, but I have run into problems when trying to repaint the border area.
None of the functions that appear to do this (refresh etc) actually seem to work in practice.

The attached example does work (VEE 7.52), but I have had to resort to calling MoveWindow() in order to repaint the border area.
This involves making an otherwise unnecessary call on GetWindowRect() to find the original window size and position to give to MoveWindow().

In practice this is OK, as I would usually wish to re-size the window before locking it - giving me a real use for the MoveWindow() call.

However; surely there must be a better way of forcing a border repaint?

Enough rambling - I guess my real question is: is there a blindingly obvious way of preventing window resizing that I have missed?

Cheers
Paul F.

--- You are currently subscribed to vrf as: TDaniels@moreycorp.com To subscribe please send an email to: "vrf-request@lists.it.agilent.com" with the word subscribe in the message body. To unsubscribe send a blank email to "leave-vrf@it.lists.it.agilent.com". To send messages to this mailing list, email "vrf@agilent.com". If you need help with the mailing list send a message to "owner-vrf@it.lists.it.agilent.com". Search the "unofficial vrf archive" at "www.oswegosw.com/vrf_archive/".(See attached file:
NoResize.vee)
---
To subscribe please send an email to: "vrf-request@lists.it.agilent.com" with the word subscribe in the message body.
To unsubscribe send a blank email to "leave-vrf@it.lists.it.agilent.com".
To send messages to this mailing list,  email "vrf@agilent.com". 
If you need help with the mailing list send a message to "owner-vrf@it.lists.it.agilent.com".
Search the "unofficial vrf archive" at "www.oswegosw.com/vrf_archive/".
举报

更多回帖

发帖
×
20
完善资料,
赚取积分