16,012,107 members
Sign in
Sign in
Email
Password
Forgot your password?
Sign in with
home
articles
Browse Topics
>
Latest Articles
Top Articles
Posting/Update Guidelines
Article Help Forum
Submit an article or tip
Import GitHub Project
Import your Blog
quick answers
Q&A
Ask a Question
View Unanswered Questions
View All Questions
View C# questions
View C++ questions
View Javascript questions
View Visual Basic questions
View .NET questions
discussions
forums
CodeProject.AI Server
All Message Boards...
Application Lifecycle
>
Running a Business
Sales / Marketing
Collaboration / Beta Testing
Work Issues
Design and Architecture
Artificial Intelligence
ASP.NET
JavaScript
Internet of Things
C / C++ / MFC
>
ATL / WTL / STL
Managed C++/CLI
C#
Free Tools
Objective-C and Swift
Database
Hardware & Devices
>
System Admin
Hosting and Servers
Java
Linux Programming
Python
.NET (Core and Framework)
Android
iOS
Mobile
WPF
Visual Basic
Web Development
Site Bugs / Suggestions
Spam and Abuse Watch
features
features
Competitions
News
The Insider Newsletter
The Daily Build Newsletter
Newsletter archive
Surveys
CodeProject Stuff
community
lounge
Who's Who
Most Valuable Professionals
The Lounge
The CodeProject Blog
Where I Am: Member Photos
The Insider News
The Weird & The Wonderful
help
?
What is 'CodeProject'?
General FAQ
Ask a Question
Bugs and Suggestions
Article Help Forum
About Us
Search within:
Articles
Quick Answers
Messages
Comments by glbrt.gds (Top 32 by date)
glbrt.gds
1-Feb-21 18:21pm
View
Yes, I have placed a comment there but this is a very old article and nobody responds.
I thought maybe asking a new questions could obtain some help.
glbrt.gds
24-Feb-12 14:09pm
View
But an administrator can close a service.
glbrt.gds
23-Feb-12 14:54pm
View
Then.. I don´t know what to do, I´m trying to do this because I need to keep executing an application all the time in background, It´s an app that I´ve been doing since some time ago, it is not a malware or something like that.It has some visual parts, that´s why it cant be a windows service. Do you know other way to do that?
glbrt.gds
23-Feb-12 8:05am
View
The security issue occurs when I use impersonation, from that impersonation account with administrator right. I'm using the same procedure with the same user(exactly the same code) to do others administration things like writing registry keys.
glbrt.gds
22-Feb-12 8:43am
View
I'm really sorry because maybe I don't understand you, what you mean with "to put the logging code into App1", I've trace it and the error that app1 is throwing is Invalid directory name, I've even verify into my App1 using Directory class members or FileInfo class and the path to the file, even the file is correct and it is there, I've checked it all from my App1. Other thing that I've done is Impersonated(I don't know if It is correctly written) in my App1 I've logged as administrator and then the message error change to: You have not enough privileges, one of the craziest thing I've ever seen, how couldn't have enough privileges from an administrator account... :(
glbrt.gds
21-Feb-12 15:43pm
View
My App1 doesn't log anything, at least I'm not doing it.
If I logged as administrator or any account with administrative privileges it goes fine, all works, then how could be the direction wrong, am I getting crazy?.
glbrt.gds
21-Feb-12 15:35pm
View
Yes, I'm using the full path (c:\windows\file.exe) for example, I've checked it out.Even I've used it explicity It seems really extrange to me, it just doesn't work.... sorry my English please.
glbrt.gds
20-Feb-12 16:25pm
View
The first app is executed but it can´t execute the second, it´s realy frustrating for me. :(
glbrt.gds
20-Feb-12 16:23pm
View
Sorry, I wasn´t clear, let me be more specific.
My real problem is how to execute a program and let it run on a diferent user than the logged user, I´ve create a Local User account with administrative rights and over this account I want to let my program run. Then i wrote a program that shuld execute the other that I want to run over a diferent account, the account that I´ve told before. This first program(the one that execute the real program) is execute at windows start, to do that I put in windows registry in Run key the direction of the first-one, this first-one is execute at windows start but it throw an error when it tryes to execute the real program over a diferent account than the logged-one, the code seems like that:
try
{
Process proc = new Process();
proc.StartInfo.FileName = "programdir";
proc.StartInfo.UseShellExecute = false;
proc.StartInfo.UserName = "localAdministratorUser";
proc.StartInfor.Password = GetPass();
proc.Start();
}
catch(Exception e){e.Message();}
The error message is: Invalid directory name
But the directory name is fine, if I just execute by clicking this first .exe, it execute the 2nd very well over the account that I´m specifying in the code. It´s realy crazy to me.
glbrt.gds
1-Feb-12 10:22am
View
I mean easy to use.
You are totally right, probably taking an existing file system and modifying the header section resolve the problem. but even doing this, I will have to implement reading and writing operation,.. or not ?
glbrt.gds
31-Jan-12 16:17pm
View
Yes JackDigler, you are right, but to do it transparent to the final user is the problem
glbrt.gds
31-Jan-12 15:31pm
View
Lot of thanks Espen
glbrt.gds
31-Jan-12 14:52pm
View
As I have said before English is not my native language, I am really sorry if I have hurt someone here, that was not my intention, I am very sorry.
And you are totally right, if I am asking for help then it won't be my own project, sorry about that. I promise to post here the solution if I find it somewhere else.
Sorry about "file format", it was my mistake, what I want to do is not a new file format,but a file system, I've understand that.
I will read about encryption, I will be back after then.. thanks.
glbrt.gds
11-Jul-11 14:36pm
View
Thanks everybody,i've other task to do , but when i finish i'll begin again with my memory io project...
glbrt.gds
8-Jul-11 17:10pm
View
I restarted my computer and WinHex show the same, my code is not changing my memory... I've not proved reading after write.. I'm gonna do ..
Thanks for your comment..
glbrt.gds
8-Jul-11 12:52pm
View
sorry but...I don't know what else do you need to know..I'm just wondering if are there some others ways to modify a byte array...just that...the error on my sample (in my loop) was just a writing error posting it... just that, it is not an error that I've in my real code...
glbrt.gds
8-Jul-11 10:55am
View
Someone has told me about Buffer.BlockCopy
glbrt.gds
8-Jul-11 10:50am
View
Marcus you are rigth,I just wrote it by memory and the loop condition is bad as you said........but do you think that is one of the correct ways to do that? I mean. one of fastest..?
glbrt.gds
8-Jul-11 9:42am
View
sorry ......... i only need to know how to modify my array of bytes the other work is already done...I've read already the bytes and etcc..... "only need to know if is there a way to modify my array no using the common for(int i = 5 ; i++) bytearray[i] = otherarray[k++];
glbrt.gds
8-Jul-11 8:50am
View
and mine too ............ :) ..thanks.. but.. what is the fastest way to modify my byte buffer array???
glbrt.gds
7-Jul-11 14:19pm
View
Richard my code is really the same but when i was trying read i was using a lot of numbers(bytes) to read(testing) not a multiple of 512 bytes............
My problem now is writing into the memory. for example: if i want to write a number of bytes begining at the position 43 (offset), how could I do this when I only can move the pointer(using SetFilePointer function) a multiple of 512 bytes......
glbrt.gds
6-Jul-11 13:16pm
View
Richard......... thanks for comment..someone in this forum http://social.msdn.microsoft.com/Forums/en-US/csharpgeneral/thread/cb8364ad-46ec-4af5-8630-36804d7de473 helped me up
glbrt.gds
5-Jul-11 12:24pm
View
Hello Richar... I'm trying with SetFilePointerEx() with files it works fine but with my flash memory it doesn't move the pointer. it is always at the begining of the flash's bytes. a can't get for example an offset of 512 bytes ..it always begin with offset of 0
glbrt.gds
1-Jul-11 16:18pm
View
but if the flash is formated using FAT32 it use little endian... I'm using c# not C..
My problem now is using SetFilePointer API function.. trying to move the pointer more than 2 gigabytes.
glbrt.gds
1-Jul-11 14:23pm
View
Now I have to try to write instead of reading...you know.. change the values within..I'm gonna test WriteFile API function, i hope it works
glbrt.gds
1-Jul-11 14:19pm
View
:D ... Richard I mean Spanish not Castellano from Castilla, in Spanish when wanna say something clear we use the frase....."Decirlo en castellano"..it means that it's said in clear Spanish.. :D ..but... do you speak Spanish??
Sorry.. but what answer below? .......
glbrt.gds
1-Jul-11 14:17pm
View
Yuri.. thanks for your post..i was just making some tests
glbrt.gds
1-Jul-11 13:22pm
View
Richar... I've already solved that..... with the function ReadFile my buffer is obtained as an array of bytes. then those bytes i've to convert to decimal if i want to understand in "Castellano"(that is my wonderful native language :) ) what number (of a section of those bytes) it really is.
glbrt.gds
30-Jun-11 14:05pm
View
Richard.. I just deleted the " uint size = GetFileSize(ptrFile,IntPtr.Zero);" line and wala..my buffer got filled like a glass of water....
but I've another problem, I'm trying to read some things like the number of bytes per cluster and others from File Allocation Table in my memory.. the problem is that I don't know how to convert the bytes that represent this nomber into decimal...how can i do this..
glbrt.gds
30-Jun-11 10:32am
View
Richard MacCutchan.......it's working !!!.. I checked it out and it is already working. thanks a lot..
glbrt.gds
30-Jun-11 8:56am
View
Hello Richard..thanks for your comment....
How can i be sure of that? i've prove the same code with CreateFile but using "\\\\.\\A:" instead of "\\\\.\\u:" and I could see my floppy drive responding(physically)....drive u: is my flash memory plugged in an USB port.
Otherwise...the call to the GetFileSize funcion always return the same number value no matter if I'm calling CreateFile with "\\\\.\\u:" or "\\\\.\\A:"
glbrt.gds
23-Jun-11 16:08pm
View
The flash that i'm talking about is the normal memory flash that people usually use daily, you know to transport photos and the normal things that normal users usually do, not embedded or sd.......but are you saying that we normally haven't privileged to access to the flash ?.......
To be exact:
I have a group of flash memories, not sd, just the common memories that we use to transport information all the time. the problem is that i need to mark this flash and asociate this mark with some password that the user of the flash could has.. I could do this encripting some file and copying it like normal data into the flash memory, but the problem is that it is a common file that any user could see and erase as you said, i need to achieve that in a low level(I guess) that the common user could not see the mark and even could not erase it by normal ways
Show More