Hi,
While using acedssget, I wanted to add a layer option to filter selectionset
Its working like this:
const ACHAR* promptPtrs[] = {
_T("\nSelect entities [Tlayer]: : "),
_T("\nRemove entities from selection set: ")
};
step1: acedSSGet (_T ("_: K"), NULL, kwordlist, resfilter, ss))
//if the user press Tlayer, the ssCallback function is called, now I can change resfilter to reslayerfilter
step2:
resbuf * ssCallback (const TCHAR * kword)
{
...
acedSSGet (_T ("_: K"), NULL, kwordlist, reslayerfilter, ss))
mycommand (ss);
}
the problem I have is that after finishing ssCallback, the first acedssget from step1 still works with resfiter
I have thought of 2 workarounds:
1. end entire program after mycommand () is done (use exit) but cad was crash ..
2. using resfilter as global variable and change the resfilter pointer -> reslayerfilter in ssCallback,
however after ssCallback is finished, acedssget from step1 still works with resfilter.
So can I change layer filter option in ssget to run my code only once?
Thanks a lot!.