topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Friday April 26, 2024, 9:48 pm
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - KodeZwerg [ switch to compact view ]

Pages: prev1 ... 20 21 22 23 24 [25] 26 27 28 29next
601
Another Location could be "c:\Windows\Web\" with its sub-folders.

C:\Users\RG\AppData\Roaming\Microsoft\Windows\Themes\CachedFiles\
Thats same for non-Firefox Wallpaper functions.

602
I have not figured out given solutions, if still needed, i could create a CopyBiggestToNewLocation type of app.

603
How about a safer reverse way, automatic copy biggest file inside sub-folder to new location, if you afterwards wish, delete that source folder.

604
Hello 4wd,

in reply to your last Post, yeah, this sound reproducable to me and will solve my issue with Windows and privileges.
A new hunt for me begun to figure out "how-to" delphi that, thanks alot for your help!

605
Sorry my fault, you have no testing Application, just a resulting Application from Post #2.
I've attached a Demo Application that execute "Batch.bat".
Two modes in Demo are supported, the first called forced privileges, in that mode i want to achieve "IsElevated = False".

Three non-working examples included in Batch.bat.

If someone find out how, please let me know! Thank you for support!
You will need those files:
RunAsTester.exe (from Post #2)
RunAsDemo.exe (inside this archive)
Batch.bat (inside this archive)

Please edit Path inside Batch.bat to your Filesystem before loading RunAsDemo.exe.
The RunAsDemo.exe will not require admin privileges at start, all managed from within Demo.

606
Thank you for reply, sadly it doesnt do the job.
IsAdministrator = False
IsAdministratorAccount = True
IsUACEnabled = True
IsElevated = True
Only the "IsAdministrator" Flag will be set to false, i badly need "IsElevated" as False.
Or with other words, thank you for helping to terminate one flag, just one left to go and i am done  :Thmbsup:

607
UrlSnooper / Re: Feature Request: IP Info for URL Snooper
« on: August 12, 2018, 05:01 PM »
Here is some Demo Code to show you what i like to have as a result. I commented things a bit to understand what i do.
Code: Delphi [Select]
  1. uses WinInet;
  2.  
  3. // here i define a record to hold information
  4. type
  5.   ApiResults = record
  6.     Status: UTF8String;
  7.     Country: UTF8String;
  8.     CountryCode: UTF8String;
  9.     RegionState: UTF8String;
  10.     RegionName: UTF8String;
  11.     City: UTF8String;
  12.     Zip: UTF8String;
  13.     Latitude: UTF8String;
  14.     Longitude: UTF8String;
  15.     CityTimeZone: UTF8String;
  16.     ISP: UTF8String;
  17.     Organization: UTF8String;
  18.     NumberName: UTF8String;
  19.     DNS: UTF8String;
  20.     MobileConnection: UTF8String;
  21.     ProxyConnection: UTF8String;
  22.     QueryIP: UTF8String;
  23.     ErrorMessage: UTF8String;
  24.   end;
  25.  
  26. // this is an api function call to perform GET, optimized to handle ASCII or UNICODE data
  27. function GetUrlContentData(const Url: string): UTF8String;
  28. var
  29.   NetHandle: HINTERNET;
  30.   UrlHandle: HINTERNET;
  31.   Buffer: array[0..1023] of byte;
  32.   BytesRead: dWord;
  33.   StrBuffer: UTF8String;
  34. begin
  35.   Result := '';
  36.   NetHandle := InternetOpen('Delphi 2009', INTERNET_OPEN_TYPE_PRECONFIG, nil, nil, 0);
  37.   if Assigned(NetHandle) then
  38.     try
  39.       UrlHandle := InternetOpenUrl(NetHandle, PChar(Url), nil, 0, INTERNET_FLAG_RELOAD, 0);
  40.       if Assigned(UrlHandle) then
  41.         try
  42.           repeat
  43.             InternetReadFile(UrlHandle, @Buffer, SizeOf(Buffer), BytesRead);
  44.             SetString(StrBuffer, PAnsiChar(@Buffer[0]), BytesRead);
  45.             Result := Result + StrBuffer;
  46.           until BytesRead = 0;
  47.         finally
  48.           InternetCloseHandle(UrlHandle);
  49.         end
  50.       else
  51.         raise Exception.CreateFmt('Cannot open URL %s', [Url]);
  52.     finally
  53.       InternetCloseHandle(NetHandle);
  54.     end
  55.   else
  56.     raise Exception.Create('Unable to initialize Wininet');
  57. end;
  58.  
  59. // in here the main work is done, input will be splitted up to prior defined fields of record
  60. function GetUrlContent(const Url: string): ApiResults;
  61. var
  62.   tmp: UTF8String;
  63.   sl: TStrings;
  64. begin
  65. // api offers XML and other stuff, but LINE needs no anything, just a stringlist :)
  66. // by manual calling desired fields you get more informations, so i add them all in here
  67.   tmp := GetUrlContentData(Url+'?fields=status,country,countryCode,region,regionName,city,zip,lat,lon,timezone,isp,org,as,reverse,mobile,proxy,query,message');
  68. // the field "reverse" aka DNS-resolver consumes most of inet time, you may add option on/off for this feature
  69.   try
  70.     sl := TStringList.Create;
  71.     sl.Text := tmp;
  72. // by reading api i figured out how results could be
  73. // first received line will be "status", so i add it to its proper record field
  74.     Result.Status := sl[0];
  75. // now i compare if "status" contain "fail" to set up later received lines correct
  76. // feel free to use it as template
  77.     if Pos('fail', LowerCase(Result.Status)) > 0 then
  78.       begin
  79.         Result.ErrorMessage := sl[1];
  80.         Result.QueryIP := sl[2];
  81.       end
  82.       else
  83.       begin
  84.         Result.Country := sl[1];
  85.         Result.CountryCode := sl[2];
  86.         Result.RegionState := sl[3];
  87.         Result.RegionName := sl[4];
  88.         Result.City := sl[5];
  89.         Result.Zip := sl[6];
  90.         Result.Latitude := sl[7];
  91.         Result.Longitude := sl[8];
  92.         Result.CityTimeZone := sl[9];
  93.         Result.ISP := sl[10];
  94.         Result.Organization := sl[11];
  95.         Result.NumberName := sl[12];
  96. // the field "reverse" aka DNS-resolver consumes most of inet time, you may add option on/off for this feature
  97.         Result.DNS := sl[13];
  98.         Result.MobileConnection := sl[14];
  99.         Result.ProxyConnection := sl[15];
  100.         Result.QueryIP := sl[16];
  101.       end;
  102.   finally
  103.     sl.Free;
  104.     tmp := '';
  105.   end;
  106. end;
  107.  
  108. // here comes what GUI perform
  109. procedure TForm1.Button1Click(Sender: TObject);
  110. var
  111. // in here all results are local stored
  112.   ThisLines: ApiResults;
  113. begin
  114. // after reading api, i choosed smallest method to perform the GET and qualify results, the LINE variant
  115. // replace the second 'ip-api.com' with target IP/Domain, this is just example
  116.   ThisLines := GetUrlContent('http://ip-api.com/line/' + 'ip-api.com');
  117. // Memo1 is a Delphi Control to draw text
  118.   Memo1.Lines.Add('Status: '+ThisLines.Status);
  119. // determine what record type we have, "fail" or "success"
  120.   if Pos('fail', LowerCase(ThisLines.Status)) > 0 then
  121.    begin
  122.      Memo1.Lines.Add('ErrorMessage: '+ThisLines.ErrorMessage);
  123.      Memo1.Lines.Add('QueryIP: '+ThisLines.QueryIP);
  124.    end
  125.    else
  126.    begin
  127.      Memo1.Lines.Add('Country: '+ThisLines.Country);
  128.      Memo1.Lines.Add('CountryCode: '+ThisLines.CountryCode);
  129.      Memo1.Lines.Add('RegionState: '+ThisLines.RegionState);
  130.      Memo1.Lines.Add('RegionName: '+ThisLines.RegionName);
  131.      Memo1.Lines.Add('City: '+ThisLines.City);
  132.      Memo1.Lines.Add('Zip: '+ThisLines.Zip);
  133.      Memo1.Lines.Add('Latitude: '+ThisLines.Latitude);
  134.      Memo1.Lines.Add('Longitude: '+ThisLines.Longitude);
  135.      Memo1.Lines.Add('CityTimeZone: '+ThisLines.CityTimeZone);
  136.      Memo1.Lines.Add('ISP: '+ThisLines.ISP);
  137.      Memo1.Lines.Add('Organization: '+ThisLines.Organization);
  138.      Memo1.Lines.Add('NumberName: '+ThisLines.NumberName);
  139.      Memo1.Lines.Add('DNS: '+ThisLines.DNS);
  140.      Memo1.Lines.Add('MobileConnection: '+ThisLines.MobileConnection);
  141.      Memo1.Lines.Add('ProxyConnection: '+ThisLines.ProxyConnection);
  142.      Memo1.Lines.Add('QueryIP: '+ThisLines.QueryIP);
  143.    end;
  144. end;

608
UrlSnooper / Feature Request: IP Info for URL Snooper
« on: August 12, 2018, 03:49 PM »
Feature Request: IP Info for URL Snooper

If you have time to implement in the Context Menu of URLs a "Show IP Info" resulting in a tiny Window showing some lines of text, that would be nice.
http://ip-api.com offers a free web-api to fullfill such request. One of many, theres api-documention that explain all.

I could provide working Delphi Code if it helps to see what i miss.
If you do not like that idea it is okay aswell.

Thanks in advance. :Thmbsup:

609
Still no answer, i guess it is impossible than.

@Admin, feel free to delete/remove thread, thanks.

610
Screenshot Captor / Re: Show name of printer in popup box
« on: August 12, 2018, 02:43 PM »
Your problem belongs to Microsoft not to Mouser. It calls standard Windows Print Dialog, not a selfmade one.
I suggest you install a Printer-Driver that show an Notification Icon to switch default device.

611
There are libraries for that.
Okay, thank you again for answering. :Thmbsup:

612
Will you later integrate at least a "does domain exists" function or will it never evolve to such?
Thank you for answering Mr. Tuxman.

613
Living Room / Re: Dawn of the Microcomputer: The Altair 8800
« on: July 29, 2018, 10:55 PM »
In Germany the breakthrough of Microcomputer has started with (around 1980) Commodore 64 / C-64 / C64 where 64 dont meant 64bit, it stand for 64 kB :)

