Posts

eclipse - Selenium- WebButton need to be clicked only once in a loop -

i writing selenium script in eclipse adding user application fetching user values excel sheet. in scenarion button "add" exist @ first user addition, once clicked textbox "add_name" appear name need added. in loop second user addition selenium "add" webelement, does'nt exists throwing error. i have used below code elements existance i'm getting below error. please me in this. code used : //click on "add new button" if(browser.findelements(by.id("ext-gen72")).size()!=0){ browser.findelement(by.id("ext-gen72")).click(); } else{ continue rest of steps.... } error:exception in thread "main" org.openqa.selenium.elementnotvisibleexception: cannot click on element (warning: server did not provide stacktrace information)

java - How can add popupMenu to items of listView in Android? -

i want show popupmenu onlongclick in android, write: @override public void oncreate(bundle savedinstancestate) { super.oncreate(savedinstancestate); setcontentview(r.layout.main); listview = (listview) findviewbyid(r.id.listview); adapter = new myadapter(getapplicationcontext()); } @override protected void onresume() { super.onresume(); connecttodatabase(); } private void connecttodatabase() { //create database listview.setadapter(adapter); } my adapter: @override public view getview(final int position, view convertview, final viewgroup parent) { final myholder holder; if (convertview == null) { convertview = layoutinflater.inflate(r.layout.list_row, null); holder = new myholder(); holder.vocabs = (textview) convertview.findviewbyid(r.id.textviewvocabs); holder.points = (textview) convertview.findviewbyid(r.id.textviewpoints); holder.tick = (imag...

php - Additional web page with flexible access control in Moodle -

in moodle 2.6 created new web page external.php , copied root folder on server. web page contains activity (my own html , javascript) must accessible participants of definite courses. have 3 courses (let's call them a, b , c) , want content of web page visible participants of , b, not participants of c. so far managed limit access isloggedin() , works fine, compromise. so question is : possible limit access web page (it not part of course , not intended be) participants of course , b, not c? this code of external.php : <?php require_once('config.php'); // open page if user logged in if (isloggedin()) { $page->set_context(get_system_context()); $page->set_pagelayout('standart'); $page->set_title("experimental page"); $page->set_heading("external"); $page->set_url($cfg->wwwroot . '/external.php'); // adding navbar $page->navbar->ignore_active(); $strhome = "impor...

Access my projects details in Microsoft Project server 2013 errors? -

i have created 1 pwa(project web app) site in ms project server 2013 i created projects on it working fine, but after time when wanted access projects details page it give loop error: an error occurred while opening project. give few minutes , try again. if happens again, contact administrator. can tell cause error in ms project server 2013 web app have checked permissions in groups & categories? simple needing add "open project," "view project site" "view project schedule in project web app" , "view project summary in project center" (in categories). i have had weird permissions issues cause such loops. place start if haven't investigated.

Ionic and angularjs Cannot read property 'scrollWidth' of null -

i have following problem. have 2 same list views, directives inside (i use angularjs). 1 of them runs without issues, other 1 throws following error: typeerror: cannot read property 'scrollwidth' of null @ object.ionic.views.scroll.ionic.views.view.inherit.initialize.options.getcontentwidth (ionic.bundle.js:4081) @ ionic.views.scroll.ionic.views.view.inherit.resize (ionic.bundle.js:4835) @ ionic.views.scroll.ionic.views.view.inherit.run (ionic.bundle.js:4147) @ ionic.bundle.js:39888 @ ionic.bundle.js:21929 @ completeoutstandingrequest (ionic.bundle.js:12022) @ ionic.bundle.js:12330ionic.bundle.js:17696 (anonymous function)ionic.bundle.js:14989 $getionic.bundle.js:21932 (anonymous function)ionic.bundle.js:12022 completeoutstandingrequestionic.bundle.js:12330 (anonymous function) my code pretty long, not posting yet - if there need so, :) hint: i've tested app on phone, , seems cant scroll on error occurs. suggestions? thanks ok, figured out. didnt have d...

c# - How to get available space on Storage Device -

i'm working on windows store app (windows 8.1, using vs2012), , i'm having trouble retrieving available/used space specific storage folder , retrieved storage device. clear, app meant run on desktop, , exchange files usb devices connected through storage device api. this have until now: storagefolder folder = windows.devices.portable.storagedevice.fromid(phoneid); uint64[] info = new uint64[] {}; var properties = await folder.properties.retrievepropertiesasync( new string[] { "system.freespace", "system.capacity" }); if (properties.containskey("system.freespace") && properties.containskey("system.freespace")) { info = new uint64[] { (uint64) properties["system.freespace"], (uint64) properties["system.capacity"] }; } return info; but no success, 'info' empty array. ideas? i've found out doing wrong. storagefolder object representing phone connected desktop. if 1...

python - How to convert a script to UTF-8 -

i have sikuli/python script works good. since dutch have same letters in our alphabet english alphabet. now there 1 letter have not occur in alphabet, used in dutch grammar. ë. sikuli falls on becuase doesn't belong in english alphabet. have belgium custumers might use french on in future. how can make scripts @ utf-8, , not @ ascii (what seems default)? in order specify module shall include utf-8 encoding, use encoding declaration in header or footer of file, per pep 0263 : # -*- coding: utf-8 -*-