乐筑天下

搜索
欢迎各位开发者和用户入驻本平台 尊重版权,从我做起,拒绝盗版,拒绝倒卖 签到、发布资源、邀请好友注册,可以获得银币 请注意保管好自己的密码,避免账户资金被盗
查看: 99|回复: 19

[编程交流] acet-help not loading from Lis

[复制链接]

3

主题

20

帖子

17

银币

初来乍到

Rank: 1

铜币
15
发表于 2022-7-6 12:24:08 | 显示全部楼层 |阅读模式
When I strip out all my dialog, and just keep the 3 tiles OK Cancel & Help, the .chm I have created opens when I click the Help button.
But when I add the code to the full routine, the dialog loads properly, the routine runs, OK & Cancel work, but the Help button does nothing.
All the files are in a set path, I am stumped here.
Please take a look at the code and see if you see something I am missing here.
The Lisp is a bit rough right now I realize, but I will improve on the functionality after I get this fixed.
>
 
Thanks
SlimP
 
  1. //DCL CODING STARTS HEREpid4 : dialog {label = "PID v1.0" ;: spacer {height          = 1 ;}: boxed_column {: row {: boxed_column {label = "SUCTION GROUPS";fixed_width = true;fixed_height = true;fixed_width_font = true;: popup_list {key = "suctgrps";value = "0" ;edit_width = 20;}}//: spacer {//width          = 3 ;//}//: spacer {//height          = 1 ;//}//Subcooler Options: row {: boxed_column {label = "SUBCOOLING";fixed_width = true;fixed_height = true;fixed_width_font = true;: popup_list {key = "subcool";value = "0" ;edit_width = 20;}}: spacer {width          = 3 ;}// Liquid Injection Option Yes or No: row {: boxed_column {label = "LIQ. INJECTION (LT)";fixed_width = true;fixed_height = true;fixed_width_font = true;: popup_list {key = "liqinj";value = "0" ;edit_width = 20;}} } } } }: spacer {width          = 30 ;}//BEGIN COMPRESSOR SELECTION: boxed_column {label = "COMPRESSORS";: row {: column {fixed_width = true;fixed_height = true;fixed_width_font = true;: row {: boxed_column {label = "COMPRESSOR 1";: popup_list {key = "comp1un";value = "0" ;edit_width = 10;}: popup_list {key = "comp1vfd";value = "0" ;edit_width = 10;}: popup_list {key = "comp1dig";value = "0" ;edit_width = 10;}: popup_list {key = "comp1hfan";value = "0" ;edit_width = 11;}}: boxed_column {label = "COMPRESSOR 2";: popup_list {key = "comp2un";value = "0" ;edit_width = 10;}: popup_list {key = "comp2vfd";value = "0" ;edit_width = 10;}: popup_list {key = "comp2dig";value = "0" ;edit_width = 10;}: popup_list {key = "comp2hfan";value = "0" ;edit_width = 11;}}: boxed_column {label = "COMPRESSOR 3";: popup_list {key = "comp3un";value = "0" ;edit_width = 10;}: popup_list {key = "comp3vfd";value = "0" ;edit_width = 10;}: popup_list {key = "comp3dig";value = "0" ;edit_width = 10;}: popup_list {key = "comp3hfan";value = "0" ;edit_width = 11;}}: boxed_column {label = "COMPRESSOR 4";: popup_list {key = "comp4un";value = "0" ;edit_width = 10;}: popup_list {key = "comp4vfd";value = "0" ;edit_width = 10;}: popup_list {key = "comp4dig";value = "0" ;edit_width = 10;}: popup_list {key = "comp4hfan";value = "0" ;edit_width = 11;}}: boxed_column {label = "COMPRESSOR 5";: popup_list {key = "comp5un";value = "0" ;edit_width = 10;}: popup_list {key = "comp5vfd";value = "0" ;edit_width = 10;}: popup_list {key = "comp5dig";value = "0" ;edit_width = 10;}: popup_list {key = "comp5hfan";value = "0" ;edit_width = 11;}} }: row { : boxed_column {label = "COMPRESSOR S1";: popup_list {key = "comps1un";value = "0" ;edit_width = 10;}: popup_list {key = "comps1vfd";value = "0" ;edit_width = 10;}: popup_list {key = "comps1dig";value = "0" ;edit_width = 10;}: popup_list {key = "comps1hfan";value = "0" ;edit_width = 11;}}: boxed_column {label = "COMPRESSOR S2";: popup_list {key = "comps2un";value = "0" ;edit_width = 10;}: popup_list {key = "comps2vfd";value = "0" ;edit_width = 10;}: popup_list {key = "comps2dig";value = "0" ;edit_width = 10;}: popup_list {key = "comps2hfan";value = "0" ;edit_width = 11;}}: boxed_column {label = "COMPRESSOR S3";: popup_list {key = "comps3un";value = "0" ;edit_width = 10;}: popup_list {key = "comps3vfd";value = "0" ;edit_width = 10;}: popup_list {key = "comps3dig";value = "0" ;edit_width = 10;}: popup_list {key = "comps3hfan";value = "0" ;edit_width = 11;}}  : boxed_column {label = "COMPRESSOR S4";: popup_list {key = "comps4un";value = "0" ;edit_width = 10;}: popup_list {key = "comps4vfd";value = "0" ;edit_width = 10;}: popup_list {key = "comps4dig";value = "0" ;edit_width = 10;}: popup_list {key = "comps4hfan";value = "0" ;edit_width = 11;}} }  }   }    }//}//BEGIN LOOP SELECTION: boxed_column {label = "LOOP CIRCUITS";: row { : boxed_column {label = "LOOP 1";: popup_list {key = "loop1";value = "0" ;edit_width = 15;}}: boxed_column {label = "LOOP 2";: popup_list {key = "loop2";value = "0" ;edit_width = 15;}}: boxed_column {label = "LOOP 3";: popup_list {key = "loop3";value = "0" ;edit_width = 15;}}  : boxed_column {label = "LOOP 4 (SC)";: popup_list {key = "loop4";value = "0" ;edit_width = 15;}} } : row { : boxed_column {label = "LOOP S1";: popup_list {key = "loops1";value = "0" ;edit_width = 15;}}: boxed_column {label = "LOOP S2";: popup_list {key = "loops2";value = "0" ;edit_width = 15;}}: boxed_column {label = "LOOP S3";: popup_list {key = "loops3";value = "0" ;edit_width = 15;}}  : boxed_column {label = "LOOP S4 (SC)";: popup_list {key = "loops4";value = "0" ;edit_width = 15;}} }  }//   //CONDENSER OPTIONS//: boxed_column {fixed_width = true;label = "CONDENSER" ;: boxed_column {label = "Condenser Location";: popup_list {key = "cond1";value = "0" ;edit_width = 25;}}: boxed_column {label = "Water Heat Reclaim";: popup_list {key = "whr";value = "0" ;edit_width = 25;}}//: boxed_column {//fixed_width = true;//label = "RECEIVER" ;: boxed_column {label = "Receiver Size";: popup_list {key = "rec1";value = "0" ;edit_width = 15;}} } ////////////////// BUTTONS /////////////////////: row {   spacer;   spacer;   spacer;   spacer;   : button {     fixed_width=true;     width=13;     key="accept";     is_default=true;     label= "OK";   }   : button {     fixed_width=true;     width=13;     is_cancel=true;     key="cancel";     label= "Cancel";   }   : button {     fixed_width=true;     width=13;     key="help";     label= "&Help";     is_help=true;   }}//ok_cancel_help ;}//DCL CODING ENDS HERE