614
    #include <vldmail.h>
   
    int main(void) {
        /* ... your code ... */
       
        vldmail validator = validate_email(L"foo@bar.quux");
        if (0 == validator.success) {
            /* success == 0 means that something was wrong. */
            printf(L"Validating foo@bar.quux failed: %ls\n", validator.message);
        }
       
        /* ... more of your code ... */
    }
Does your library perform online check to see if its valid or how does it work?

615
iptables & ddos-protection, a good information resource for actual things that happen here.
I hope you master soon this more than sad situation. Best wishes!

616
Right,

Disabling updates is not an option. Making updates non-automatic might work, but is a poor option.
I don't want to have to remember to go and check for + install updates - I want it to be a fairly automatic process.

wraith808: that link is just Microsoft really, really, REALLY not getting what people are complaining about >_<
In my case (Auto-Update OFF / metered connection) i use WSUS Offline Update to do such action.
= How to REALLY stop ******* Windows Update on Win10? = solved with that. Or am i wrong?

617
I wanted to give a warning out before bad things happen to unexperienced Windows Users. In past that point i missed to write, so take care what you do.
Unexperienced run blind the batch and wonder why certain Windows-Things may suck afterwards.

For me it was always enough to configure No-Auto-Update with metered Network setting.

618
Other things that i do not understand fully yet:
If EndDLL("PSDcalc_for.dll") Then MsgBox "It worked!"
Translated in my world this would mean: If "something is TRUE" then "show Text"
BUT "EndDLL" is defined
Public Function EndDLL(DllReturnValue As Long) As Boolean
wich contain
hInst = DllReturnValue

