Posts by Leonardo • 9,130 points
332 posts
-
2
votes2
answers1118
viewsA: Testing primes in C
Recently I had done an exercise of this (except that in addition to talking about whether you are cousin or not I had to display the sum of pairs, odd and cousins) , I also do ADS rs, well, I edited…
-
6
votes2
answers513
viewsQ: Monetize Windows Forms C#?
Hello, sorry not to be a question directly linked to a language, but I searched a lot and did not find, anyone knows any library like Ad Mediator to be used in Windows Forms? How do I monetize/place…
-
5
votes2
answers2187
viewsQ: Run a Javascript function from the site link?
Example have the link: www.meusite.com.br/index.php?subject=conteudo do assunto;message=teste de mensagem I want to call the function onclick of that button automatically: <input value="Enviar"…
-
0
votes2
answers6996
viewsA: Program that sums/multiplies 2 numbers and what’s between them and prints
The while can wrong.. And the & us printf With for : #include <stdio.h> main(void) { int x = 0, y = 0, cont, pares = 0, impares = 1; while(x >= y) { // trate x como menor que y, como o…
-
2
votes2
answers4104
viewsQ: How do I access and manipulate a web page in the same way that the user would access a web page?
I am planning to make a software that publishes topics in a forum. The start screen will have a menu with all categories and subcategories, when choosing one I will open in the background a link…
-
2
votes1
answer841
viewsQ: Vector union, adding the vectors?
I created the following function to join two vectors (not being able to repeat an equal number), follows the function and the comments showing what I did and the error it is giving: void uniao(int…
-
1
votes3
answers2971
views -
0
votes1
answer157
viewsQ: A 'tremida' effect with while?
I’m using the following code inside a Timer: void dt_Tick(object sender, EventArgs e) { double x, y; int cont = 0; x = tt.X; y = tt.Y; while(cont < 5) { tt.X += cont; tt.Y += cont; cont++; }…
-
4
votes2
answers19877
viewsQ: How to include an action in the HTML5 sign-up button?
I have the following code: <form action="paginas/login.php"> <p id="log">Usuário: </p> <input id="cmpG" type="text" name="usuario"/> <p id="log">Senha: </p>…
-
5
votes1
answer174
viewsQ: Add data to a Mysql table with PHP. What’s wrong?
Initially, I’m new to PHP and SQL, so take it easy if you have shaving in the code. I’m just testing the PHP and Mysql integration, I took an example table from a book and made a quick html page to…
-
0
votes1
answer179
viewsA: Turn this menu into sub-menus?
I looked at another example on the internet and in CSS, I ended up seeing what I had forgotten, which is the sign > which is to indicate what to change in an object when there is an action in…
-
2
votes1
answer59
viewsQ: How to block an Pivot?
On Windows Phone, we have the Pivot structure, which has the Pivotitens, which are tabs (screens) on which the user just navigates by sliding his finger left or right. I’m making an app and…
-
3
votes0
answers33
viewsQ: Sharestatustask identify my app on Facebook?
I’m using the code Microsoft.Phone.Tasks.ShareStatusTask status = new Microsoft.Phone.Tasks.ShareStatusTask(); status.Status = "Eu, " + sNome + ", sou doador de órgãos, baixe o app e seja um também:…
-
3
votes1
answer179
viewsQ: Turn this menu into sub-menus?
I have this vertical menu: <!-- Coluna2 --> <div id="d2" align="right"> <nav id="menu"> <ul id="menu-nav"> <li><a href="cEmpresa.html">Hotel</a></li>…
-
0
votes1
answer102
viewsQ: Update image whenever a new one is chosen?
I’m using the following code: private void foto_Completed(object sender, PhotoResult e) { if (e.TaskResult == TaskResult.OK) { // se teve sucesso na escolha de uma imagem da galeria BitmapImage…
-
2
votes1
answer3469
viewsQ: Fixed background in HTML5 CSS3
I put a background x on my site, with the css code: body { background-image: url("../imagens/back.jpg"); background-color: rgba(64, 118, 182, 1); background-repeat: no-repeat; background-size: auto;…
-
1
votes1
answer52
viewsQ: Page/website manipulation, Windows Phone Silverlight C#?
I see several apps on Windows Phone, which manipulate a site, are usually apps of the sites themselves, such as Tecmundo. It captures elements of the site and adds within the elements of the app,…
-
0
votes1
answer108
viewsQ: How does a mobile browser work?
In mobile browsers we usually have the Mode Fast, aportuguesando had turned 'Modo Rápido', where, it leaves the websites lighter to be loaded, know that part of this is that the site itself…
-
12
votes3
answers14451
viewsQ: Turn the first letter of a string into uppercase?
Example: I have a string "stack exchange", how do I transform your first character, getting "Stack exchange"?
-
4
votes1
answer486
viewsA: Manipulating the opacity of an object(control)
Well, then with the help of @ramaral: .page xaml, part of the panel <!-- Uma 'div'. --> <StackPanel Grid.Row="1"> <StackPanel.Resources> <!-- Animação para ocultar o painel…
-
2
votes1
answer486
viewsQ: Manipulating the opacity of an object(control)
Example: At the push of a button I’ll display a painel editing only its visibility, it works, but is without any effect, is a dry transition. Then I had the idea of pressing the button to display…
-
0
votes1
answer30
viewsA: How to treat Swipe horizontal, Windows Phone Silverlight?
I got it using Wptoolkit: first Install the Wptoolkit package Install-Package WPToolkit 2nd Reference Toolkit in the shampoo:…
-
15
votes2
answers5787
viewsQ: Cut string when it reaches space
Example: I have a string "João da Maquipe", as I do to cut in space, leaving as a result: "João" or "João". whatever. In PHP I know, but in C# I have no idea.
-
1
votes1
answer30
viewsQ: How to treat Swipe horizontal, Windows Phone Silverlight?
First of all, I’m sorry about the post. Well, I’m trying to deploy a hamburger menu in my application Silverlight, I’ve tried Drawer layout, but Visual Studio insists on not recognizing it. So I try…
-
2
votes1
answer111
viewsQ: Alternative to PHP database?
I want to know if there’s a way to save form data, display it and edit it without using a database? Because whenever a software will do integration with database I stop because I do not understand…
-
1
votes3
answers8609
viewsA: Run a Shell Script with double click on Ubuntu
Well an easy way that I found as I had already said, was to create a C program that runs the script and open the terminal. Code in C: (main. c) #include<stdio.h> #include<stdlib.h>…
-
1
votes3
answers8609
viewsQ: Run a Shell Script with double click on Ubuntu
I have a program in Shell, it does the installation and configuration of some programs on Ubuntu, I wanted to know how to compile or make it run when the user double click on it, yesterday had found…
-
1
votes2
answers1368
viewsQ: Responsive form in HTML?
I am using the following code below, where the span controls the description text, the <p> controls a line of form, and the id of input specifies its size, this defined in CSS: #cmpG {width:…
-
6
votes1
answer838
viewsQ: How to print the variable name in C?
Example: I have an entire variable called menino, how do I print on a printf() the name of that variable, i.e. "menino"
-
10
votes4
answers25170
viewsQ: Format a CPF string?
I have a problem, in an app the user type the CPF, but only the numbers because it is very complicated to create mask on Windows Phone, and this CPF will be 'drawn' in a picture of a card, and to…
-
1
votes1
answer164
viewsQ: Save a photo to Windows Phone Gallery?
I am using the following code to save the image in Isolatestorage: String tempJPEG = "/Shared/Media/card.jpg"; using (IsolatedStorageFile myIsolatedStorage =…
-
1
votes2
answers177
viewsQ: Tag <code> recognize language (Wordpress)?
I do not understand much of this tag, but wanted to know how to make a scheme of the style of this site in a Wordpress blog, code example: string demo = "StackOverflow"; if(demo.Lenght == 13) { demo…
-
3
votes2
answers5849
viewsQ: How to cut a string?
Example: nome = "Josénildo da Silva Ramos do Carmo"; Cut to have up to X characters, and look like this: nome = "Josénildo da Silva "; In this case I cut to 20 characters. How do I do this in C#? I…
-
2
votes2
answers9037
viewsQ: CPF mask in the textbox?
I’m using the following code: string numero = ""; private void MaskeditCPF(TextBox txt, KeyEventArgs e) { //Verifica de a tecla digitada foi algo diferente de números ou BackSpace if (e.Key !=…
-
0
votes0
answers61
viewsQ: How to write a string in an image or PDF?
Having a template image or a PDF file with an image template embedded in it, the image could be a card for example, hence in the application have fields TextBox as "Name, CPF and Comment", hence…
-
2
votes1
answer2284
viewsA: Enable or disable navigation buttons C#
First, collect the names of the buttons you want to disable, so click them once and go to Properties and see the Name parameter When to start editing? You must double-click each textBox and in the…
-
4
votes1
answer459
viewsQ: Doubt about FK, Visual Studio database
Hi, I created three tables in a database in Visual Studio, the first two (clientes and produtos) are normal tables with Primary key in column Nome. Then I created the table compras that would have…
-
1
votes1
answer263
viewsQ: How to integrate one database table into another?
Example: A system that records customers, purchases and products, each in a different table. Having a purchase record that must own the fields: Client: indicates which customer already registered…
-
1
votes1
answer2412
viewsQ: Check if e-mail is valid?
I’m using this function to check: public static bool IsEmail(string strEmail) { string strModelo = "^([0-9a-zA-Z]([-.\\w]*[0-9a-zA-Z])*@([0-9a-zA-Z][-\\w]*[0-9a-zA-Z]\\.)+[a-zA-Z]{2,9})$"; if…
-
2
votes2
answers1730
viewsQ: How to update dataGridView by clicking a button?
I’m using an interface where I have the menustrip left and other form to the right, from there on menustrip has the options to novo(form charges nvCli) and busca(form charges nvConsCli), I need when…
-
3
votes3
answers2456
viewsQ: Phone and CPF fields in SQL?
I’m wondering what type of variable to create for the CPF and Phone fields in the database, they should be saved like this: (34) 9652-5214 134.124.214-47 With nchar wouldn’t complicate the search?…
-
0
votes1
answer97
viewsA: Display form in the middle of splitContainer Pinel?
I managed to solve, the problem would be the anchors that were like top,left, then no matter what I did he always carried the contents to the top left. I also added a code to resize my form to stay…
-
0
votes1
answer97
viewsQ: Display form in the middle of splitContainer Pinel?
I’m using the following code to call and show the form in the panel2 of my splitContainer: splitContainer.Panel2.Controls.Clear(); // limpa o painel2 form.TopLevel = false; // redefine lvl do form…
-
4
votes1
answer311
viewsA: Fixed Menu in Csharp
This I can answered (I’m making a form like this). First of all you add one splitContainer on his form, after which you change his properties (from splitContainer and not of panels), and changes to…
-
2
votes2
answers1144
viewsQ: Update function to update date and time?
I have a Windows Form, on the control bar (where you have the Title, close and minimize) I also have the date and time: this.hora.Text = DateTime.Now.ToShortTimeString(); this.data.Text =…
-
2
votes4
answers29520
viewsQ: Print strings in alphabetical order
I’m trying to do here because the user provides 3 name at least so I have to sort these names in alphabetical order, had tried with strcmp, but I didn’t really understand the concept of this…
-
1
votes2
answers2213
viewsQ: Best way to display a form within another form?
I’m in doubt here, I don’t know much about it. 1 I was wearing a form only, with several panel hidden within it, and when the user clicked on some option in the menuStrip I manipulated the…
-
1
votes2
answers399
viewsQ: Sort field or expired date notifications, database
I know nothing about database, I’m using one in Visual Studio (the standard SQL called "Service-based database"), I’ve integrated it into the form and made up the query fields. But there is a field…
-
0
votes2
answers1166
viewsA: How to block a form after certain downtime?
Well achieved, there is only one drawback, it does not record mouse movement as activity, just click, changing fields, etc.. The code is big: Form 'system' public Timer relogio; // cria timer public…
-
2
votes2
answers1166
viewsQ: How to block a form after certain downtime?
Example: After 1 minute of inactivity the 'system' form is disabled and calls a 'login' form, after completing the login it returns to the 'system' form and activates it again.. Or it can be by…