pid903.LSP
acet.zip
回复

使用道具 举报

32

主题

1166

帖子

1146

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
159
发表于 2022-7-6 12:30:05 | 显示全部楼层
It appears you are calling for a function called acet-help.
 
  1.            (action_tile "help" "(acet-help)")
 
I did not find a function by this name in your program.
Also I think you cannot use "help" as a key as it is reserved for acad help function. (not exactly sure)
回复

使用道具 举报

15

主题

687

帖子

169

银币

中流砥柱

Rank: 25

铜币
582
发表于 2022-7-6 12:30:41 | 显示全部楼层
Hi,
 
Try
 
  1. (action_tile "help" "(help "acet")")
回复

使用道具 举报

32

主题

1166

帖子

1146

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
159
发表于 2022-7-6 12:33:59 | 显示全部楼层
 
gile,
 
That work great except the acet.chm needed to be renamed to acet-help.chm, Otherwise it opens express tools help file.
 
I added the change with the renamed help file in the attached zip file.
 
  1. (action_tile "help" "(help "acet-help")")
 
Also the action tile needed to be placed here and not at the end of the program. See below.
 
  1. ;;;          /////////////////////     End  of List Box Build  Section      \\\\\\\\\\\\\\\\\\\\\\\\\ ;(action_tile"help""(help "acet-help")")(action_tile"accept""(get_data) (done_dialog) (setq userclick T)");action tile(action_tile"cancel";if cancel button pressed"(done_dialog) (setq userclick nil)";close dialog);action_tile(start_dialog);start dialog(unload_dialog dcl_id);  ;;          /////////////////////     End  of List Box Build  Section      \\\\\\\\\\\\\\\\\\\\\\\\\ ;; **************************************************************************************
 
 
 
 
 
 
