Posts

performance - is better to call a inBuilt VBA function with or without its Class? -

some inbuilt functions in vba can called or without class. 1 better use? when calling sub/function vba.format(date,"yy-mm-dd") 'or format(date,"yy-mm-dd") also when dimensioning variable, class might or might not used. in case, better? dim xmldoc msxml2.domdocument60 'or dim xmldoc domdocument60 i tend use class , name in case has defined function/sub/type bring conflicts. how performance? when having great amount of codes , procedures, 1 or other have impact on performance/speed? there other aspect take in account when deciding whether use 1 form or other? if understanding correctly, , if understanding of vba correct, doesn't make difference in terms of performance whether qualify property or method library prefix. don't think necessary qualify objects referenced within vba library (if indeed working in vba environment, opposed .net using interop), when set external references (such msxml2, or scripting), might beneficial ...

c++ - why does my cin loop never end? -

in following code, if user inputs not int , program goes infinite loop. why happen, , should fix it? #include <iostream> #include <string> using namespace std; int main() { int i; char str[100]; while (!(cin >> i)) { gets(str); cout << "failure read!" << endl; } cout << "successful read!" << endl; return 0; } clear error state: int main() { int i; char str[100]; while (!(cin >> i)) { cin.clear(); cin.getline(str,100); cout << "failure read!" << endl; } cout << "successful read!" << endl; return 0; }

What is difference between a job and a process in Unix? -

what difference between job , process in unix ? can please give example ? http://en.wikipedia.org/wiki/job_control_%28unix%29 : processes under influence of job control facility referred jobs.

Rails 3: How to trigger a form submission via javascript? -

i have form part submits normal form, don't want set in form_tag :remote => true option. however, under circumstances i'd able have javascript function post form if had been posted :remote => true. need in javascript accomplish this? i tried works, if form has remote => true, remove data-remote attribute submit w/ javascript ie $('input').click(function(){ $('#form').removeattr('data-remote') }); i'm guessing opposite work ie if form doesn't have remote => true do $('input').click(function(){ $('#form').attr('data-remote',true)});

jquery ui - I have one Textbox and inside the textbox i want the text which user cannot be deleted -

i have 1 text box in text inside text box should not deleted , after text cursor has placed ex: textbox: "http://" should available , text in quotations cannot deleted inside textbox , cursor should after quotations. thanks in advance, vara prasad.m add input field: onchange="testedit(this)" and have javascript function this: function testedit(field) { if (field.value.substring(0, 8) != "http://") { field.value = "http://" + field.value.substring(8); } } however, sloppy. best way put http:// in label outside text box. if in text box, should input. putting inside text box, confusing users. good luck.

osx - GTK+ macport on os x -

i installed gtk2 through macport on os x 10.6 when tried use library #include <gtk/gtk.h> it still doesn't recognize , give me compile errors. know how install gtk2? if have pkg-config on system, try: pkg-config --cflags gtk+-2.0

jsf - Icefaces Actionlistener Pass Parameter To Another Page -

i have have icefaces datatable , when user clicks row, pass row's value page. value row's 1 column primary key. planning use how can this? thanks * follow up ** kindly suggest approach following right passing paramter icefaces datatable page. i have following in jsf page <h:commandlink actionlistener="#{bean.setselecteditem}"> and in bean of setselecteditem(actionevent event) method have following code selectedrows.put(datatable.getrowindex(), true); (selectedrows of map<integer, boolean> selectedrows = new hashmap<integer, boolean>(); list<class> selectitems = new arraylist<class>(); (int index = 0; index < datalist.size(); index++) { if (isselectedrow(index)) { selectitems.add(datalist.get(index)); } } newbean.method(selectitems); selectitems.clear(); selectedrows.clear(); corre...