|
I just specified the a png file as the background image of the form. How would I load it as a file?
thanks
|
|
|
|
|
Me.BackgroundImage.FromFile("c:\windows\clouds.png") ' whatever your path and file is.
|
|
|
|
|
The problem exists even if I dont specify a background image.
|
|
|
|
|
|
I am writing a distributed transaction code. My current scenario include a client database(Suppose client- having 4 main database) which can be installed anywhere which would connect to a public database placed at ISP datacentre(Suppose Server- having 2 database[host,transmissionqueue]). this server database is added to client as linked server through vb.net interface. i have a transmission routine which transmitts the data from the client to Server and update client transmit field. If i implement the distributed transaction in this scenrio is there any alternate to MTS . I m using the distributed transaction through vb.net interface using transaction object and setting 'begin distributed transaction' and 'set xact_abort on' and 'SET NOCOUNT ON' and 'SET REMOTE_PROC_TRANSACTIONS ON' options.
Sample code
''Start (Coding in VB.NET/ SQL Server 2000 backend on windows XP)
Public Function TransmitFiles(ByVal filepath As String, ByVal oDtTransmit As DataTable, ByVal iStation As Int16, ByRef TransmitErrorDetails As String) As Int32
Dim myConnection As SqlConnection = New SqlConnection("Data Source=shabbir;Database=AGS_LOGISTICS;UID=sa;pwd=SA;")
myConnection.Open()
Dim myTrans As SqlTransaction = myConnection.BeginTransaction()
Dim myCommand As SqlCommand = myConnection.CreateCommand()
myCommand.Transaction = myTrans
set_OPtions_on_database(myConnection, myTrans)
myCommand.CommandText = "Insert into Region (RegionID, RegionDescription) VALUES (100, 'Description')"
myCommand.ExecuteNonQuery()
myCommand.CommandText = "INSERT INTO [192.168.1.181].AGS_TRANSMISSIONQUEUE.DBO.MANIFEST SELECT * FROM MANIFEST WHERE ORIGINSTATIONID=9007 AND TRANSMITTED=1"
myCommand.ExecuteNonQuery()
myTrans.Commit()
myTrans.Dispose()
Console.WriteLine("Both records are written to database.")
Catch e As Exception
myTrans.Rollback()
end try
end sub
''End
Different problems are coming at different time
1- The problem is that transaction object is running fine but its not inserting anything in the database.
2- the executenonquery is returning -1 even where it is returning the correct record affected count without the transaction object for this command.
3-sometimes giving SQL server not found or Access Denied from the front end.
4- Some times SQL log is showing
2004-08-14 07:55:35.46 server Attempting to initialize Distributed Transaction Coordinator.
2004-08-14 07:55:35.53 server Failed to obtain TransactionDispenserInterface: Result
Code = 0x8004d01b
2004-08-14 07:55:35.54 spid3 Starting up database 'master'.
2004-08-14 07:55:36.03 server Using 'SSNETLIB.DLL' version '8.0.766'.
2004-08-14 07:55:36.03 spid5 Starting up database 'model'.
2004-08-14 07:55:36.06 server SQL server listening on 192.168.1.190: 1433.
2004-08-14 07:55:36.06 server SQL server listening on 127.0.0.1: 1433.
2004-08-14 07:55:36.06 server SuperSocket Info: Bind failed on TCP port 1433.
2004-08-14 07:55:36.09 spid3 Server name is 'SHABBIR'.
?????Can some body explain what is wrong with my coding or wht setting to made in the system?
* I m using window XP professional and .NEt studio 2003 and MSSQL 8.0
one of my testing server is also the same confing and other testing server is windows2000 server.
Important : will i have to install MTS on each client or server only if i went for Distributed transactions through DCOM and MTS?
Will i face any difficulties regarding the com registration?
Can some body provide some short sample project?
or Can some body provide some Code sample for the transaction class and how to configure in the MTS?
Can some body provide Some helpfull links to clear my concepts and helpfull in implementation and code?
All your help would be highly appreciated.
Regards,
Shabbir
shabbir
|
|
|
|
|
Is your server's IP address changing...
It looks to me like you have a network router/hub, Firewall or Unconfigured Qos service, problem.
Failed to obtain TransactionDispenserInterface: Result Code = 0x8004d01b
0x8004d01b "The transaction manager is unavailable" .
It is possible that DTC is shutting down unexpectedly.
SuperSocket Info: Bind failed on TCP port 1433.
(would not bind if DTC is in a shutDown State)
http://support.microsoft.com/default.aspx?scid=kb;en-us;319578&sd=tech
"Important : will i have to install MTS on each client"
You can use the MTS Explorer to distribute components to a client machine whether or not that client is running MTS. If the client is not running MTS, MTS can generate an executable that will automatically install and configure clients to access remote MTS server applications. The client must support DCOM for this procedure to work.
|
|
|
|
|
Hi, I have develop my database application in Ms access. Instead of copy the file to deploy at the other computer, I need to create a set up file for my MDB database. Because my application that I was written contain some reference from custom activx control. Can any one give me some advice to use any utilities of software to package the file. I need a very basic guide (step by step) to pacakge my database file and its activex control.
APO-CEDC
Save Children Norway-Cambodia Office
|
|
|
|
|
If your using Vb 6 take a look here.
Distributing Your Applications
Using the Package and Deployment Wizard
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vbcon98/html/vbconmanuallycreatingsetuplstfile.asp
|
|
|
|
|
Thank you, but I have a problem while I have a small project in vb6. I used to develop vb6 as interface and access as database. I used DAO as database engine to connect between database and its interface. The problem when I faced is package (create setup file) with package and deployment wizard. Whether I take a loot at MSDN at microsoft I still have a problem. Some screen of its wizard made me confuse and don't understand (I just guess and pass through it). It made me very difficult when I deploy my application to the other computer. Can any one give me a step by step guide?
APO-CEDC
Save Children Norway-Cambodia Office
|
|
|
|
|
hi,
can any one tell me how to translate gregorian date to hebrew date?
thanks in advance
|
|
|
|
|
I Haven't seen any source code for one, but
the .Net FrameWork does have some classes dealing with them here.
System.Globalization
.NET Framework Class Library
HebrewCalendar Class
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfsystemglobalizationhebrewcalendarclassctortopic.asp
.NET Framework Class Library
GregorianCalendar Class
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfSystemGlobalizationGregorianCalendarClassTopic.asp?frame=true
Maybe of help to you.
|
|
|
|
|
Hey
This should be a quick question, was hoping this is possible. I have a program , that minimizes to the system tray, I would like though, if the user, wants to push ctrl+a to in which will pull up a form to display. Without making the whole program come up to view. More or less my question is , is it possible to make a hotkey from anywhere in windows, open up a form from my program.
Thanks
|
|
|
|
|
There is an article about them here on CP
http://www.codeproject.com/vb/net/mclhotkeynet.asp
|
|
|
|
|
Hi All,
I need to write a XML file thru MSXML Parser 4.0 using DOMDocument element.
The elements are written in the same line of the file without any fomat for tags.
I would like to insert a newline char between tags. how do i do this...?
Help..Me..out from this.
Prasanna
|
|
|
|
|
What encoding if any are you using?
example: xml version="1.0" encoding="UTF-8" standalone="yes"
|
|
|
|
|
I haven't used any encoding yet..
By what way the encoding is useful while the opening the file in Notepad.
I think, the encoding is for viewing it in Browser.
Correct me if i am wrong anywhere...
Prasanna
|
|
|
|
|
hi
i want to know if it is possible to use real component in a app without installing real player? if yes how?
please help me, with best wishes!
|
|
|
|
|
You can, but since the real player component requires a bunch of supporting .DLLs and codecs, it's MUCH easier to just install it. Otherwise you'd have to write your own installer to make sure that all of these piece were in place to get the component your using to work.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
In VC++, with Sleep(1000) we can have about 1 second delay time. Do we have some thing like that in VB.net?
Thanks
|
|
|
|
|
|
System.Threading.Thread.CurrentThread.Sleep(1000)
|
|
|
|
|
how can I find the input value if exit in the data? I want to insert data to my database, and if the data is exiting in my database, then it isn't allowed to input this data.
Is anybody know how to code it?
Lisa
|
|
|
|
|
|
It seems that row validation fires when any one column of the row changes, so if you have a blank form that you are inputting values into and one of the things that you have to check is that both columns must contain data, how does it not flag the row as in error when the second col is still blank because you haven't got to it yet?
Thanks
|
|
|
|
|
I have two forms, main forms is viewing the data, the second form is open a data to update or delete, when I update or delete a data, then this form closes and return to main form, how can I update those data in the main form when the second form changed the data in database? do I need to call main form to reload the data after my me.close() in the second form?
Lisa
|
|
|
|