-
Notifications
You must be signed in to change notification settings - Fork 0
/
ddecfg.frm
277 lines (251 loc) · 8.23 KB
/
ddecfg.frm
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
VERSION 5.00
Begin VB.Form frmDdelink
Caption = "DDE Settings"
ClientHeight = 3458
ClientLeft = 65
ClientTop = 351
ClientWidth = 3419
Icon = "ddecfg.frx":0000
LinkTopic = "Form1"
ScaleHeight = 3458
ScaleWidth = 3419
StartUpPosition = 3 'Windows Default
Begin VB.CheckBox CheckLog
Caption = "Log Events"
Enabled = 0 'False
Height = 247
Left = 1872
TabIndex = 15
Top = 2340
Width = 1300
End
Begin VB.TextBox Decimal
Height = 247
Left = 117
TabIndex = 13
Text = "."
Top = 2457
Width = 247
End
Begin VB.ComboBox DDEFormat
Height = 315
Left = 120
TabIndex = 11
ToolTipText = "Select the tracking program to provide frequency calculations."
Top = 360
Width = 1335
End
Begin VB.CommandButton Command3
Caption = "Satellite Data"
Height = 375
Left = 1800
TabIndex = 10
ToolTipText = "When using Nova, a satellites frequencies database is kept."
Top = 240
Width = 1215
End
Begin VB.CommandButton Command2
Caption = "Close"
Height = 495
Left = 1800
TabIndex = 9
ToolTipText = "Close this window."
Top = 2808
Width = 975
End
Begin VB.TextBox Interval
Height = 285
Left = 1800
TabIndex = 8
ToolTipText = $"ddecfg.frx":030A
Top = 1800
Width = 855
End
Begin VB.TextBox Item
Height = 285
Left = 120
TabIndex = 6
ToolTipText = "DDE link item for frequency and mode info of satellite tracking application."
Top = 1800
Width = 1335
End
Begin VB.TextBox Topic
Height = 285
Left = 1800
TabIndex = 5
ToolTipText = "DDE link topic for frequency and mode info of satellite tracking application."
Top = 1080
Width = 1335
End
Begin VB.TextBox SourceApplication
Height = 285
Left = 120
TabIndex = 4
ToolTipText = "DDE name of satellite tracking application."
Top = 1080
Width = 1335
End
Begin VB.CommandButton Command1
Caption = "Save"
Height = 495
Left = 468
TabIndex = 2
ToolTipText = "Save settings to Windows Registry."
Top = 2808
Width = 975
End
Begin VB.Label Label5
Caption = "Decimal separator:"
Height = 247
Left = 117
TabIndex = 14
Top = 2223
Width = 1300
End
Begin VB.Label DDE
Caption = "Receive DDE from:"
Height = 255
Left = 120
TabIndex = 12
Top = 120
Width = 1455
End
Begin VB.Label Label4
Caption = "Query Interval (sec.):"
Height = 255
Left = 1800
TabIndex = 7
Top = 1560
Width = 1575
End
Begin VB.Label Label3
Caption = "Link Item:"
Height = 255
Left = 120
TabIndex = 3
Top = 1560
Width = 1455
End
Begin VB.Label Label2
Caption = "Link Topic:"
Height = 255
Left = 1800
TabIndex = 1
Top = 840
Width = 1455
End
Begin VB.Label Label1
Caption = "Source Application:"
Height = 255
Left = 120
TabIndex = 0
Top = 840
Width = 1575
End
End
Attribute VB_Name = "frmDdelink"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
SaveSetting "WiSP_DDE_Client", "Config", "Dde_source", SourceApplication.text
SaveSetting "WiSP_DDE_Client", "Config", "Dde_topic", Topic.text
SaveSetting "WiSP_DDE_Client", "Config", "Dde_item", Item.text
SaveSetting "WiSP_DDE_Client", "Config", "Dde_period", Interval.text
SaveSetting "WiSP_DDE_Client", "Config", "Dde_format", DDEFormat.text
'make sure decimal separator is OK
If (Decimal.text <> "." And Decimal.text <> ",") Then
frmDdelink.Decimal.text = "."
End If
SaveSetting "WiSP_DDE_Client", "Config", "Decimal_Separator", Decimal.text
'if WiSPDDE is to be client, we update settings,
If DDEFormat.text <> "SatPC32" Then
'Set the proper value for the Timer (convert to
'milliseconds)
If frmMain.Cdbl2(Interval.text) <> 0 Then
frmMain.DDEPollTimer.Interval = frmMain.Cdbl2(Interval.text) * 1000
frmMain.DDEPollTimer.Enabled = True
Else
frmMain.DDEPollTimer.Enabled = False
End If
'Source and Topic goes together separated by '|':
frmMain.DDELabel.LinkTopic = SourceApplication.text + "|" + Topic.text
frmMain.DDELabel.LinkItem = Item.text
frmMain.DDE_Test
End If
End Sub
Private Sub Command2_Click()
frmDdelink.Hide
End Sub
Private Sub Command3_Click()
frmSats.Show
End Sub
Private Sub DDEFormat_Change()
Select Case DDEFormat.text
Case Is = "WiSP"
SourceApplication.text = "GSC"
Topic.text = "Tracking"
Item.text = "Tracking"
Interval.text = "3"
Command3.Enabled = False
Case Is = "Station"
SourceApplication.text = "Station"
Topic.text = "Tracking"
Item.text = "General"
Interval.text = "3"
Command3.Enabled = False
Case Is = "Winorbit"
SourceApplication.text = "WinOrbit"
Topic.text = "TrackingInfo"
Item.text = "SatelliteName"
Interval.text = "3"
Command3.Enabled = False
Case Is = "Nova"
SourceApplication.text = "NFW32"
Topic.text = "NFW_DATA"
Item.text = "NFW_SERVER"
Interval.text = "3"
Command3.Enabled = True
Case Is = "SatPC32"
SourceApplication.text = "SatPC32"
Topic.text = "SatPcDdeConv"
Item.text = "SatPcDdeItem"
Interval.text = "3"
Command3.Enabled = False
Case Is = "Satscape"
SourceApplication.text = "Satscape"
Topic.text = "Tracking"
Item.text = "Tracking"
Interval.text = "3"
Command3.Enabled = False
Case Is = "WXtrack"
SourceApplication.text = "WXtrack"
Topic.text = "Tracking"
Item.text = "Tracking"
Interval.text = "3"
Command3.Enabled = False
Case Is = "Orbitron"
SourceApplication.text = "Orbitron"
Topic.text = "Tracking"
Item.text = "TrackingData"
Interval.text = "1"
Command3.Enabled = False
End Select
End Sub
Private Sub DDEFormat_Click()
Call DDEFormat_Change
End Sub
Private Sub Form_Load()
DDEFormat.AddItem "None"
DDEFormat.AddItem "Orbitron"
DDEFormat.AddItem "WiSP"
DDEFormat.AddItem "Station"
DDEFormat.AddItem "Winorbit"
DDEFormat.AddItem "Nova"
DDEFormat.AddItem "SatPC32"
DDEFormat.AddItem "Satscape"
DDEFormat.AddItem "WXtrack"
CheckLog.Enabled = False
CheckLog.Value = 0
End Sub