|
How can i put my program entry in sys menu, ie the menu which appears when we right click on any component whether it is being folder or file
|
|
|
|
|
Google for "VB6 Shell Extension[^]".
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
My friend has created a program in vb6 with the help of api that prompts for passwords if i delete his password protected folder, how can achieve similar one.Is he hooked the api function that deletes the folder or is it something else
|
|
|
|
|
Something else. There is no hook for this, other than file system extensions. This is NOT a task suited for VB6.
You're not really dealing with a folder under this kind of protection. Rather, you're actually looking at an extension of the file system where the files/folders are stored in a hidden file in the directory structure. The extension you write, kind of like .ZIP files in XP are handled, is the interface between NTFS and the file holding the secured files/folders.
But, like I said, VB6 is NOT a good candidate to do this.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
How can i disallow the unauthorized user to uninstall my setup, ie, if he doesn't have the proper passwords which the authorized user has set during installarion to uninstall my setup.
|
|
|
|
|
This should normally be done using Group Policy on the machine/domain.
You would have to implement custom actions in the .MSI setup to do something like this. I would recommend using a professional .MSI builder, such as Wise for Windows Installer, to do this instead of using the rather generic Setup project builder in Visual Studio.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
How can we open a folder? I need to open a window to show the contents of a folder..only could find how to open Files and Create Directories..
|
|
|
|
|
Use the ShellExecute API function
Public Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long
It opens all files and folders
|
|
|
|
|
Do you want to open the folder in an Explorer window, just like typing in C:\ in the Start/Run box? If so, all you need to do is the same thing, either using a Process object (VB.NET), or the other suggestion (VB6).
Process.Start()[^] method
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
hi friends ,
i having a problem in creating a object to ping ip addresses. my application works fine on my comuter but gives an error on other computer:
Library not registered:
i m creating the following object through my application:
===========================================================
Sub Scan(ByVal IP)
Dim status As String
Dim strComputer As String = IP
Dim objShell = CreateObject("WScript.Shell")
'Dim objScriptExec = objShell.Exec("ping " & strComputer & "t")
Dim objScriptExec = objShell.Exec("ping -n 3 -w 1000 " & strComputer)
Dim strPingResults = LCase(objScriptExec.StdOut.ReadAll)
If InStr(strPingResults, "reply from") Then
status = "OK"
MsgBox(strPingResults, MsgBoxStyle.Information)
Else
status = "Not Working"
MsgBox(strPingResults, MsgBoxStyle.Critical)
End If
End Sub
============================================================
can any one help me out to find a way out fo this!
abhinav
|
|
|
|
|
Does the other machine have Windows Scripting Host[^] installed? Preferrably 5.1 or 5.6...
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
thanx ,
windows scripting host was not istalled. i installed it and its working properly.
bi
abhinav
|
|
|
|
|
Hello Everyone!
When we write in a textbox (let's say a username and password for email) and press Enter Key, the button Login/Submit/signIn is "clicked". How can i do this in VB?
Thanks a lot!
|
|
|
|
|
The button's Default value properties =true
<italic>Work hard, Work effectively.
|
|
|
|
|
i want to make small aplication to make letter for company.
the input is date, from who?,and for who? and teks for the letter.
this application do not use database.
i want to ask are this program need data report from vb or crystal report, or only use coding "print code".
any suggestion are big help for me
|
|
|
|
|
What's wrong with using Word, WordPad, or WordPerfect?
I mean, all you said is your writing a letter. Is this letter supposed to go out in a mass-mailing? In that case, you would need a database with all the names and addresses, then you could just use Word's mail merge function.
I guess I don't get what the problem is that couldn't be done with Word...
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
i need to develop a system configuration GUI function.
Thanks for guidance.
|
|
|
|
|
And?
You really need to narrow this question down to something we can answer without guessing at what your having a problem with.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I have some code that I am experimenting with and need to know if it is possible to speed up. I already have working routines which encode SNMP querys into the proper RFC datastream and via Winsock send SNMP GET requests to remote devices via UDP port 161. After the GET query is sent, eventually the Winsock _DataReceive is called (or times out) when the device responds (or doesn't). I then decode the response data block and log the queried info into a spreadsheet.
This is fine until I have a long list of devices to process. This can take hours, especially over a moderatly slow connection. I would like to see if there is a better approach to this task than the method I am using, single threaded send a query and wait for response.
My first elementary idea to enhance this very slow single-threaded process was to just iterate through the IP addresses to be queried, sending GET requests to one device after another , and hoping that Winsock would "catch up" on the responses via some buffer and "keep up" with the sending. I have found that even though I have 2 "DoEvents" in the send loop, still the _DataReceive seems to only be called and receiving data for the very last request in the iteration loop of sends.
Should this be working? If not, what I am doing wrong (in beginner to VB API programming terms). From what I have seen of the UDP Winsock topics of VB Programming examples, there is no way or no need to use the Index function if using UDP. Thanks in advance!!!
|
|
|
|
|
Don, MultiThread It....
You've almost come up with your own answer from your question:
"I am using, single threaded send a query and wait for response."
"This can take hours, especially over a moderatly slow connection."
There is literaly ton's of VB example Code & controls out there about udp MultiThreading & pooling in VB.
(I'm assuming your working in VB 5 or 6 and Not the .Net framework.)
The doEvents() inside of the do loops... bad idea.. I haven't see your code but it would not be a
big surprise, to find it is only recieving the last request.
A lot of the documentation on multithreading is geared toward it's "use" with winsock, have a look thru the MSDN Library CD's that came with the version of VB your using. and MSDN on the net still has a few bit's and pieces on multitheading....in the older versions of VB.(but getting harder to find)
"Google is your best friend:"
http://www.google.com/search?hl=en&q=vb6+udp+MultiThreading[^]
(If you are working in the .Net Framework check out the Threading Class
.NET Framework Developer's Guide
Threading
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconthreading.asp?frame=true
.NET Framework Developer's Guide
Managed Threading Best Practices
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconmanagedthreadingbestpractices.asp?frame=true
.NET Framework Developer's Guide
Thread Pooling
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconThreadPooling.asp
Hope this helps
|
|
|
|
|
Tricky question for you all ....
Added a "Windows Picture and fax viewer"-objekt to my toolbox. (added shimgvw.dll/PREVIEWLib)....
This seems to be a valid objekt. I used the function .ShowFile(strPath)to view a picture and it worked.
Now I want to save that picture. The function SaveAs(strPath) exists in interface IPreview3 ... How do I access that method? Can I apply this interface to my object in any way? The method is there so I hope I can call it.
What do you say professionals? Please help ...
//Maw
|
|
|
|
|
|
And you don't know how to use other interfaces?
//Maw
|
|
|
|
|
No I don't, Like I said in the last message, I haven't used the shimgvw.dll
It looks like a lot of folks are looking for Info on it, when I seached on google, but the functions are undocumented so without a lot of work it may be quite difficult to decode all that it can do. Just playing with it, I got VS to generate a wrapper, but it doesn't wrap the IPreview3 functions.
I did come across a microsoft post about it, on how to use it under the shell but it's not much:
'-------------------------------------
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button2.Click
'Process.Start("c:\windows\explorer.exe", "C:\drums.jpg")
Process.Start("c:\windows\system32\rundll32.exe",
"C:\WINDOWS\System32\shimgvw.dll,ImageView_Fullscreen c:\drums.jpg")
End Sub
Please Apply My Suggestion Above And Let Me Know If It Helps Resolve Your
Problem.
Best regards,
Peter Huang
Microsoft Online Partner Support
'----------------------------------------------------------
and came across this reference for it, But absolutly no documentation what-so-ever.
'------------------------------------------------------------
PREVIEWLib reference for C# and VB.NET
Methods marked * are get/set properties.
PREVIEWLib Classes:
DPreviewEvents
Void OnActualSizePress
Void OnBestFitPress
Void OnClose
Void OnError
Void OnPreviewReady
DPreviewEvents_Event
Void add_OnActualSizePress
Void add_OnBestFitPress
Void add_OnClose
Void add_OnError
Void add_OnPreviewReady
Void remove_OnActualSizePress
Void remove_OnBestFitPress
Void remove_OnClose
Void remove_OnError
Void remove_OnPreviewReady
DPreviewEvents_EventProvider
Void add_OnActualSizePress
Void add_OnBestFitPress
Void add_OnClose
Void add_OnError
Void add_OnPreviewReady
Void Dispose
Void Finalize
Void remove_OnActualSizePress
Void remove_OnBestFitPress
Void remove_OnClose
Void remove_OnError
Void remove_OnPreviewReady
DPreviewEvents_SinkHelper
Void OnActualSizePress
Void OnBestFitPress
Void OnClose
Void OnError
Void OnPreviewReady
IImgCmdTarget
Void ActualSize
Void BestFit
Void GetMode (pdw)
Void GetPageFlags (pdw)
Void NextPage
Void PreviousPage
Void Rotate (dwAngle)
Void ZoomIn
Void ZoomOut
IPreview
Int32 cxImage *
Int32 cyImage *
Int32 printable *
Void Show (var)
Void ShowFile (bstrFileName,iSelectCount)
IPreview2
Void ActualSize
Void BestFit
Int32 cxImage *
Int32 cyImage *
Int32 printable *
Void Show (var)
Void ShowFile (bstrFileName,iSelectCount)
Void SlideShow
Void Zoom (iSelectCount)
IPreview3
Void ActualSize
Void BestFit
Int32 cxImage *
Int32 cyImage *
Void Rotate (dwAngle)
Void SaveAs (bstrPath)
Void SetWallpaper (bstrPath)
Void Show (var)
Void ShowFile (bstrFileName)
Void SlideShow
Void Zoom (iSelectCount)
PreviewClass
Void ActualSize
Void add_OnActualSizePress
Void add_OnBestFitPress
Void add_OnClose
Void add_OnError
Void add_OnPreviewReady
Void BestFit
Int32 cxImage *
Int32 cyImage *
Int32 printable *
Void remove_OnActualSizePress
Void remove_OnBestFitPress
Void remove_OnClose
Void remove_OnError
Void remove_OnPreviewReady
Void Show (var)
Void ShowFile (bstrFileName,iSelectCount)
Void SlideShow
Void Zoom (iSelectCount)
PREVIEWLib enumerated types:
DPreviewEvents_OnActualSizePressEventHandler
DPreviewEvents_OnBestFitPressEventHandler
DPreviewEvents_OnCloseEventHandler
DPreviewEvents_OnErrorEventHandler
DPreviewEvents_OnPreviewReadyEventHandler
'-----------------------------------------------------
Sorry I can't help you out more, But I'm in the middle of a large project now, when I have time, I'll try to check out some more of the functions.
In the meantime if you come across any documentation that would be of interest drop me a note.
progload
|
|
|
|
|
I thought you were talking about the Kodak controls,
so disregard what I said there.
I have not tryed to use the shimgvw.dll/PREVIEWLib yet.
Sorry.
|
|
|
|