Heres my problem:
You call EndDLL with a "String" but EndDLL wants "Long" as input.... VB or your Text is very confusing me :)

And yeah, comment that "EndDLL" out of Exit-Code.

619
FYI: I still get sometimes this with my browser Screenshot - 26_07.jpg

620
Hello again, i did not found eMail, but a link with similar content to block Microsoft Servers.
Stop Windows 10 spying on you using just Windows Firewall

Hope it helps, take care!

edit
Attention!
Above is not mentioned to be (mis-)used by beginners since it go systemdeep without restore!! You must know what you do!

621
Thank you for informing us, i'd thought i got network connection errors today.
Since i am able to connect and read/write again, i hope you catched those "where is smiley for *nuke them*" ....

Thanks for hard work and never give up!!! Please!

622
Hello Sir, did you tried all THIS methods?

In my (bad english) words:
Turn Auto-Updates OFF from System Settings and Configure Network Connection as "metered" <<< MOST IMPORTANT!
More is not needed and works 100% for me since day 1.

If above does for some reason do not work for you, i can search my eMails for a "block all microsoft" firewall rule.
Afterwards no telemetry etc is sended and you can not argue with Microsoft Services anymore (like Cortana and such)

623
What i suggest you should do:

Post your code where you define that dll call. (like i did in my previous post " ExampleCall () ")
Post your complete exit-routine code. <<< if i guess right, there should be the error.

That way more people can help and we do not need to guess whats wrong.

624
Hello again, as more i read about VB and working with DLL as more confused i get.
Many informations lead into a direction that VB need some kind of special prepared DLL. (i think wraith808 link write something similar)
Above i think isnt needed since your App can work with Dll.

But how you work with Dll, there is something very buggy.

I've been reading on Microsofts Visual Studio Site (in German) and its so much input, you could fill books with it.
Very complicated for me to a) translate all that expert stuff to english and b) understand it by myself.
It would make no sense if i copy and paste "something" and have no clue what i pasted.
Thats far out of my scope, i am sorry!

With the programming language i use, i just type something like this, thats all i need:
function ExampleCall ( SomeParameter: ParameterType ): ResultType; stdcall; external 'Some.dll';
This would enable me to use "ExampleCall" from "Some.dll", i do not need to (un)load that dll, all happen automatic this way.

I feel sorry for not being able to help any deeper.

625
What i see is absolutely a no-go. No wonder that Application hang if you try to kill Processes at end. A DLL aint a process.
CreateProcess() TerminateProcess() and such are made to run/kill external Applications, not DLL.

I have no time ATM, will come back later and post how to correct call a DLL with VB. (i have to search "how-to" for VB.... not my territory)

Ps: with Delphi i used stdcall convention and it worked.

Pages: prev1 ... 20 21 22 23 24 [25] 26 27 28 29next