Jump to content
Xtreme .Net Talk

Rothariger

Avatar/Signature
  • Posts

    66
  • Joined

  • Last visited

Everything posted by Rothariger

  1. Hello, i dont know if this is the right Forum... if it isnt move it.. pls... i need to make a mms streamer(if it is posible to a file)... does anybody have a example??? thanks!!!
  2. hello, i am making an C# smart application, and i have a problem.. i have an xml file for configuration... i need to know how can i make it for when i make the debugging deployment, the xml file uploads automatically... i must to upload manually... thanks... PS: i put to the xml file, the property i think it is "action generated"... i put it "content"... i dont know if this has something to do.. but...
  3. Hello.... i want to know if its posible to rename multiple files like windows does.. example: file zzzzzzz.doc file asdasd.doc file esfsefse.doc if you select the three files and rename it, windows put this way.. file(1).doc file(2).doc file(3).doc is there any vb.net way of doing this? thanks!!! PS: off course i want the easy way, some way for windows api for make it... now i am making by code, but may be, there's a way automatically... or with an api...
  4. at weekend, i take a look to your suggestions, and make a callback... thanks!!! Add: i also meant to change the code, i dont like the datatable thing, but i dont get other way working.. thanks once again!
  5. Hello ive make this code, to rename the files with the "Picture Date Taken" property and i leave it a little ugly... someone can help me to clean up.. i use datatables, for the files, so i can use the unique property and the orderby... but can make it other way... change it at like... Private Sub BDcmdReemplazar_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BDcmdReemplazar.Click Dim file As String Dim pattern As String Dim i As Integer Dim Fecha As DateTime = DateTime.MinValue Dim myDr As DataRow Dim myDataTable As New DataTable Dim tmpdate As String If MsgBox("Se van a Renombrar " & System.IO.Directory.GetFiles(BDtxtPath.Text, cmbExt.SelectedValue).Length & " Archivos." & vbCrLf & "Desea Continuar", MsgBoxStyle.YesNo, "Confirmar") = MsgBoxResult.No Then Exit Sub End If myDataTable.Columns.Add(New DataColumn("Numero", GetType(System.Decimal))) myDataTable.Columns.Add(New DataColumn("Nombre", GetType(System.String))) myDataTable.Columns(1).Unique = True myDataTable.Columns.Add(New DataColumn("Path", GetType(System.String))) myDataTable.Columns.Add(New DataColumn("Fecha", GetType(System.DateTime))) myDataTable.Columns.Add(New DataColumn("Ext", GetType(System.String))) For Each file In System.IO.Directory.GetFiles(BDtxtPath.Text, cmbExt.SelectedValue) Dim myFile As New System.IO.FileInfo(file) myDr = myDataTable.NewRow myDr(1) = myFile.Name myDr(2) = myFile.Directory tmpdate = Propert(myFile.FullName) If Trim(tmpdate).CompareTo("0000:00:00 00:00:00") = 0 Then myDr(3) = Now Else myDr(3) = CType((tmpdate.Substring(0, 10)).Replace(":", "-"), Date) End If myDr(4) = myFile.Extension myDataTable.Rows.Add(myDr) Next i = 0 For Each myDr In myDataTable.Select("", "Fecha") If Format(Fecha, "dd-MM-yyyy") <> Format(myDr(3), "dd-MM-yyyy") Then Fecha = myDr(3) i = 0 End If Try System.IO.File.Move(myDr(2) & "\" & myDr(1), myDr(2) & "\" & Format(myDr(3), "dd-MM-yyyy") & IIf(i = 0, "", " - " & i) & myDr(4)) Catch ex As IOException MsgBox(ex.Message, MsgBoxStyle.Critical, ex.ToString) Finally i += 1 End Try Next myDr = Nothing Fecha = Nothing End Sub Private Function Propert(ByVal file As String) As String Dim img As Image = Image.FromFile(file) Dim x As String Try For Each iPI As Drawing.Imaging.PropertyItem In img.PropertyItems Select Case iPI.Id Case "9003" 'Date If Trim(ASCIIEncoding.ASCII.GetString(iPI.Value)) <> "" Then Return ASCIIEncoding.ASCII.GetString(iPI.Value) End If Case 306 'PropertyTag DateTime If Trim(ASCIIEncoding.ASCII.GetString(iPI.Value)) <> "" Then Return ASCIIEncoding.ASCII.GetString(iPI.Value) End If Case 36867 'PropertyTag ExifDTOrig If Trim(ASCIIEncoding.ASCII.GetString(iPI.Value)) <> "" Then Return ASCIIEncoding.ASCII.GetString(iPI.Value) End If Case 36868 'PropertyTagExif DTDigitized If Trim(ASCIIEncoding.ASCII.GetString(iPI.Value)) <> "" Then Return ASCIIEncoding.ASCII.GetString(iPI.Value) End If End Select Next Catch Finally img = Nothing End Try End Function anything just ask... PD: My english is every day worst..!!! thanks and salute!!!
  6. thanks!!! it worked perfectlly!!!! thank you very much!
  7. Hello People... i need help with this... im making a little program that stores the pictures automatically, in a DB, i need a hand with this thing... one field i want to save is the Date Picture Taken of the file, but i dont know how to retrieve it.... some one can give me a hand??? thanks!!!
  8. yes, i have seen javascript rpc, but its a little difficult... but im in practice!!! thanks a lot!!!
  9. ok, thank you very much utilitaire... it was good explained..!!! may be with the .net 2.0, callback... but thats doesnt matter now... thanks once again..!!!
  10. hello, i am making an web application for the university, and in some places, there makes somethings in the DB, then i would like to leave the page like "suspended" and when the job is all done, then i raise an event, and render the data to the page... it is this possible??? thanks!!!
  11. ok i will look in it... THANKS!!!
  12. hello, i must to make that, i have found this code that acomplish that, but, when i make the postback i loose all that i have done... how can i make so the changes are still there after the postback??? im making this little example for make a try... but at the postback i loose all data... Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load 'Introducir aquí el código de usuario para inicializar la página If Not IsPostBack Then ListBox1.Items.Add(New System.Web.UI.WebControls.ListItem("Uno", 10)) ListBox1.Items.Add(New System.Web.UI.WebControls.ListItem("Dos", 20)) ListBox1.Items.Add(New System.Web.UI.WebControls.ListItem("Tres", 30)) ListBox2.Items.Add(New System.Web.UI.WebControls.ListItem("Cien", 100)) ListBox2.Items.Add(New System.Web.UI.WebControls.ListItem("Doscientos", 200)) ListBox2.Items.Add(New System.Web.UI.WebControls.ListItem("Trescientos", 300)) End If Button1.Attributes.Add("onclick", "javascript:return pasaraderecha();") Button2.Attributes.Add("onclick", "javascript:return pasaraizquierda();") thanks and salutes!!!
  13. no no, i mean, that i create a credential "cCache.Add(New Uri(strURL), "Basic", New System.Net.NetworkCredential("User", "Pass", "domain"))", and with this i log into the server, i have no problem, if i look at "Wapp2WebResponse" i have a good response, and i have the document at the Wapp2WebResponse.getresponsestream but i must to make a redirection to that page... its clear? thanks!
  14. infragistics, are the best... then you have janusys, at least the grid and panel are outlook like...
  15. Hello, i have two webapplications (webapp1 and webapp2), webapp1 its with integrated security, and webapp2 its with basic auth, i must from webapp1 login in webapp2 but i cant... :S i have this code... Dim strURL As String = "http://localhost/webapp2/webform1.aspx" Response.ClearHeaders() Response.ClearContent() Dim Wapp2WebRequest As System.Net.HttpWebRequest = CType(System.Net.WebRequest.Create(strURL), System.net.HttpWebRequest) Wapp2WebRequest.Timeout = 10000 Wapp2WebRequest.MaximumAutomaticRedirections = 50 Dim cCache = New System.Net.CredentialCache cCache.Add(New Uri(strURL), "Basic", New System.Net.NetworkCredential("User", "Pass", "domain")) Wapp2WebRequest.Credentials = cCache Wapp2WebRequest.PreAuthenticate = True Dim Wapp2WebResponse As System.net.WebResponse Wapp2WebResponse = CType(Wapp2WebRequest.GetResponse(), System.net.WebResponse) Dim i As Integer Response.AddHeader("Location", strURL) For i = 0 To Wapp2WebRequest.Headers.Count - 1 Response.AddHeader(Wapp2WebRequest.Headers.Keys(i).ToString, Wapp2WebRequest.Headers.Item(i).ToString()) Next Response.Redirect(strURL) obviusly the response.redirect erease all the headers i add, then i dont know how to get redirected, from this page... :S some one can help me??? thanks!
  16. hello i have an windows vb app, that must to connect to an webapplication asp.net the problem is that the site have basic authenticacion... ok i have done this... Dim strURL As String = TextBox1.Text Dim ReportWebRequest As System.Net.HttpWebRequest = CType(System.Net.WebRequest.Create(strURL), System.net.HttpWebRequest) ReportWebRequest.Timeout = 1000000 ReportWebRequest.MaximumAutomaticRedirections = 50 Dim cCache = New System.Net.CredentialCache cCache.Add(New Uri(strURL), "Basic", New System.Net.NetworkCredential("User", "Pass", "Domain")) ReportWebRequest.Credentials = cCache ReportWebRequest.PreAuthenticate = True Dim ReportWebResponse As System.net.HttpWebResponse = CType(ReportWebRequest.GetResponse(), System.Net.HttpWebResponse) and here i stuck, i dont know what to do with the ReportWebResponse object... ok, i have another problem, i have to 2 thing, one is to open a internet explorer with the page, or if the user selects it, open it in the windows program itself, in an axwebbroser obj. some one can give me a hand? thanks!
  17. hello, in a intranet at my work, i see that the error page are customized... and i dont know how, anyone can say me how can I make it? i post an example page of error, and i want it customized. PD: rename the file to .htm Login failed for user 'sa'.doc
  18. hello, i must to determine windows version, not only if it is windows 2000 i must to determine too if it is professional or advanced server, or server...!!! i have this page http://support.microsoft.com/default.aspx?scid=kb;en-us;304289 but only helps for determining if its windows 2000, or xp, or 2003, or 98... but not wich version of every one... does anybody knows how to doit? thanks!!!
  19. thanks, but this is a local program... i need the code to add to a vbulletin forum so i can put [ vb ] tag and format the text like vb, or [ cs ] and format the text like CSharp...
  20. aaaaa.... ok thanks to all!!! PS: I did search "SqwishyWare syntax highlighter" in google, but nothing appears...
  21. hello i do post in another forum its the biggest forum in argentina, and i want that they insert te csharp vbtag, but i dint find it anywhere... does you can tell me where to find it? or better can you share me with a copy??? thanks!
  22. aaaa.... ok... i got that... ok i will work locally, and then i will upload to mi web server, by ftp... thanks anyway!
  23. Hello, i need a little help... i must to load a XML File, from an URL, to a Memorystream, or something like IO.Stream. i try buy i was unable to do it... thanks!
×
×
  • Create New...