Så här ser sidan ut i dagsläget, man klickar på mapp och väljer bild, då visas exif.aspx
Det är den sidan jag vill att man ska kunna bläddra mellan bilderna på.
Kod:
exif.aspx
<%@ Import Namespace="System" %>
<%@ Import Namespace="System.Drawing" %>
<%@ Import Namespace="System.Drawing.Imaging" %>
<%
Dim objImage As Drawing.Image
Dim arrProps As PropertyItem()
Dim objProp As PropertyItem
Dim strReturn As String
Dim blnIsEXIFFile As Boolean
Dim intRecip As Integer
Dim intVal As Integer
Dim strModel As String
Dim strDate As String
Dim strExposureTime As String
Dim strFStop As String
Dim strFocalLength As String
Dim strISOSpeed As String
Dim strMeteringMode As String
Dim strLightSource As String
Dim strExposureProgram As String
Dim strTemp As String
Dim arrByte As Byte()
Dim intCounter As Integer
Dim strFileName as string
Dim strSize
Dim strISO as string
strFileName = Request.QueryString("photo")
strSize = Request.QueryString("z")
objImage = System.Drawing.Image.FromFile(MapPath(strFileName))
arrProps = objImage.PropertyItems
blnIsEXIFFile = False
For Each objProp In arrProps
Select Case objProp.Id
Case 272 'Model
arrByte = objProp.Value
For intCounter = 0 To arrByte.GetUpperBound(0)
If Not arrByte(intCounter) = 0 Then 'Strips off "end of string" Byte if present
strTemp &= Chr(arrByte(intCounter))
End If
Next
strModel = RTrim(strTemp)
blnIsEXIFFile = True
Case 306 'DateTime
strTemp = System.Text.Encoding.ASCII.GetString(objProp.Value)
'Reformat the Date from yyyy:mm:dd hh:mm:ss to YYYY-MM-DDDD
strDate = Mid(strTemp, 1, 4) & "-" 'Year
strDate &= Mid(strTemp, 9, 2) & "-" 'Month
strDate &= Mid(strTemp, 6, 2) 'Da
blnIsEXIFFile = True
Case 33434 'Exposure Time
If System.BitConverter.ToInt32(objProp.Value, 0) >= System.BitConverter.ToInt32(objProp.Value, 4) Then
strExposureTime = (System.BitConverter.ToInt32(objProp.Value, 0) / System.BitConverter.ToInt32(objProp.Value, 4)) & " Sec"
Else
intVal = 1
intRecip = System.BitConverter.ToInt32(objProp.Value, 4) / System.BitConverter.ToInt32(objProp.Value, 0)
strExposureTime = intVal & "/" & intRecip & " Sec"
End If
blnIsEXIFFile = True
Case 33437 'FStop
strFStop = "F" & (System.BitConverter.ToInt32(objProp.Value, 0) / System.BitConverter.ToInt32(objProp.Value, 4))
blnIsEXIFFile = True
Case 37386 'Focal Length
strFocalLength = (System.BitConverter.ToInt32(objProp.Value, 0) / System.BitConverter.ToInt32(objProp.Value, 4)) & "mm"
blnIsEXIFFile = True
Case 37383 'Metering Mode
strTemp = System.BitConverter.ToUInt16(objProp.Value, 0).ToString
Select Case strTemp
Case "1"
strMeteringMode = "Average"
Case "2"
strMeteringMode = "Center Weighted Ave"
Case "3"
strMeteringMode = "Spot"
Case "4"
strMeteringMode = "Multi-Spot"
Case "5"
strMeteringMode = "Pattern"
Case "6"
strMeteringMode = "Partial"
Case Else
strMeteringMode = "Other"
End Select
blnIsEXIFFile = True
Case 37385 'Flash
strTemp = System.BitConverter.ToUInt16(objProp.Value, 0).ToString
Select Case strTemp
Case "0"
strLightSource = "Yes"
Case Else
strLightSource = "No"
End Select
blnIsEXIFFile = True
Case 34850 'Exposure Program
strTemp = System.BitConverter.ToUInt16(objProp.Value, 0).ToString
Select Case strTemp
Case "1"
strExposureProgram = "Manual"
Case "2"
strExposureProgram = "Normal Program"
Case "3"
strExposureProgram = "Aperature Priority"
Case "4"
strExposureProgram = "Shutter Priority"
Case "5"
strExposureProgram = "Creative Program"
Case "6"
strExposureProgram = "Action Program"
Case "7"
strExposureProgram = "Portrait Mode"
Case "8"
strExposureProgram = "Landscape Mode"
Case Else
strExposureProgram = "Unknown"
End Select
blnIsEXIFFile = True
Case 34855 'ISO
strISO = System.BitConverter.ToUInt16(objProp.Value, 0).ToString
blnIsEXIFFile = True
End Select
Next
%>
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=iso-8859-1">
<meta name="generator" content="Microsoft .net">
<title>© Daniel Gustafsson - Mixed Albums</title>
<style type="text/css">
<!--
A:link, A:active { color: #FF9900; text-decoration: underline; }
A:visited { color: #FF9900; text-decoration: underline; }
A:hover { color: #FF9900; text-decoration: none; }
.text { font-family: Verdana, Arial, Helvetica; font-size: 9px; color: #222222; }
-->
</style>
</head>
<body topmargin="40">
<center>
<p>
<img border=0 src='myResize.aspx?src=<%=strFileName%>&z=<%=strSize%>' Style="FILTER:progid:DXImageTransform.Microsoft.Shadow(color='#333333', Direction=120, Strength=7)">
<br>
<center><font size='2' face='Tahoma,Arial' color='#000000'>Other sizes:
<a href='exif.aspx?photo=<%= strFileName %>&z=2'>Small</a>
<a href='exif.aspx?photo=<%= strFileName %>&z=6'>Medium</a>
<a href='exif.aspx?photo=<%= strFileName %>&z=12'>Large</a>
<a href='exif.aspx?photo=<%= strFileName %>&z=1000'>Original</a><br>
<% IF blnISEXIFFile Then %>
<Table width=650 border='0' cellpadding='2' cellspacing='1' width='80%' bgcolor='black' ID="Table1" Style="FILTER:progid:DXImageTransform.Microsoft.Shadow(color='#333333', Direction=120, Strength=5)">
<TR>
<TH bgcolor='#F6F6F6'><center><font size='1' face='Tahoma,Arial' color='#000000'>Camera</center></TH>
<TH bgcolor='#F6F6F6'><center><font size='1' face='Tahoma,Arial' color='#000000'>Date</center></TH>
<TH bgcolor='#F6F6F6'><center><font size='1' face='Tahoma,Arial' color='#000000'>Exposure Time</center></TH>
<TH bgcolor='#F6F6F6'><center><font size='1' face='Tahoma,Arial' color='#000000'>Aperture</center></TH>
<TH bgcolor='#F6F6F6'><center><font size='1' face='Tahoma,Arial' color='#000000'>ISO</center></TH>
<TH bgcolor='#F6F6F6'><center><font size='1' face='Tahoma,Arial' color='#000000'>Focal Length</center></TH>
<TH bgcolor='#F6F6F6'><center><font size='1' face='Tahoma,Arial' color='#000000'>Metering Mode</center></TH>
<TH bgcolor='#F6F6F6'><center><font size='1' face='Tahoma,Arial' color='#000000'>Flash</center></TH>
<TH bgcolor='#F6F6F6'><center><font size='1' face='Tahoma,Arial' color='#000000'>Exposure Program</center></TH>
</TR>
<TR>
<TD bgcolor='#FFFFFF'><center><font size='1' face='Tahoma,Arial' color='black'><%=strModel %></center></TD>
<TD bgcolor='#FFFFFF'><center><font size='1' face='Tahoma,Arial' color='black'><%=strDate %></center></TD>
<TD bgcolor='#FFFFFF'><center><font size='1' face='Tahoma,Arial' color='black'><%=strExposureTime %></center></TD>
<TD bgcolor='#FFFFFF'><center><font size='1' face='Tahoma,Arial' color='black'><%=strFStop %></center></TD>
<TD bgcolor='#FFFFFF'><center><font size='1' face='Tahoma,Arial' color='black'><%=strISO %></center></TD>
<TD bgcolor='#FFFFFF'><center><font size='1' face='Tahoma,Arial' color='black'><%=strFocalLength %></center></TD>
<TD bgcolor='#FFFFFF'><center><font size='1' face='Tahoma,Arial' color='black'><%=strMeteringMode %></center></TD>
<TD bgcolor='#FFFFFF'><center><font size='1' face='Tahoma,Arial' color='black'><%=strLightSource %></center></TD>
<TD bgcolor='#FFFFFF'><center><font size='1' face='Tahoma,Arial' color='black'><%=strExposureProgram %></center></TD>
</TR>
</Table>
<% Else %>
<Table width=650 border='0' cellpadding='2' cellspacing='1' width='80%' bgcolor='black' ID="Table1" Style="FILTER:progid:DXImageTransform.Microsoft.Shadow(color='#333333', Direction=120, Strength=5)">
<TR>
<TH bgcolor='#F6F6F6'><center><font size='1' face='Tahoma,Arial' color='#000000'>This file does not contain any EXIF Data.</center></TH>
</TR>
</Table>
<% End If %>
<br>
<p><br>
</center>
</body>
</html>
Detta koden från http://aspnet.4guysfromrolla.com/London/
som har funktionen jag vill ha i ovanstående sida.
Kan nån av er experter sy ihop dessa, förklara gärna..
/Daniel