(defun c:flexcelltest/Form1#OnInitialize (/)
;These codes are working
(dcl-AxControl-Put flexcelltest/Form1/Grid1 "Rows" 1)
(dcl-AxControl-Put flexcelltest/Form1/Grid1 "Cols" 5)
(dcl-AxControl-Put flexcelltest/Form1/Grid1 "DisplayRowNumber" T)
(dcl-AxControl-Invoke flexcelltest/Form1/Grid1 "AddItem" (strcat "A" "\t" "B" "\t" "C" "\t" "D") T)
(dcl-AxControl-Invoke flexcelltest/Form1/Grid1 "AddItem" (strcat "A" "\t" "B" "\t" "C" "\t" "D") T)
(dcl-AxControl-Invoke flexcelltest/Form1/Grid1 "AddItem" (strcat "A" "\t" "B" "\t" "C" "\t" "D") T)
;Returns a Cell object as an entity.
(setq cell (car (dcl-AxControl-Invoke flexcelltest/Form1/Grid1 "Cell" 1 2))
)
;"Text" is a cell object property based on FlexCell documentaion. "Text" returns or sets the content of a given cell.
;This gives an error: Invalid argument type dcl-Control-SetProperty, argument 0
(dcl-Control-SetProperty cell "Text" "XYZ")
)
Quote from: owenwengerd on March 21, 2023, 04:10:23 PMI gave up on PayPal, and never looked for an alternative. I hope whoever takes over the web site administration may be motivated to find an alternative solution.
(defun c:FINDMS (/ *error*)
(command "OPENDCL")
(dcl_Project_Load "FindMS" T)
(dcl_Form_Show FindMS_Form1)
(princ)
)
;; Error Trap
(defun *error* ( msg )
(if (not (wcmatch (strcase msg t) "*break,*cancel*,*exit*"))
(princ (strcat "\nError: " msg))
);if
(princ)
);error
;; Start Dialog box
(defun c:FindMS/Form1#OnInitialize (/)
(if (not MS#)
(setq MS# "")
);if
(if (not uOpt)
(setq uOpt 1)
);if
(dcl-Control-SetText FindMS/Form1/TextBox1 MS#)
(dcl-OptionList-SetCurSel FindMS/Form1/OptionList1 uOpt)
)
;; OK Button
(defun c:FindMS/Form1/TextButton1#OnClicked (/)
(setq MS# (dcl-Control-GetText FindMS/Form1/TextBox1)
uOpt (dcl-OptionList-GetCurSel FindMS/Form1/OptionList1)
);setq
(command "_UnisolateObjects")
(if (tblsearch "Layer" MS#)
(if (setq SS (ssget "_X" (list (cons 8 MS#))))
(command "Zoom" "_object" SS "")
(alert (strcat "No Objects assigned to " MS#))
);if
(alert (strcat MS# " Not Found!"))
);if
(UserOption) ;; Option Button
(princ)
);defun
;; Cancel Button
(defun c:FindMS/Form1/TextButton2#OnClicked (/)
(dcl_Form_Close FindMS_Form1)
)
;; Isloate Option
(defun UserOption (/)
(cond
((= uOpt 0)(command "_IsolateObjects" "P" ""))
((= uOpt 1)(command "_UnisolateObjects"))
);cond
)
;; Run command with retrun key
(defun c:FindMS/Form1/TextBox1#OnReturnPressed (/)
(dcl-sendstring "FindMS/Form1/TextButton1#OnClicked\r")
)
;; Keep dialog open when pressing return
(defun c:FindMS/Form1#OnCancelClose (Reason /)
(/= intIsESC 1)
)