|
The documentation DOES provide an answer to your question.
MSDN wrote: lParam
The low-order word specifies the x-coordinate of the cursor. The coordinate is relative to the upper-left corner of the client area.
The high-order word specifies the y-coordinate of the cursor. The coordinate is relative to the upper-left corner of the client area.
lParam = x or (y << 16)
|
|
|
|
|
I'd give this a 5, but post voting is broken for Safari.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
All that remains to be done is you buying a real computer, or Chris fixing the Safari voting bug
|
|
|
|
|
ROTFL - well, if IE was not crap, I'd use IE for CP, in XP, on my Mac.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
I'm happy running FireFox on Vista, except for some companies (banks) and governmental organizations that only support IE.
Did you consider FireFox on Mac?
|
|
|
|
|
I am aware that it exists, but I've never hated Safari like I hate IE, so I've never felt enough motivation to install it. I ran FF on my old PC.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
|
Hi, I have tried this every which way but loose (maybe I should have tried that one as well!)
I need to select rows from a datatable based on a date column but no matter how I format the date it just errors.
The sample in MS help does not work either.
Microsoft Example
'Presuming the DataTable has a column named Date.
Dim expression As String<br />
expression = "Date > '1/1/00'"<br />
Dim foundRows() As DataRow<br />
<br />
' Use the Select method to find all rows matching the filter.<br />
foundRows = table.Select(expression)
My Code
dteTStart = Me.m_dteCurrentGraphStart.AddDays(-1)<br />
dteTEnd = Me.m_dteCurrentGraphEnd.AddDays(1)<br />
strFilter = "TradingDate > '" & dteTStart.ToString("MM/dd/yyyy") & "' AND TradingDate < '" & dteTEnd.ToString("MM/dd/yyyy") & "'"<br />
Dim drowData As DataRow() = m_dtblROIData.Select(strFilter)
The error message
Cannot perform '<' operation on System.DateTime and System.String.
Does any one have any idea how to get round this?
Thanks
|
|
|
|
|
try using Between
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Use the System Format date that available in Control Panel.
Same think use in code with the format statement.
Ex.
dat=format(today,"dd-MMM-yyyy")
and if u have error in access data statement use SQL Query.
|
|
|
|
|
Hello guys.
I m created Treeview & Menu in ASP.net using vb lang. now i m try to write code for treeview for expend and Collapse. But it is showing Error
And one more thing I m not yet assigned link.
I m receiving following error:
Server Error in '/web page1' Application.
--------------------------------------------------------------------------------
Invalid postback or callback argument. Event validation is enabled using <pages enableeventvalidation="true"> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.ArgumentException: Invalid postback or callback argument. Event validation is enabled using <pages enableeventvalidation="true"> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[ArgumentException: Invalid postback or callback argument. Event validation is enabled using <pages enableeventvalidation="true"> in configuration or <%@ Page EnableEventValidation="true" %> in a page. For security purposes, this feature verifies that arguments to postback or callback events originate from the server control that originally rendered them. If the data is valid and expected, use the ClientScriptManager.RegisterForEventValidation method in order to register the postback or callback data for validation.]
System.Web.UI.ClientScriptManager.ValidateEvent(String uniqueId, String argument) +261
System.Web.UI.Control.ValidateEvent(String uniqueID, String eventArgument) +83
System.Web.UI.WebControls.TreeView.RaisePostBackEvent(String eventArgument) +119
System.Web.UI.WebControls.TreeView.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +31
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +32
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +244
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3837
|
|
|
|
|
non-bugging Errors wrote: I m created Treeview & Menu in ASP.net
Then why are you posting this in the VB.NET forum?
You'll get answers faster in the correct forum
|
|
|
|
|
Hi all...
I am using VS2005 to create a web browser program(in vb).
I want to know that how can I access and store the selected text of webbrowser.
As selected text of a text box can be retrieved by using
str=textbox1.selectedtext
how can I store selected text of webbrowser in str? (str is string)
Thanks.
Gagan
|
|
|
|
|
Hey all, not 100% sure if this is the right forum for Visual Basic Scripting but i can only assume it is.
Basicly put my current script will let you type a directory into an input box
e.g C:\Temp\Files
then it will rename every file in there with the extension .txt to .bak
while all that works great,
i have subfolders and it will not change the extensions of the txt files in them
here is my current code for you to look at
FILEPATH=inputbox("What is the directory?")
strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set FileDirectory = objWMIService.ExecQuery _
("ASSOCIATORS OF {Win32_Directory.Name='" & FILEPATH & "'} Where " _
& "ResultClass = CIM_DataFile")
For Each objFile In FileDirectory
If objFile.Extension = "txt" Then
strbak = objFile.Drive & objFile.Path & objFile.FileName & "." & "bak"
objFile.Copy(strbak)
End If
Next
msgbox "Complete."
im pretty sure i have to use Win32_SubDirectory.Name but i have tried to implement it and failed
so can someone please help me to get my script to change subfolder file extensions?
|
|
|
|
|
I don't believe there is a built in mechanism for simulating following the file system hierarchy, so you'll have to create your own. You need to put the logic of renaming all the .txt files to .bak in a folder into a sub and then use recursion to walk the directory structure. So, you'll have a sub that accepts either a folder object or a string that is the path (your choice) and then within the sub you'll process all the files and then have it call itself for each folder within the supplied path. Here's some pseudocode:
sub ProcessFolder(folder)
foreach(file in folder.files)
rename file...
foreach(folder in folder.folders)
ProcessFolder(folder)
end sub
From your main script you'll just call the sub with for the root level of folder and then let it handle everything from there.
Keep It Simple Stupid! (KISS)
|
|
|
|
|
i got it working after finding some code that monitors a folder including subfolders
i just changed it around so that it checked for the extention and renamed it
strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
strFolderName=inputbox("ENTER THE FULL BACKUP PATH")
msgbox "A messagebox will display on completion, this may take some time"
Set colSubfolders = objWMIService.ExecQuery _
("Associators of {Win32_Directory.Name='" & strFolderName & "'} " _
& "Where AssocClass = Win32_Subdirectory " _
& "ResultRole = PartComponent")
arrFolderPath = Split(strFolderName, "\")
strNewPath = ""
For i = 1 to Ubound(arrFolderPath)
strNewPath = strNewPath & "\\" & arrFolderPath(i)
Next
strPath = strNewPath & "\\"
Set colFiles = objWMIService.ExecQuery _
("Select * from CIM_DataFile where Path = '" & strPath & "'")
For Each objFile in colFiles
If objFile.Extension = "txt" Then
strBACKUP = objFile.Drive & objFile.Path & objFile.FileName & "." & "bak"
objFile.Copy(strBACKUP)
End If
Next
For Each objFolder in colSubfolders
GetSubFolders strFolderName
Next
Sub GetSubFolders(strFolderName)
Set colSubfolders2 = objWMIService.ExecQuery _
("Associators of {Win32_Directory.Name='" & strFolderName & "'} " _
& "Where AssocClass = Win32_Subdirectory " _
& "ResultRole = PartComponent")
For Each objFolder2 in colSubfolders2
strFolderName = objFolder2.Name
arrFolderPath = Split(strFolderName, "\")
strNewPath = ""
For i = 1 to Ubound(arrFolderPath)
strNewPath = strNewPath & "\\" & arrFolderPath(i)
Next
strPath = strNewPath & "\\"
Set colFiles = objWMIService.ExecQuery _
("Select * from CIM_DataFile where Path = '" & strPath & "'")
For Each objFile in colFiles
If objFile.Extension = "txt" Then
strBACKUP = objFile.Drive & objFile.Path & objFile.FileName & "." & "bak"
objFile.Copy(strBACKUP)
End If
Next
GetSubFolders strFolderName
Next
End Sub
thanks for the help!
|
|
|
|
|
How to copy data in a data table to another table in run time (by using VB.NET 2005)
|
|
|
|
|
This is disconnected from a DB ? You'd have to build the table to have the right format and copy the rows across.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
|
Dim NewTable as datatable = oldtable.copy
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Hi
How can I open a website from a windows application in any browser
Thanks
Sebastian
|
|
|
|
|
By using Process.Start with a URL, you can launch the default browser. To specify the browser, you'd need to find the exe on the HDD and know how to launch it with a URL.
Christian Graus
Driven to the arms of OSX by Vista.
|
|
|
|
|
Actually...This will launch any default browser at the URL you specify
Private Sub LaunchURL(byval URL as String)
Try
Process.Start(URL)
Catch ex as exception
End Try
End Sub
You can then use: LaunchURL("http://urlhere") from anywhere within your code..
The Try is needed because some browsers like Firefox will sometimes return an error for no reason...
Steven
|
|
|
|
|
in one of my application i am using mscomm32.ocx for fetching data from electronic weighbridge but in this case one problem occur some time it gives wrong value(eg:the actual weight is 5900Kg some time it shows 2810Kg or 2800Kg and then again convert to 5900Kg automatically it happens frequently in some timer interval).i am using timer control for getting data to textbox.
I hope i am able to clear my situation.
Thanx in advance
|
|
|
|
|
Hi I m not sure about it...
1. But some time machine will send more than 2 parameter check it Once.
2. Check Number conversion is happens...
|
|
|
|