Posts

I was wondering how to create several rows in a box using the fbox command in latex -

this basic question, cant find answer question.... create box looks like: ___________________ |hello1 | |hello2 | |hello3 | |__________________| i have tried fbox command in latex. text on 1 line , not several. \fbox puts frame round content, not paragraph box. need \parbox inside \fbox \documentclass{article} \begin{document} \fbox{\parbox{\textwidth}{% hello1\\ hello2\\ hello3 }} \end{document}

c++ - How to properly interrupt a QThread infinite loop -

i'm done implementing go program human can interrupt @ time software order play. basically, i've got algorithm running in thread has @ every moment "best move" available, keeps on improving. my question : how correctly interrupt thread in infinite loop? i've tried few things, , resolved : class myworker : public qobject { q_object public: myworker(); ~myworker(); public: threadcontrol * getthreadcontrol(); public slots: void work(); private: void endofcomputation(); private: threadcontrol * threadcontrol; } notice don't subclass qthread : class threadcontrol : public qobject { q_object public: threadcontrol(); public: bool getabort(); parameter getparameter(); void setparameter(parameter & param); public slots: void setabort(bool b); private: qmutex mutex; bool abort; parameter param; }; and, finally, infinite loop coded : void myworker::work() { // ... forever...

user interface - How to use a CTabCtrl in a MFC dialog based application? -

i need expected simple - create tab control has 2 tabs, implying 2 modes of operation app. when user clicks on tab1, he'll presented buttons , textboxes, , when clicks tab2, other input method. noticed there ctabctrl class thats used in mfc add tabs. however, once added tab ctrl using ui designer, couldn't specify how many tabs there'll using property window. searching on net, found examples of them required derive ctabctrl , create 2 or more child dialogs etc , write own custom class. question is, since want basic, why couldn't using familiar add event handler/add member variable wizard , handle else inside app's class ? surely, default ctabctrl class can useful without needing derive ? the mfc tab control pretty thin wrapper on win32 tab control, works in pretty way describe. window, provides switching between child windows using tabs. happens, in straight win32 useful way work. if want more sophisticated switching between individual windows, using...

.htaccess - setting up 301 redirects: dynamic urls to static urls -

we using template-based website , hoping move site static urls. our domain stay same. understand using 301 redirects in .htaccess file preferred method -- , 1 has highest chance of preserving our google rankings. i still new @ , having hard time figuring out proper way code all. over hundred of our pages indexed. have similar url different pageids: http://www.realestate-bigbear.com/nav.aspx/page=%2fpagemanager%2fdefault.aspx%2fpageid%3d2020765 some link out provided content, ex. /realestatenews/default.aspx then there many flow main featured listings page: /listnow/default.aspx down specific properties.. propertyid changes /listnow/property.aspx?propertyid=2048098 would simple set of codes work... following.... redirect 301 /nav.aspx/page=%2fpagemanager%2fdefault.aspx%2fpageid%3d2020765 www.realestate.bigbear.com/searchbigbearmls.htm or need entirely different? this depends on trying do. example posted, of unique pages going go sing...

Running WatiN using Scheduled task or Windows service -

my watin automation doing file download working fine when executed in command window normally. failing timeout exceptions or filedownload dialog not found exception when executed scheduled task. is possible execute watin exe (with filedownload dialog handler) scheduled task. if no there other way execute schedule task. note: have seen blogs referring running watin using cc.net. so, possible run above scenario using cc.net pointers cc.ent documentation , working let me know if u require more informations.. for work, have enable desktop interaction , have user logged in. if running on server, here's a clever way start process , make sure has desktop access.

vb.net - How can i get the DomainName\AccountName with the .NET Framework? -

how can domainname\accountname as string .net framework? system.security.principal.windowsidentity.getcurrent().name.tostring()

tsql - Dynamic SQL, sp_executesql, and rebuilding the dynamic sql statement - Part 1 -

part 1: in article, "dynamic search conditions in t-sql...for sql 2005 , earlier", erland sommarskog gives example of how use dynamic sql sp_executesql. http://www.sommarskog.se/dyn-search-2005.html#sp_executesql select @sql = -- 19 'select o.orderid, o.orderdate, od.unitprice, od.quantity, -- 20 c.customerid, c.companyname, c.address, c.city, -- 21 c.region, c.postalcode, c.country, c.phone, -- 22 p.productid, p.productname, p.unitsinstock, -- 23 p.unitsonorder -- 24 dbo.orders o -- 25 join dbo.[order details] od on o.orderid = od.orderid -- 26 join dbo.customers c on o.customerid = c.customerid -- 27 join dbo.products p on p.productid = od.productid -- 28 1 = 1' -- 29 ...