|
A great pity! It would solve some of my problems.
Anyway, thanks a lot for your support Guffa!
Rudi
|
|
|
|
|
i dont need to write in note pade and the another application read from it. i need to use the sendwait() method but the problem what happed ? really i dont know maybe i shoudl add timer to the button action to slow down the transfer of data from vb.net to another application ..so i need the solution .. because i work with seminar project and i have a 1/5 as a dead date .. the problem is transfer a data from vb.net to another application without any changes of data..
please i send more than 12 to get the answer but still at this moment without a correct soluation...please help me.
in the subject example the first time will print 08052 and the second maybe 080052 and the third maybe 0855520 and th fourth maybe 08052 but why doesnt print the correct data in each time click on the button "080052" doh:
kilany
|
|
|
|
|
i still wait the answer ... if you dont have a anwswer just tell me.. because i hate the wait time
kilany
|
|
|
|
|
Hello,
i need help to know how can i post XML to XML web service url, it should be easy for someone who worked with XML web services:
I need to post this sample xml data:
<catalogrequest xml:lang="en-US">
<xmlpassword>myxmlpassword
after posting i would like to receive the data and save it to xml file, it would contain hunders of records.
Please need the code to work on VB.NET application.
here is all i have about this xml web services any help would be approciated to get a code that i can get and download/save the xml response Thanks:
Download the catalog
To download the catalog, you must form an XML CatalogRequest and send it to your cobranded site's XML URL. This URL can be found on the 'Site Setup' tab under the 'General' sub tab. The XML URL will look similar to the following URL:
http://p7d6.arixmedia.com/xxxxxxxxxxxxxxxx/xml
Where 'xxxxxxxxxxxxxxxx' is the cobranded site's numeric ID. The specification for CatalogRequest is documented in the next section in Table 1: CatalogRequest Specification. Below is a sample CatalogRequest:
<catalogrequest xml:lang="en-US">
<xmlpassword>myxmlpassword
<lastupdated>2005-09-21 06:00:00
In the above example our XML password is 'myxmlpassword'. We also only want items that have been added or updated since 6:00am on 9/21/2005.
Once the CatalogRequest has been sent to the server, it should respond with a CatalogResponse, which contains the actual catalog data.
Note: When sending your CatalogRequest to the XML URL, make sure you use a method that provides a valid User Agent string. If you are using CURL/PHP, you can use the following code to do this:
curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)");
where $ch is your CURL session handle.
Storing the data
Once you have received a CatalogResponse, you will need to save the data to a local database. The procedure for doing this will vary depending on the scripting language or application you are using to download the feed.
You will also need to save the value of 'LastUpdated' from CatalogResponse/CatalogInfo, as this will allow you to retrieve incremental updates for subsequent CatalogRequests as opposed to the entire catalog.
Note that a CatalogResponse may contain items that already exist in your database, as some items may have been changed or updated since your last CatalogRequest.
Samer
|
|
|
|
|
here is the xml again,
the forum reads it as HTML tags:
?xml version="1.0" encoding="ISO-8859-1"?>
CatalogRequest xml:lang="en-US">
XMLPassword>myxmlpassword
LastUpdated>2005-09-21 06:00:00
/CatalogRequest>
Sam
|
|
|
|
|
There's no way we are going to give you the code for this. You have apparently made no attempt at solving it yourself. This forum is for help with programming problems - not doing your assignments for you.
If you need help with one or two problems related to the assignment then that's fine - we're only too happy to help - but we won't do it for you.
...Steve
1. quod erat demonstrandum
2. "Give a man a fish and you've fed him for a day. Teach him how to fish and you've fed him for life." I read that somewhere once
|
|
|
|
|
Steve yes i tried working on it but i have had no clue what is that or how it does work, im programer and i know well about coding and trying.
anyway i got to do it with a help from a friend in php thanks
Samer
Samer
|
|
|
|
|
In the present code, we use a datagrid as a container to print data from a SQL database. The following gets data (via ODBC) in the SQL database and save it in a DATASET.
Public Function GetDatasetGiveSql(ByVal sqlCmd As String) As DataSet
Dim dataset As New DataSet
odbcCmd.Connection.Close()
odbcCmd = New Odbc.OdbcCommand(sqlCmd, odbcConnection)
odbcAdapt = New Odbc.OdbcDataAdapter(odbcCmd)
odbcCmd.Connection.Open()
odbcAdapt.Fill(dataset)
Return dataset
End Function
Elsewhere in the software, the software builds a query and sends it to the database like this:
dsCommand = sql.GetDatasetGiveSql(cmd)
DataGridCommand.SetDataBinding(dsCommand, "Table")
As you can suspect, dsCommand is a DataSet and DataGridCommand is the DataGrid to update.
Easy to date… OK.
Question:
---------
I want to have control on the background and foreground color of a cell based on some information like any people in this forum. I found many EXAMPLES with DataGridColumnStyle where the idea is to override the Paint method (aka: make a custom datagrid control). Yes, Perfect. I understand it BUT in this case… I DON’T CONTROL ANY COLUMN in the datagrid. It seems that the SetDataBinding() does everything by itself, it is magic.
I did not find HOW to OVERRIDE the Paint() method of this datagrid. Maybe I don’t understand something !
Danny Gilbert, enginneer
Montréal, Canada
Danny Gilbert, enginneer
Montréal, Canada
|
|
|
|
|
Hi Danny
I found a class on the net that changes the cell color according to what
information is placed in the cell, is this what your after? Below is how
I used it. Instead of a basic color I actually used a linear graded color in the cell, looks great in the grid.
Imports Microsoft.VisualBasic
Imports System
Imports System.Drawing
Imports System.Drawing.Drawing2D
Imports System.Windows.Forms
Public Class DataGridColoredTextBoxColumn
Inherits DataGridTextBoxColumn
Public Sub New()
'Warning: Implementation not found
End Sub
Protected Overloads Overrides Sub Paint(ByVal g As Graphics, ByVal bounds As Rectangle, ByVal source As CurrencyManager, ByVal rowNum As Integer, ByVal backBrush As Brush, ByVal foreBrush As Brush, ByVal alignToRight As Boolean)
' the idea is to conditionally set the foreBrush and/or backbrush
' depending upon some crireria on the cell value
' Here,we color anything that matches the select case
Try
Dim o As Object
o = Me.GetColumnValueAtRow(source, rowNum)
If (Not (o) Is Nothing) Then
Dim c As Char
Dim cellStr As String
c = CType(o, String).Substring(0, 1)
cellStr = CType(o, String)
Select Case cellStr
Case "**CRITICAL**"
backBrush = New LinearGradientBrush(bounds, Color.FromArgb(255, 50, 25), Color.FromArgb(128, 20, 20), LinearGradientMode.BackwardDiagonal)
foreBrush = New SolidBrush(Color.White)
Case "- URGENT -"
backBrush = New LinearGradientBrush(bounds, Color.FromArgb(255, 255, 255, 0), Color.FromArgb(200, 10, 0), LinearGradientMode.BackwardDiagonal)
foreBrush = New SolidBrush(Color.White)
Case "current"
backBrush = New LinearGradientBrush(bounds, Color.FromArgb(255, 10, 255, 0), Color.FromArgb(0, 50, 0), LinearGradientMode.BackwardDiagonal)
foreBrush = New SolidBrush(Color.White)
End Select
End If
Catch ex As Exception
' empty catch
Finally
' make sure the base class gets called to do the drawing with
' the possibly changed brushes
MyBase.Paint(g, bounds, source, rowNum, backBrush, foreBrush, alignToRight)
End Try
End Sub
End Class
It gets called like this.
Dim numCols As Integer
numCols = Me.m_openQueries.Tables(0).Columns.Count
Dim aColumnTextColumn As DataGridColoredTextBoxColumn
Dim i As Integer
i = 0
Do While (i < numCols)
aColumnTextColumn = New DataGridColoredTextBoxColumn()
aColumnTextColumn.HeaderText = m_openQueries.Tables(0).Columns (i).ColumnName
aColumnTextColumn.MappingName = m_openQueries.Tables(0).Columns(i).ColumnName
table_style.GridColumnStyles.Add(aColumnTextColumn)
i = (i + 1)
Loop
Hope this helps
cowtech
|
|
|
|
|
Thank you very much, I will try it.
Danny Gilbert, enginneer
Montréal, Canada
|
|
|
|
|
Hi Danny
Just wondering how you went with this.
cowtech
Sydney Australia
|
|
|
|
|
I have an MDIList menu item that I want to enumerate at run-time and possibly change the text shown for some of the MDI children included in that list. When I enumerate the collection for that menu item, none of the open MDI child windows show in the list although they are clearly there in the actual drop-down of the menu item. Does anyone know how I can enumerate the menu item that contains the MDIList at run-time and change the text associated with some of the MDI children in that list?
Thank you.
|
|
|
|
|
I have a ActiveX control created in VB 6 from a 3rd party and wanted to use it in ASP.Net/VB.Net but the control dosent expose APIs which could be called from ASp.Net/VB.Net. I tried invoking the function from javascript but later foudn that some functions on the OCX were not even exposed to javascript. So the tech support (who do not provide support for .Net) suggested that we create another wrapped OCX around theirs, and use that OCX within our web pages. So far so good.
We did as they said, created our own OCX, doing whatever we wanted to. We then tested it out on .Net 1.1 and the control worked like a charm. But when we attemp to use the same control in VS 2005 (prfessional edition), the control does appear in teh toolbox pane, but is disabled, and does not allow itself to be placed on any page. in VS 2003 we are using it normally without any issues.
Can you plz guide me as to what might be the problem.
|
|
|
|
|
Hi.
Can anyone help me with the problem I have. I need to write a program that will monitor user activity: file open, deleted, renamed, on the server. But most important I need to know WHO actually did it (user name).
I was able to write code (windows service), using FileSystemWatcher, that can monitor directories on my computer and even was able to parse it by extensions.
The problem is I cannot get user name who changed, deleted, created files. As soon as I install my windows service it returns SYSTEM as user name for me.
I looked for other programs but they can't give me user name as well. Like
http://www.sysinternals.com/Utilities/Filemon.html[^]
Did anyone have any experience with this? Any suggestions are appreciated.
Thank you,
|
|
|
|
|
About the only other place to try to get this information would the Network Redirector. But I don't think you'll be able to match it up to any actual file operation in the File System. You can see who has what files open, but not what those users are doing to them using the Win32 API NetFileEnum.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Thanks Dave.
Do you have any references (link or article) I can read?
I'm not sure what should I do. I thought file system suppose to have last modified information somewhere (who opened file last).
Should I still use FileStreamWatcher with combination of Win32 API (NetFileEnum)?
Thanks,
|
|
|
|
|
It doesn't. It tracks the last owner of the file, which is not necessarily the last person to touch it. It also tracks the last Modified time, last Accessed time, and Created time, but that's about it.
You can try FileSYstemWatcher and the NetFileEnum, but keeping the two in synch would probably be very difficult. For instance, two people have the same file open, but only one writes to it. Which one??? There's no way to tell...
Dave Kreskowiak
Microsoft MVP - Visual Basic
-- modified at 13:34 Wednesday 19th April, 2006
|
|
|
|
|
Thanks for your help Dave. I think I will use FileSystemWatcher with Event Log entries (parse Event Log) like this I can tell at lest who access it and match it against FileSystemWatcher (create, delete, modify). I will write 2 services (I think it would be better if I keep these separate) to monitor dirctory and Event Log.
Thank you again.
|
|
|
|
|
Hi
I want to create a report in crystal reports (the one that comes with VS 2003) that reads its data from our SQL2000 server. The problem I have, is that it keeps on poping up the database login screen every time I try to run the report and then I have to enter the password. How do I remove the database login popup?
Some extra information:
1. I have created a user in SQL Server 2000 with a password and the correct access rights to the tables that I want to read from.
2. In Crystal reports I created a connection with OLE DB (ADO) and entered the server, user ID, password and default database. Integrated security is not selected.
Anyone have an idea what the problem might be?
Thanks!
Izak
|
|
|
|
|
Hi all,
I'm developing a vb.net 2005 application with an Access database. I create a setup and install it on a client machine. The first time I run the application it takes about 20 seconds to load. If I close it down and run it again straight away it takes about 3-4 seconds to load. If I don't load it for about an hour or restart the machine it again takes 20 seconds to load.
I then put in a few thousand records and the times are about the same so I don't think it has to do with the database.
The machines I've tried it on are about 3 years old. Is it something I have to live with or is there something I can do.
In AdvancedCompile Options I have Enable Optimizations turned on. Should I have Configuration Manager set to Release instead of Debug everytime I create a setup or does VS 2005 automatically do it?
Any help would be much appreciated,
|
|
|
|
|
Well, the slow startup time first time is because of what is called a "Cold Startup". So, if you are running 2 or 3 .NET applications at the same time, the 20+secs delay will be only for the first app. This is because the OS loads the .NET Libarrys and JITter into Memory the first time a .NET app is loaded.
Probably, this problem will be solved in Vista, since probably the .NET Framework will be preloaded on startup....
More Information here : http://msdn.microsoft.com/msdnmag/issues/06/02/CLRInsideOut/default.aspx
Yuvi Panda T
Microsoft Student Partner
Blogs at : http://yuvipanda.blogspot.com
|
|
|
|
|
Thanks for that Yuvi,
I tried a small hello world app. Re-started the machine and it took about 10 seconds to load, so you are correct with your Cold Startup theory.
Thanks for clearing that up for me.
Dave
|
|
|
|
|
hi
I want to have a variabel member in a class in vb6 to be SHARED between all instances of the class. I used Public Shared Myvar as Integer but VB6 automatically changed it to Public Myval as Integer
This is the case for Private Shared... and I could not also use Shared alone to declare the variable.
What can I do to have shared Variables??
-- modified at 10:02 Wednesday 19th April, 2006
|
|
|
|
|
IIRC, there's no such thing in VB6 because VB6 doesn't support true OOP. About the only approximation is to delcare a public variable in a module, but the variable will be exposed to everything, not just every instance of a class.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
"Shared" is a new keyword introduced in VB.NET.
Try using "Static" instead. VB6 classes have serious limitations, so cross your fingers.
|
|
|
|
|