Posts by Renan Lazarotto • 1,025 points
44 posts
-
3
votes2
answers916
viewsA: How to integrate the awesome font in Laravel?
Even installing via NPM, you still need to reference the files in your project. Font Awesome itself has in its documentation a reference to how to use icons using a package manager. That question…
-
0
votes1
answer22
viewsQ: Where based on the value of a variable
I am working on migrating an API to a new platform and this includes migrating queries that were previously written directly into the code to functions in the database. One of the problems I’ve been…
sql-serverasked Renan Lazarotto 1,025 -
2
votes1
answer134
viewsQ: Group similar elements of an Array in PHP
I am working on a project for my company where I need to group elements of an array that have values in common. My array is as follows: Array ( [0] => stdClass Object ( [strRespAciona] =>…
phpasked Renan Lazarotto 1,025 -
0
votes3
answers4298
viewsQ: Count values from one column based on a filter from another column
I have a spreadsheet where I have some data. From this data, I need to count the repeating values of a column SE the value of the cell in the same row but in another column is equal to a given…
excelasked Renan Lazarotto 1,025 -
4
votes2
answers112
viewsQ: What is the best way to monitor a value in a database?
I am working on an item management system, in which I need to constantly monitor the amount of items available. Upon reaching a predefined minimum threshold, the system shall issue the item in an…
-
1
votes2
answers916
viewsQ: Layout occupying the entire screen
I’m working on a project where I have a screen that contains some elements separated by different layout types. All these elements needed to be grouped within a single LinearLayout so that I could…
-
1
votes2
answers1195
viewsQ: Remove shadow between Toolbar and the rest of the layout
I’m working on a project where I need to put one CalendarView next to a Toolbar. The problem is that the Toolbar gets a shadow on the bottom, where I’d like you to join the CalendarView. I tried to…
-
2
votes2
answers531
viewsQ: What is the correct way to get the device date?
This is a relatively simple question, but one that has broken my mind a lot. I need to pick up the date and time at a certain point in my app’s run, but I don’t know what is the most recommended way…
-
3
votes3
answers126
viewsQ: Is it safe to keep the context of an app in a Singleton?
I have the habit of keeping the context of an Android app saved inside a Singleton as follows: public class Global { private static Global instance; private Context context; public Global() { }…
-
1
votes1
answer1035
viewsQ: Doubt with style files (Styles.xml) on Android
On Android it is possible to make multiple style files, one for each version of the level of API (16, 19, 21...), for each type of screen (xxxdp) and etc. But a question arose: there is some kind of…
android-layoutasked Renan Lazarotto 1,025 -
0
votes1
answer858
viewsQ: Material style button bar layout
I’m trying to create a button bar at the bottom of the screen ("Cancel" and "Save" buttons similar to the one used by Google Drive: However, nowhere in the Material guidelines have I found anything…
android-layoutasked Renan Lazarotto 1,025 -
4
votes2
answers5861
viewsQ: Change the line color of an Edittext
I have a Layout simulating a PIN screen (type one lockscreen), where I have a EditText. I’m using the AppCompat v21 to be able to use the Material style elements. However, I want to set the…
-
0
votes1
answer586
viewsQ: When to use a Fragment instead of an Activity
I’m working on a project where I’m making use of several fragments and only one activity. Giving a researched, I saw that many places suggest the use of fragments when the code of the same will be…
-
2
votes1
answer258
viewsA: Hide Actionbar in one Ragment but show in another
After a little research, I realized that apparently it is not possible to hide the ActionBar in just one Fragment without affecting others. Thus, I solved the problem as follows: public static void…
-
2
votes1
answer258
viewsQ: Hide Actionbar in one Ragment but show in another
I am working on a project that is being done virtually all based on fragments. So far, I’ve only got one activity and 4 fragments, within which I need only one of them not to have the ActionBar.…
-
4
votes1
answer841
viewsQ: Difference between calling the Fragment call and a new instance
I’m working on a college project where I made an app that uses Ragments. I’ve always been used to creating a Fragment as follows: // imports ... public class LoginFragment extends Fragment { public…
-
0
votes1
answer336
viewsQ: Toast text out of alignment
I am working on a small project for the college and came across this when using a Toast: I have no idea what made Toast look like this. Has anyone experienced a similar problem? Edition: This is the…
androidasked Renan Lazarotto 1,025 -
2
votes2
answers14672
viewsQ: Refresh the contents of a page without reloading it
I am working on a project for college where I would like to update the content of a page without reloading it. The page in question has its content received from a script PHP, which in turn picks up…
-
3
votes1
answer1277
viewsQ: Error with SOAP webservice using PHP
I’m trying to learn how to make one webservice using this tutorial: http://www.sitepoint.com/web-services-with-php-and-soap-2/ But my server is returning the following: Error Response not of type…
-
4
votes1
answer937
viewsQ: Problem with 8 digit hexadecimal colors - Android
I am working on an app where I am trying to follow Google’s Material design guide. On this page, it is recommended to use the black color (#000000) with 87% opacity as the color of the main texts.…
-
0
votes1
answer1646
viewsQ: Creating a customized and animated toggle
I am creating an app for Android in which I am using a ToggleButton as one of the interface elements. I am trying to make it have images instead of the button itself and there is a transition…
-
1
votes1
answer913
viewsQ: How to translate Strings from a . resx file?
I am creating a small application in C# and would like to translate it into English, because I intend to publish it and most of the target audience speaks English. Searching, I discovered that I can…
c#asked Renan Lazarotto 1,025 -
3
votes1
answer4700
viewsQ: Uniting several SQL queries in a single query
I have a 'mission' in my work, where I need to unite some queries in a single query. But I have no idea how I can do this so that everything I need is returned using just one query to the bank. Is…
-
0
votes2
answers652
viewsQ: Calling a function when a Fragment is closed
I have a activity who calls a fragment which is displayed in the form of a DialogAlert. But when that fragment is closed, need a method of Activity be called. What is the best way to do this? The…
-
1
votes2
answers77
viewsA: How to leave the fields with the same style?
Search about styles and themes (Styles and themes). You can create a specific style for what you want and apply it to all the elements you want. More about the subject, click here.…
-
2
votes2
answers813
viewsQ: Creating a double array (not a multidimensional array)
I need to pass two values of the kind double for a AsyncTask in my application. I tried to define an array using the following code: double latitude = location.getLatitude(); double longitude =…
-
1
votes1
answer451
viewsQ: Use interface implementation in a Fragment
I’m trying to implement an interface I created within a fragment, but I’m not succeeding. My fragment is being defined with the following code: package fragments; import…
-
1
votes1
answer4140
viewsQ: Return an address using Google Maps API
I’m finishing an application where I need to use the Google Maps API for two things: select an address from the user’s choice (example: user navigates to the desired address and chooses it) and…
-
1
votes1
answer98
viewsA: Help with app and update
One simple way is to use an Sqlite database to store this video list. In this case, the application would read the data from the BD videos and display them, so you would only need to update the BD…
-
2
votes1
answer149
viewsQ: Prevent animation from repeating when changing the orientation of the device
I’m working on a screen that contains an animation that is repeated every time the screen is rotated. I searched but found no precise information of what I need to do so the animation does not…
-
2
votes1
answer144
viewsQ: Android - take the splash screen from the back-stack
I’m finishing a college job where an app should present a splash screen and then a login screen. I would like it, as soon as the splash screen was finished, it would go out of history. The structure…
-
5
votes1
answer5160
viewsQ: Pin a footer element to the footer
I am doing a job for the college where we were instructed to take advantage of the new semantic tags of HTML5 (Nav, Section, footer, etc). I’m having trouble fixing the footer at the bottom of the…
-
0
votes1
answer1057
viewsQ: Problem updating Listactivity using a custom adapter
I’m working on an app where I populate a ListActivity using data from a SQLite created by the program itself. When adding items in the database, the list is automatically updated, but when removing,…
-
4
votes1
answer3881
viewsA: Manage back button between Ragments
Apparently the problem solved itself, but then I understood how the FragmentManager, solving the problem as follows: Inside Fragment 1, I call Fragment 2, adding it to the stack: FragmentTransaction…
-
1
votes1
answer3881
viewsQ: Manage back button between Ragments
I’m working on an app for the college where I’m using Fragments for all my screens, for reuse purposes. The problem is that I cannot control the behavior of the back button between the Fragments.…
-
3
votes1
answer470
viewsQ: Problem with transition animation between Fragments
I’m working on an app that consists of several fragments and decided to put animations between them. Looking, I found that I should use the command setCustomAnimations to get the desired result, but…
-
5
votes2
answers586
viewsQ: Error with CSS, bar appears where it should not
I’m working on a college project where I need to make a website for a pizza place. I’m making an embryo of the site, but when I add the navigation menu, a bar appears on top of the div which should…
-
0
votes1
answer155
viewsQ: Add reference to a contact in an Edittext
I am working on a project where I need a form in which it is possible to place a Contact. How can I add a reference to a calendar contact? This is possible? My idea was something like: user touches…
androidasked Renan Lazarotto 1,025 -
1
votes1
answer313
viewsA: Problem to the popular a Listview
After a lot of work, I managed to solve it in the following way: 1.First I changed the function query getUserId of: Cursor cursor = db.rawQuery("SELECT ? FROM " + table_user + " WHERE email=?", new…
-
1
votes1
answer313
viewsQ: Problem to the popular a Listview
I need a popular ListView that is using a custom adapter in my app but nothing happens, the list simply goes blank. Here is the adapter: package adapters; import java.util.List; import…
-
2
votes1
answer222
viewsQ: Updating the text of a Toast without waiting for it to disappear
I’m creating an app for testing and I’m using toasts to validate my tests. I usually define a Toast as follows: Toast.makeText(this, "Texto que eu quero que apareça",Toast.LENGTH_SHORT).show(); Is…
androidasked Renan Lazarotto 1,025 -
8
votes1
answer660
viewsQ: Communication between Fragment and Activity
I’m making an Android app that uses time and date switches (Datepicker and Timepicker), which are displayed in the form of Fragments. When the user sets the desired time, I need it to be passed from…
-
0
votes1
answer262
viewsQ: Application closing in user interaction after being summarized
I’m playing with an app that controls the flash from my mobile phone, but the same force close as soon as the user interacts with the application, after it has been summarized. For example: I opened…
androidasked Renan Lazarotto 1,025 -
0
votes1
answer624
viewsQ: Synchronize Listview Ids with database
I’m working on a college project where I use a database and a Listview. The problem is when I need to recover the data from one of the Listview items, as I cannot synchronize the Listview Ids with…
androidasked Renan Lazarotto 1,025