|
ok i solve it.
I forgot a very old and very useful rule... heh.
All good now. Thank you.
modified 1-Jan-19 13:41pm.
|
|
|
|
|
You're welcome!
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
another devil now - with progressBarX1_Click.
And...Resolved!
I wish i can Delete this thread. The "delete" link Button from the top, is showing this time(Haleluia), but is greyed out and I can not use it. Probably is a thing for those with money. I am thinking too much probably.
But seriously, this is a ... (my) fart thread, that i wish to smudge it.
modified 1-Jan-19 15:10pm.
|
|
|
|
|
No, it's simply that you can't delete any post with a response: it would leave the response "hanging in midair" with no support, screaming and wetting itself in terror (Posts are scared of heights, as I'm sure you know).
And of course you have no authority to delete other peoples posts, so you can't get rid of it!
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Hi,
I have a WSDL provided by a third party supplier that i would like to use in my C# code however currently i'm struggling to find a way to use the WSDL.
I looked at their example and they're using ASMX file in the C# project in order to invoke the methods exposed by the service.
If i wanted to use methods available in the WSDL in the C# project, how do i import the WSDL into the project?
modified 31-Dec-18 9:13am.
|
|
|
|
|
The obvious answer is, talk to the supplier.
|
|
|
|
|
Yes thats right. Sorry i didn't make it clear.
What's the correct way of importing the WSDL into the C# project? Is it using Web Reference or Service Reference?
|
|
|
|
|
No, what Richard suggested was: "talk to the supplier"
I.e. the supplier of the WSDL, not a random website that probably isn't at all familiar with that particular service...
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
And a trivial Google (using part of your last sentence as the search string) would have told you anyway: importing the WSDL into the C - Google Search[^]
The top link is even expanded for you!
Quote: Start Visual Studio.
On the File menu, select New > Project. ...
In the New Project dialog box, enter the desired settings, then click OK.
In the Solution Explorer pane, right-click on References. ...
In the Add Web Reference dialog box, enter the URL to the web service's WSDL document.
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Statistical program. Not a keyllogger. For me, to know how much of my life I waste by tapping without meaning into the keyboard;}}
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Diagnostics;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace StatisticChar
{
public partial class Form1 : Form
{
private GlobalKeyboardHook _globalKeyboardHook;
public void SetupKeyboardHooks()
{
_globalKeyboardHook = new GlobalKeyboardHook();
_globalKeyboardHook.KeyboardPressed += OnKeyPressed;
}
private void OnKeyPressed(object sender, GlobalKeyboardHookEventArgs e)
{
if (e.KeyboardState == GlobalKeyboardHook.KeyboardState.KeyDown)
{
var znak = $"{(char)e.KeyboardData.VirtualCode} {e.KeyboardData.VirtualCode}";
if ((e.KeyboardData.VirtualCode >= 112) && (e.KeyboardData.VirtualCode <= 123))
{
znak = "F" + (e.KeyboardData.VirtualCode - 111).ToString();
}
if ((e.KeyboardData.VirtualCode >= 96) && (e.KeyboardData.VirtualCode <= 105))
{
znak = (e.KeyboardData.VirtualCode - 96).ToString();
}
if (e.KeyboardData.VirtualCode == 144)
{
znak = "NumLock";
}
if (e.KeyboardData.VirtualCode == 111)
{
znak = "/";
}
if (e.KeyboardData.VirtualCode == 106)
{
znak = "*";
}
if (e.KeyboardData.VirtualCode == 109)
{
znak = "-";
}
if (e.KeyboardData.VirtualCode == 107)
{
znak = "+";
}
if (e.KeyboardData.VirtualCode == 107)
{
znak = ",";
}
if (e.KeyboardData.VirtualCode == 13)
{
znak = "ENTER";
}
if (e.KeyboardData.VirtualCode == 192)
{
znak = "`";
}
if (e.KeyboardData.VirtualCode == 9)
{
znak = "tabulator";
}
if (e.KeyboardData.VirtualCode == 20)
{
znak = "capslock";
}
if (e.KeyboardData.VirtualCode == 160)
{
znak = "LewyShift";
}
if (e.KeyboardData.VirtualCode == 162)
{
znak = "ctrl";
}
if (e.KeyboardData.VirtualCode == 91)
{
znak = "win";
}
if (e.KeyboardData.VirtualCode == 32)
{
znak = "spacja";
}
if (e.KeyboardData.VirtualCode == 37)
{
znak = "←";
}
if (e.KeyboardData.VirtualCode == 39)
{
znak = "→";
}
if (e.KeyboardData.VirtualCode == 38)
{
znak = "↑";
}
if (e.KeyboardData.VirtualCode == 40)
{
znak = "↓";
}
if (e.KeyboardData.VirtualCode == 8)
{
znak = "backup";
}
if (e.KeyboardData.VirtualCode == 161)
{
znak = "prawyShift";
}
if (e.KeyboardData.VirtualCode == 93)
{
znak = "ppm";
}
if (e.KeyboardData.VirtualCode == 45)
{
znak = "insert";
}
if (e.KeyboardData.VirtualCode == 44)
{
znak = "printscreen";
}
if (e.KeyboardData.VirtualCode == 19)
{
znak = "pause";
}
if (e.KeyboardData.VirtualCode == 166)
{
znak = "back";
}
if (e.KeyboardData.VirtualCode == 36)
{
znak = "home";
}
if (e.KeyboardData.VirtualCode == 35)
{
znak = "end";
}
if (e.KeyboardData.VirtualCode == 46)
{
znak = "delete";
}
if (e.KeyboardData.VirtualCode == 33)
{
znak = "pageUp";
}
if (e.KeyboardData.VirtualCode == 34)
{
znak = "pagDown";
}
if (e.KeyboardData.VirtualCode == 163)
{
znak = "PrawyCtrl";
}
if (e.KeyboardData.VirtualCode == 1)
{
znak = "LeftClick";
}
if (e.KeyboardData.VirtualCode == 2)
{
znak = "RightClick";
}
Statystyki[znak] = Statystyki.ContainsKey(znak) ? ++Statystyki[znak] : 1;
}
}
public new void Dispose()
{
base.Dispose();
_globalKeyboardHook?.Dispose();
}
private DateTime data_zbierania_statystyk;
private static readonly Dictionary<string, int> Statystyki = new Dictionary<string, int>();
public Form1()
{
_globalKeyboardHook = new GlobalKeyboardHook();
SetupKeyboardHooks();
var dt = DateTime.Now;
data_zbierania_statystyk = new DateTime(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, 0);
Timer timer = new Timer
{
Interval = 1 * 10 * 1000
};
timer.Tick += new EventHandler(Timer_Tick);
timer.Start();
Timer timer2 = new Timer
{
Interval = 1000
};
timer2.Tick += new EventHandler(Timer2_Tick);
timer2.Start();
InitializeComponent();
}
private void Timer2_Tick(object sender, EventArgs e)
{
richTextBox1.Text = StatystykiJakoText();
}
void Timer_Tick(object sender, EventArgs e)
{
Saves();
}
void Saves()
{
var dt = DateTime.Now;
var now = new DateTime(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, 0);
if (data_zbierania_statystyk < now)
{
data_zbierania_statystyk = now;
string sb = StatystykiJakoText();
string path = $@"O:\statystyki{dt.Year}-{dt.Month}-{dt.Day}.txt";
File.AppendAllText(path, sb);
richTextBox1.Text = "";
richTextBox1.Text = sb.ToString();
}
}
private string StatystykiJakoText()
{
var sb = new StringBuilder();
sb.Append(Environment.NewLine);
sb.Append($"Statystyki za dzień: {data_zbierania_statystyk}{Environment.NewLine}");
foreach (var literka in Statystyki)
{
sb.Append($"{literka.Key} - {literka.Value}{Environment.NewLine}");
}
return sb.ToString();
}
}
}
However, there is still a problem:
1. I do not catch every character, eg right alt, F Mode
2. Does not catch characters written in some programs, eg Notepad ++?
Is anyone able to say why this is happening and how to fix it?
3. How to handle shortcuts eg ctrl + c, ctrl + v?
4. How to protect against pressing the key, if we keep it and do not let it go?
modified 30-Dec-18 11:16am.
|
|
|
|
|
Quote: Statistical program. Not a keyllogger.
Quote:
namespace Keylogger
Um. I suspect it might be ...
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
it's just the name of the project in English.
in my own I had written: Program Statystyczny
|
|
|
|
|
Your namespace doesn't agree with you...
|
|
|
|
|
I have already corrected that there were no connections.
And the data is for me, for my needs;)
For proof I can show collections of other statistics such as mouse movement and data transmission over the network from the program: "KalendarzXP" or OmCounter (until computer work) - this is unfortunately programs of Polish programmers
|
|
|
|
|
You're not "counting"; you're "logging".
What do you take us for?
Stick to Mavis Beacon for your "stats".
"(I) am amazed to see myself here rather than there ... now rather than then".
― Blaise Pascal
|
|
|
|
|
|
|
AFAIK, it's not possible - just ignoring that it would make a for difficult user experience to use it, there is no mechanism I can think of that allows you to rotate a DGV 90 degrees and still use it as a DGV. It's possible to rotate PrintDocument output by 90 degrees, but not display controls.
Why would you want to? Do your users habitually rotate their monitors to look at them?
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
I meant that I would have a lot of (256) columns and it is not convenient to view them in the current version of DGV. More conveniently the opposite ...
|
|
|
|
|
|
Hi guys.
I'm doing a program to update applications that we only use in my home. And what I want to do is through the network to find if there is an "X" file on the different PCs, and if there is a return of your route, otherwise it will not return anything.
Could someone help me?
regards
|
|
|
|
|
What do you mean by a return of your route ?
We can’t stop here, this is bat country - Hunter S Thompson RIP
|
|
|
|
|
He means the fully qualified path to the file.
".45 ACP - because shooting twice is just silly" - JSOP, 2010 ----- You can never have too much ammo - unless you're swimming, or on fire. - JSOP, 2010 ----- When you pry the gun from my cold dead hands, be careful - the barrel will be very hot. - JSOP, 2013
|
|
|
|
|
So, what have you done/tried. Tell us about your code, show us some code, describe what works or what breaks. What is your "network" like ?
We can't read your mind !
«Where is the Life we have lost in living? Where is the wisdom we have lost in knowledge? Where is the knowledge we have lost in information?» T. S. Elliot
|
|
|
|
|
First, you need to be able to identify all of the machineson your network, or provide a way for the user to specify what remote drive(s) to search.
Second, you should use UNC paths instead of shares because shares can be deleted (or Windows could simply lose them), while UNC paths always exist as long s the machine is turned on and connected to the network.
After those two things, the act of finding a file on a remote drive is beyond trivial.
".45 ACP - because shooting twice is just silly" - JSOP, 2010 ----- You can never have too much ammo - unless you're swimming, or on fire. - JSOP, 2010 ----- When you pry the gun from my cold dead hands, be careful - the barrel will be very hot. - JSOP, 2013
|
|
|
|