Nice fix
pid4.zip
回复

使用道具 举报

3

主题

20

帖子

17

银币

初来乍到

Rank: 1

铜币
15
发表于 2022-7-6 12:39:31 | 显示全部楼层
Perfect!
I swear I tried that way (sort of)...
After a while it all starts to run together.
I need to learn patience when dealing with this lisp stuff.
 
One other thing maybe one of you could help me with...
Once I run the program, and I see that I missed answering one of the questions correctly,
I would like the program to "remember" the previous selections so I do not have to answer ALL the questions again, only the one I want to change/revise.
That would be a big plus for this.
 
I also realize I should put in an error trap.
Which type do you prefer?
回复

使用道具 举报

32

主题

1166

帖子

1146

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
159
发表于 2022-7-6 12:41:42 | 显示全部楼层
 
slimpickinz,
 
Attached is a program with two popup lists that will remember the last selection. Just go to the Main Function in this program to see how this is done. I think you will be able to figure this one out. Pay close attention to all the action tiles including the accept or OK button. Everything you need to do this is in there.
This is just a simple generic program that has no other use but to serve as a dialog sample. It does function well for its intended purpose.
 
As far as the error trap is concerned, Get thru this part first and we will worry about error trapping later.
 
Good Luck,
The Buzzard
SL.zip
回复

使用道具 举报

32

主题

1166

帖子

1146

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
159
发表于 2022-7-6 12:45:49 | 显示全部楼层
On second thought the above posted program, I just realized that I did not declare local variables. This may not be as good an example as I originally thought. It may complicate things for you. You cannot declare local variables for the action tiles as they will not remember there last settings because they lose there values after the program completes. They would need to be made as an obscure variable which is not declared and pass their values to another variable to be used in the program, Then those variables can be declared local.
 
You can still use the above program, But you will need to keep this in mind when setting your variables up to remember there last settings.
 
I will see if can come up with a better example or if someone else can post a better explanation. I hope you understand what I have just explained. If you get stuck I will try to get you past it. I did not want you to get too far ahead of yourself just to find this out.
 
Sorry about that slimpickinz,
I did not mean to complicate this more for you.
回复

使用道具 举报

3

主题

20

帖子

17

银币

初来乍到

Rank: 1

铜币
15
发表于 2022-7-6 12:46:29 | 显示全部楼层
...after looking through your example, it did seem to confuse me some.
Actually there are alot of variables to redefine in my program.
I think this would make the code way too long...agree?
 
I will wait and see what comes up.
I appreciate your help!
 
I am off to work on my .chm file now, which is much more enjoyable for me.
回复

使用道具 举报

32

主题

1166

帖子

1146

银币

初露锋芒

Rank: 3Rank: 3Rank: 3

铜币
159
发表于 2022-7-6 12:49:50 | 显示全部楼层
 
OK, I shortened the program to give you only what you need to see and fixed the variable problem. I hope this helps. Do not give up!
Yes you have alot of variables, So what! You are writting an interesting application. The effort you put into it now will return big rewards.
Because the program you are trying to create seems to be a tall order for you is a good reason to see this thru. Complete what you start!
 
You will not gain the knowledge by giving up on this. Yes, programming is difficult. The whole reason we do this is to make our jobs better to deal with in the first place. I am very impressed with what you have put together so far.
 
Please review what I have now posted. Get started and finish.
There is alot of help here for you in your corner.
 
Good Luck
SYMB.zip
回复

使用道具 举报

3

主题

20

帖子

17

银币

初来乍到

Rank: 1

铜币
15
发表于 2022-7-6 12:54:00 | 显示全部楼层
I am a persistent sort, and appreciate the encouragement.
Since you are helping so much I am attaching all the project files
including the drawing that goes with the app, just to show you what I have got so far.
If you would like to suggest any thing you think would help please feel free.
I really enjoy learning like this, and the end result will be a big help.
Again, I really appreciate the assistance.
I really hope that someone else will gain some knowledge from this thread.
 
I will look at your file and see what I can do. At this point I feel very confidant,
& if I cannot figure out a portion of it, I will get back with you.
I am looking forward to sharing the final result with all as well.
pid4.zip
PID-DWG.zip
回复

使用道具 举报

发表回复

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

  • 微信公众平台

  • 扫描访问手机版

  • 点击图片下载手机App

QQ|关于我们|小黑屋|乐筑天下 繁体中文

GMT+8, 2025-3-5 06:07 , Processed in 0.434636 second(s), 72 queries .

© 2020-2025 乐筑天下

联系客服 关注微信 帮助中心 下载APP 返回顶部 返回列表