Vote count: 1 Make a function code in JAVA which gets 2 parameters(x and y, that are 2 integers), and retu how many times y goes into x? for example: If I'll put x=5 and y=2, the retu will be 2. If I'll put x=2 and y=5, the retu will be 0. asked 32 secs agoCodicos Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I have an scenario where i want to render product image on markers. But all the details of that particular product (like its .obj , .mtl file) will come from webservice. So is it possible to render image of product at runtime using artoolkit ? Is dynamic image rendering is possible using artoolkit native ? asked 41 secs agoBhavika Solanki Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I want to develop hybrid mobile app for Employee Location Tracking. I am using HTML5 an Jquery Mobile for development. Requirement- App should able to trace location of employees on specified time period,Location should be store in cloud or any central database. I am having following queries - Can i develop an app using HTML5 and jquery mobile + cordova/phonegap,which will run in background to get the location of user. What is optimum way to get location of user with less battery drainage. What if user is not having inteet coection or network problem for couple of hours,how to store it's data into my server? asked 31 secs agoAlok Chandra Shahi Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I have defined this class: class numbers { private: int i{ 0 }; int j{ 0 }; public: int get_i() const; int get_j() const; void set_numbers(int, int); numbers(int x, int y); numbers(); }; Now in the int main(void) what is the difference between the following statements: numbers numberA; numbers numberA (); numbers numberA {}; numbers numberA (10,20); numbers numberA {10,20}; Basically I am confused between the use of () empty or otherwise vs {} empty of otherwise. Both of them seem to give same result, but with programming languages things usually have very specific meanings thus this question. I notice that using numberA (10,20); causes 2 calls to initializer than numberA {10,2...
ادامه مطلبVote count: 0 I want to see the number of customers who only shopped in one specific store during a specific period, so I wrote the following SQL: SELECT COUNT (DISTINCT CARD_NUMBER) FROM WHERE DATE BETWEEN ‘XXXX-XX-XX’(DATE) AND ‘XXXX-XX-XX’(DATE) AND STORE_NUMBER = 1234; What if these customers (card holders) shop in other store chains? I couldn’t use AND CARD_NUMBER NOT IN… Because we have too many stores. Any syntax that could be used here to solve this problem? asked 50 secs agoYuan Yuan Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I am trying to achieve page navigation (Next and back button) using Angular UI-route. I am changing the state from controller and it is getting changed on view as well but is not redirecting me to that page. I have achieved it using button click using $state.go('stateName') but I want use Bootstrap page for this . here is my code $stateProvider .state('settings', { url: '/settings', templateUrl: 'templates/settings.html' }) .state('settings.profile', { url: '/profile', templateUrl: 'templates/profile.html', controller: 'ProfileController' }) .state('settings.account', { url: '/account', templateUrl: 'templates/account.html', controller: 'AccountController' }) .state('settings.p...
ادامه مطلبVote count: 0 I am working to create a a matrix of missingness for a SQL database consisting of 5 tables and nearly 10 years of data. I have established ODBC coectivity and am using the RODBC package in R as my working environment. I am trying to write a function that will output a count of rows for each year for each table, a count and percent of null values (values not present) in a given year for a given table, and a count and percent of missing (questions skipped/not answered) values for a given table. I have written the code below, trying to get it to work on one variable then tuing it into a function once it works. However, when I run this code, the count for total, missing and null va...
ادامه مطلبVote count: 0 I am working on a script (which is in Python) for doing some management on our Magento environment.Now I am wondering if I can create categories with assigned ID. I think this might be impossible due to key constraints. But is there a way?Just putting category_id in the parameter list in catalog_category.create, it does not work, it just skips the parameter.The main reason of wanting this is because I need to know the category ID in order to create the subcategories.I do know the Magento API retus the ID of the created category.But, I have no way of knowing what subcategories are supposed to go to that created category.(Or I can rewrite a load of code, which I am not too fond o...
ادامه مطلبVote count: 0 For a given ActiveCell in Excel how can VBA retu the Table Name that appears in the properties grouping that becomes visible when the Table Tools Design tab is activated. So for example in the immediate window: ?ActiveSheet.ListObjects(2) Table3600 but if I select a cell (potentially within a table) I can't seem to find a property that will either retu the selected cell's containing table's name. I am trying to either store the retu value or to state that the current cell is not in a table. TIA (This seems very fundamental yet I am nowhere) asked 37 secs agoStumpedObject Let's block ads! بخوانید...
ادامه مطلبVote count: 0 i cant really figure out this problem , lets say that on the page there is a form with one input in it , if you submit the form then the text that you save will be sent to the database and stored now , i would like to get user location: Longtitude Latitude whenever he submits the form , now i found that its better to get the location using Javascript and then send it to the server using AJAX so basicaly when i submit the form the text of input is stored in the database and , i marked the submit button with id "submit" and i want to use ajax with jquery so: $.ajax({ url:'update_the_last_form_submit_data.php', type:'POST', data:{lat:lat,lat:lat} success:, error: }); so what i wan...
ادامه مطلبVote count: 0 So this is my task: gulp.task('prod', function() { browserify({entries: [ 'resources/assets/js/app.js' ]}) .transform("babelify") .transform(envify({ NODE_ENV: 'production' })) .bundle() .pipe(source('all.js')) .pipe(buffer()) .pipe(sourcemaps.init({loadMaps: true})) .pipe(uglify()) .on('error', gutil.log) .pipe(gulp.dest('public/js/')); }); yet the console still sais: all.js:30 Waing: It looks like you're using a minified copy of the development build of React. When deploying React apps to production, make sure to use the production build which skips development waings and is faster. See [url here that stack doesn't like] for more details. So I am confused. Whats the deal? ask...
ادامه مطلبVote count: -1 Hello, Right now i am in the process of "Sorting Files" to get the correct information from the latest file. I am using a different but a good way in my mind to do this process. I seem to always get the retu of 1 from this code but there are over 100 files. The code is VB.NET And it is easy to read after i just explained what its for. Dim lineread As Integer = 1 Dim pageread As Integer = 1 Private Sub ScanPage_Tick(sender As Object, e As EventArgs) Handles ScanPage.Tick Dim database As String = Environment.GetFolderPath(Environment.SpecialFolder.Desktop) If My.Computer.FileSystem.FileExists(database & "DEVFOURM" & "S1P" & pageread & ".txt") = True Then pageread += 1 Exit Sub E...
ادامه مطلبVote count: 0 I've this xml file: variable comment _enabled True _coordinate (8, 235) _rotation 0 id freq value 4.17e9 I've to modify the attribute of value (value = 4.17e9 i mean). I've wrote this function to read it : grc_radio_program_name = kwargs['grc_radio_program_name'] file_extension = kwargs['file_extension'] tree = ET.ElementTree(file=os.path.join(os.path.expanduser("~"),"test",grc_radio_program_name+file_extension)) root = tree.getroot() for block in root.findall('block'): if block.findtext('key') == 'variable': for param in block.findall('param'): if param.findtext('key') == 'id' and param.findtext('value') == 'freq': for param in block.findall('param'): if param.findtext('key') ...
ادامه مطلبVote count: 0 Download not working in python? I've written a simple python program, to get files from FTP location but when executing it's give [Ero 13] Permission denied message. My code is as follows. Any idea why is this ? import ftplib from ftplib import FTP, error_perm def getFTPDir(dirpath): f = ftplib.FTP(ip, useame, password) try: f.cwd(dirpath) nameList = f.nlst() oldest = nameList[0] newest = nameList[-1] newest = oldest newDirPath = dirpath +'/'+ newest print f.cwd(newDirPath) subNameList = f.nlst() for i in range (len(subNameList)): f.cwd( newDirPath + '/' + str(subNameList[i]) ) nameList1 = f.nlst() filename = nameList1[i] print "downloading..............", filename f.retrbinary...
ادامه مطلبVote count: 0 I have problem with how to sort by line on my text file. For example i have one file the name is a.txt on the a.txt i have 4 line:DATE,EVENT,TYPE,2016-07-01 14:43:17,Communication lost,UPS exteal event2016-07-01 14:38:59,UPS power on immediately,UPS exteal event2016-07-01 14:38:04,AC recovery,Input event so i want to attempt on another file, but on the another file the line must be sorted by datetime, the new datetime is on the last line and Date, Event, Type still on the first line Thank You, i hope somebody can help me. asked 15 secs agoJ-Protop Let's block ads! بخوانید...
ادامه مطلبVote count: 0 The method setId, setGravity, setMargins works fine but method setBackground, setColor, setLayoutParams, setTextColor, setTextSize is not working on api 19 the app get crashed but works in api 21 how to solve this issue. asked 1 min agodaya nidhi Let's block ads! بخوانید...
ادامه مطلبVote count: 0 Is there a way to limit uploads to a path in Firebase Storage by group? asked 27 secs agoecalvo Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I'm using wso2 LDAP coector for retrieving data from ldap server.so getting following error when calling my service.try to searchEntry operation. { "error": { "errorMessage": "Missing 'equals'", "errorCode": 7000001 } } Also I refer wso2 documentation for above scenario. any reson for this ? asked 10 secs agodanera Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I'm trying to install an sql server silently and after the completion of installation I need to check it's exit code, which is created in sqlsetup log file and as per the exit code the script will prompt user that the installation is successful or not. asked 47 secs agoSupriya Let's block ads! بخوانید...
ادامه مطلبVote count: 0 Our project requries a custom sorting. And upon diving into the net I come up with the following SQL statements. SELECT CountryName FROM dbo.Country ORDER BY CASE WHEN CountryName = 'INDIA' THEN '1' WHEN CountryName = 'CHINA' THEN '2' ELSE CountryName END ASC Can someone help me have this in Slick? I already have this kind of query contriesQuery.map(_.CountryName) .sortBy(c => { val srt = { Case If(x.CountryName = "India") Then 1 Case If(x.CountryName = "China") Then 2 Case Else CountryName } srt.asc }) .result But it always showing me an error org.postgresql.util.PSQLException: ERROR: for SELECT ORDER BY expressions must appear in select list asked 43 secs agounderscore_05 Let...
ادامه مطلب